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

PDF conversion hangs for large files

    XMLWordPrintable

    Details

    • Affected Branches:
      MOODLE_31_STABLE, MOODLE_33_STABLE, MOODLE_34_STABLE, MOODLE_35_STABLE

      Description

      Background of this is - "Prepare submissions for annotation (\assignfeedback_editpdf\task\convert_submissions)" scheduled task looks for assignment submissions queued in assignfeedback_editpdf_queue table to convert them to PDF files. Normally this process works fine.

      However, if the file included in the student assignment submission contains extreme contents, e.g. an Excel file contains over 1 million lines, the conversion would exhaust server resource and eventually fail. See attached file for an example. Depending on the server configuration, this may not bring down the server, but it guarantees to stop the queue processing. Over time, the queue will become very long.

      This may not always be a problem, because as I understand, when a teacher tries to grade an assignment submission using PDF annotation, if the submitted file hasn't be converted, it will be converted on the fly, so in most cases (which are submitted waiting in queue, delayed by the failed conversion), the difference may only be a few more seconds' waiting time. But for the submission with the buggy file, conversion on the fly will fail as well, making it impossible for the teacher to grade the assignment submission.

      Some prevention mechanism would be preferred to:

      1. Allow conversion queue to be processed.
      2. Allow teachers to grade the assignment submission.

       

      We have seen this issue in a few different Moodle instances that we manage, in different Moodle versions, e.g. 3.1, 3.3, 3.4, 3.5. Other versions 

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              weilai Lai Wei
              Participants:
              Component watchers:
              Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan
              Votes:
              3 Vote for this issue
              Watchers:
              6 Start watching this issue

                Dates

                Created:
                Updated: