Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-45626

Some way to pass extra information to API calls (e.g. context for events) without proliferating many parameters

    XMLWordPrintable

Details

    • MOODLE_27_STABLE

    Description

      In many cases it will make sense to fire events from API calls. However, not all APIs have access to complete information to fire the event (e.g. context).

      The worst thing is to do extra db calls and kill performance (especially in big loops).

      Tim outlined the issue in this thread:
      https://moodle.org/mod/forum/discuss.php?d=257934

      Here is an example of an instance of trying to solve it in an 'ugly' way MDL-45466

      I think we need a solution which doesn't involve a proliferation of extra parameters to apis (especially if there is potential for a mismatch between the parameters).

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              poltawski Dan Poltawski
              David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo, David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo, Matteo Scaramuccia, David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo
              Votes:
              2 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: