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

OPcache support

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Critical
    • Resolution: Fixed
    • 2.5
    • 2.6
    • Libraries
    • MOODLE_25_STABLE
    • MOODLE_26_STABLE
    • w28_MDL-40415_m26_opcache
    • Hide

      I do not really know what to test here:

      1/ configure opcache
      2/ try install, upgrade, etc.
      3/ run phpunit tests
      4/ test web services
      5/ do whatever else

      Maybe it would be best if every HQ developer installed opcache and used it for master development.

      Note: you can disable the opcache easily in your moodle config.php using (you can not enable it there!)

      ini_set('opcache.enable', 0);
      

      Show
      I do not really know what to test here: 1/ configure opcache 2/ try install, upgrade, etc. 3/ run phpunit tests 4/ test web services 5/ do whatever else Maybe it would be best if every HQ developer installed opcache and used it for master development. Note: you can disable the opcache easily in your moodle config.php using (you can not enable it there!) ini_set('opcache.enable', 0);

    Description

      http://php.net/manual/en/book.opcache.php

      We need:

      • documentation
      • required + recommended settings
      • automatic reset and disabling

      Why? Because that is the only officially supported opcode cache in PHP 5.5.x (and even earlier versions via PECL).


      php.ini settings:

      [opcache]
      opcache.enable = 1
      opcache.memory_consumption = 128
      opcache.max_accelerated_files = 4000
      opcache.revalidate_freq = 60
       
      ; Required for Moodle
      opcache.use_cwd = 1
      opcache.validate_timestamps = 1
      opcache.save_comments = 1
      opcache.enable_file_override = 0
       
      ; If something does not work in Moodle
      ;opcache.revalidate_path = 1 ; May fix problems with include paths
       
      ; Experimental for Moodle 2.6 and later
      ;opcache.fast_shutdown = 1
      ;opcache.enable_cli = 1 ; Speeds up CLI cron
      ;opcache.load_comments = 0 ; May lower memory use, might not be compatible with addons and other apps.
      

      Attachments

        Issue Links

          Activity

            People

              skodak Petr Skoda
              skodak Petr Skoda
              Damyon Wiese Damyon Wiese
              Dan Poltawski Dan Poltawski
              David Woloszyn, Huong Nguyen, Jake Dallimore, Meirza, Michael Hawkins, Raquel Ortega, Safat Shahin, Stevani Andolo
              Votes:
              1 Vote for this issue
              Watchers:
              14 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                18/Nov/13