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

Finalise deprecation of repository sync methods

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.7.3, 2.8.1
    • Fix Version/s: 2.9
    • Component/s: Files API, Repositories
    • Labels:
    • Testing Instructions:
      Hide
      1. Check that behat and php unit passed on the nightly server (If there are errors relating to repositories, this issue may likely be the cause) http://nightly.test.in.moodle.com:8080/view/Master/
      2. Go to Home ► My profile ► My private files
      3. Use a core repository plugin (e.g. wikimedia) to add an image to my private files
      4. Ensure that the file is successfully added, and has a filesize
      5. Use a repository plugin from the plugins DB to add an image to my private files
      6. Create a "page" activity module on a course.
      7. Insert an image from a core repository plugin
      8. Ensure it is inserted with no errors and displays correctly
      9. Insert an image from a repository plugin from the plugins DB
      10. Ensure it is inserted with no errors and displays correctly
      Show
      Check that behat and php unit passed on the nightly server (If there are errors relating to repositories, this issue may likely be the cause) http://nightly.test.in.moodle.com:8080/view/Master/ Go to Home ► My profile ► My private files Use a core repository plugin (e.g. wikimedia) to add an image to my private files Ensure that the file is successfully added, and has a filesize Use a repository plugin from the plugins DB to add an image to my private files Create a "page" activity module on a course. Insert an image from a core repository plugin Ensure it is inserted with no errors and displays correctly Insert an image from a repository plugin from the plugins DB Ensure it is inserted with no errors and displays correctly
    • Affected Branches:
      MOODLE_27_STABLE, MOODLE_28_STABLE
    • Fixed Branches:
      MOODLE_29_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-42166-master
    • Sprint:
      BACKEND Sprint 19
    • Issue size:
      Medium

      Description

      In MDL-42016 the repositories API for synchronising external references was simplified.

      Remove completely:
      stored_file::set_filesize()
      stored_file::replace_content_with()
      repository::reset_caches()
      repository::sync_external_file()

      In repository::__call() remove code related to functions:
      sync_individual_file()
      get_file_by_reference()
      get_reference_file_lifetime()

      probably there will be nothing left in __call() at all so it can be deleted.

      In repository::sync_reference() remove all code starting from comment "Backward compatibility (Moodle 2.3-2.5)". Replace it with "return false;"

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              johno John Okely
              Reporter:
              marina Marina Glancy
              Peer reviewer:
              Ankit Agarwal
              Integrator:
              Dan Poltawski
              Tester:
              Dan Poltawski
              Participants:
              Component watchers:
              Matteo Scaramuccia, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                11/May/15