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

Webservices errors should throw proper http code

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Won't Do
    • 3.2
    • None
    • Web Services
    • None
    • MOODLE_32_STABLE

    Description

      Came up from MDL-55916 - we made the web interface return a 503 when a a site was in maintenance mode. We should do the same in webservices, in fact there are other places where it doesn't seem like we are making use of proper http response codes.

      The code around maintance mode exception even gives a clue:

      //this is usually temporary, client want to implement code logic  => moodle_exception
       throw new moodle_exception('sitemaintenance', 'admin');
      

      Attachments

        Issue Links

          Activity

            People

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

              Dates

                Created:
                Updated:
                Resolved: