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

Sending large file fails because of php 30 seconds timeout

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.7.3, 2.8, 2.9.2
    • Fix Version/s: None
    • Component/s: Files API
    • Labels:
    • Testing Instructions:
      Hide
      1. To simulate a slow connection I suggest using Chrome and turning on throttling in the Developer Tools.
      2. Create an assignment.
      3. Submit multiple large files as the students. Be sure they are large enough that the throttled download will take more than 30 seconds.
      4. As the teacher try to Download all submissions.
        The download will error with a PHP timeout.

      If enough data was uploaded to the assignment the timeout may occur durring the compressing of the files into a zip. see MDL-40245

      Show
      To simulate a slow connection I suggest using Chrome and turning on throttling in the Developer Tools. Create an assignment. Submit multiple large files as the students. Be sure they are large enough that the throttled download will take more than 30 seconds. As the teacher try to Download all submissions. The download will error with a PHP timeout. If enough data was uploaded to the assignment the timeout may occur durring the compressing of the files into a zip. see MDL-40245
    • Workaround:
      Hide

      add a call to core_php_time_limit::raise(); before sending the temporary file.

      Show
      add a call to core_php_time_limit::raise(); before sending the temporary file.
    • Affected Branches:
      MOODLE_27_STABLE, MOODLE_28_STABLE, MOODLE_29_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-48220_master

      Description

      If an assignment has a lot of large files in it. Download all submissions may take longer than the default 30 second php script time limit. This makes the download fail.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              swit Matthew G. Switlik
              Reporter:
              swit Matthew G. Switlik
              Peer reviewer:
              Simey Lameze Simey Lameze
              Participants:
              Component watchers:
              Matteo Scaramuccia, Andrew Lyons, Dongsheng Cai, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              3 Vote for this issue
              Watchers:
              8 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: