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

If recording is removed or updated in the server, the value is not updated in Moodle

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 4.0
    • 4.0
    • BigBlueButton
    • MOODLE_400_STABLE
    • MOODLE_400_STABLE
    • Hide
      1. Create a course C1.
      2. Add two BBB activities, A1 and A2 (with default values).
      3. Go to activity A1.
      4. Click on the “Join session” button and create a recording.
        • Press the recording button, wait for a few seconds (10 to 15).
        • Click the 3-dots at the top-right corner and exit the session by ending it.
      5. After a few minutes, run cron (we have to wait until the recording is available).
        • Confirm that after refreshing the page, the list of recordings shows a new recording.
      6. Verify you can playback the recording
        • Take note of the recordingID that appears as the last segment in the URL. (E.g. 65ecbe7db33b3a652a7c5df7ded146687f50e8de-1637605116096).
      7. Go to activity A2.
      8. Repeat steps 4 - 6.
      9. Prepare the external app api-mate:
        • On a different tab or browser, open api-mate: https://mconf.github.io/api-mate/
        • Make sure the credentials are the same used in BBB (before merging MDL-73200, the default server is test-install in both Moodle and API-Mate and you don't need to change anything).
      10. Unpublish the A1 recording outside Moodle, using api-mate:
        • Remove the random meetingID and replace the recordID for A1 with the one obtained from the actual recording on playback (e.g. 65ecbe7db33b3a652a7c5df7ded146687f50e8de-1637605116096).
        • Click the link to publish the recording, close to the "publishRecordings" text on the right side (which will actually unpublish it because by default publish is unchecked).
      11. Delete the A2 recording outside Moodle, using api-mate:
        • Remove the random meetingID and replace the recordID for A2 with the one obtained from the actual recording on playback (e.g. f7ded146687f50e8de-163760511609665ecbe7db33b3a652a7c5d).
        • Click the link to delete the recording, close to the "deleteRecordings" text on the right side.
      12. Wait 5 minutes so the cache expires.
      13. Go to activity A1 in Moodle.
      14. Confirm the recording is shown with no link for playback and the eye slashed icon is displayed on the "Toolbar" column.
      15. Got to activity A2 in Moodle.
      16. Confirm the recording is not shown in the table.
      Show
      Create a course C1. Add two BBB activities, A1 and A2 (with default values). Go to activity A1. Click on the “Join session” button and create a recording. Press the recording button, wait for a few seconds (10 to 15). Click the 3-dots at the top-right corner and exit the session by ending it. After a few minutes, run cron (we have to wait until the recording is available). Confirm that after refreshing the page, the list of recordings shows a new recording. Verify you can playback the recording Take note of the recordingID that appears as the last segment in the URL. (E.g. 65ecbe7db33b3a652a7c5df7ded146687f50e8de-1637605116096). Go to activity A2. Repeat steps 4 - 6. Prepare the external app api-mate : On a different tab or browser, open api-mate:  https://mconf.github.io/api-mate/ Make sure the credentials are the same used in BBB (before merging MDL-73200 , the default server is test-install in both Moodle and API-Mate and you don't need to change anything). Unpublish the A1 recording outside Moodle, using api-mate: Remove the random meetingID and replace the recordID for A1 with the one obtained from the actual recording on playback (e.g. 65ecbe7db33b3a652a7c5df7ded146687f50e8de-1637605116096). Click the link to publish the recording, close to the "publishRecordings" text on the right side (which will actually unpublish it because by default publish is unchecked). Delete the A2 recording outside Moodle, using api-mate: Remove the random meetingID and replace the recordID for A2 with the one obtained from the actual recording on playback (e.g. f7ded146687f50e8de-163760511609665ecbe7db33b3a652a7c5d). Click the link to delete the recording, close to the "deleteRecordings" text on the right side. Wait 5 minutes so the cache expires. Go to activity A1 in Moodle. Confirm the recording is shown with no link for playback and the eye slashed icon is displayed on the "Toolbar" column. Got to activity A2 in Moodle. Confirm the recording is not shown in the table.

      Since the way recordings are fetched was redesigned for 2.5, and it is now based on a cache, there is a flaw that shows up when the recordings are managed outside Moodle.

      This normally happens when automated management actions ( in the BBB servers) are performed on recordings, but can be easily be reproduced using API-mate.

      How to reproduce it:

      • Create a new activity with only default values, launch into BBB and record the meeting
      • Wait until the recording shows up and playback the recording
      • Take note of the recordingID that appears as the last segment in the URL. It should look like this (65ecbe7db33b3a652a7c5df7ded146687f50e8de-1637605116096)
      • Open api-mate https://mconf.github.io/api-mate/, change the BBB credentials, remove the random meetingID and replace the recordID with the one obtained from the actual recording.. Then click the link to publish the recording (which will actually unpublish it)
      • Go back to moodle and try to playback the recording again, you should get a 404
      • On Moodle unpublish the recoding, now it is in sync again
      • On Moodle publish the recording again, and On API-mate click on the link to delete the recording
      • Go back to moodle and try to playback the recording again, you should get a 404
      • On Moodle unpublish the recoding, now it is in sync again, but since the recording is deleted the data shown now is incorrect

      Here is a video that describes how to reproduce the problem and why is this a problem [^contrib-8777.mp4]

       

      I should point out that the solution is not necessary to destroy the recording in Moodle  when the request comes as deleted, because in some cases there will be no delete, but the playback format may be replaced.So, what we need is a mechanism to expire the cache, so a getRecordings is performed again to keep the data in sync

        1. MDL-73198_step 14.png
          MDL-73198_step 14.png
          85 kB
        2. MDL-73198_step 16.png
          MDL-73198_step 16.png
          81 kB
        3. MDL-73198_step 5_a1.png
          MDL-73198_step 5_a1.png
          87 kB
        4. MDL-73198_step 5_a2.png
          MDL-73198_step 5_a2.png
          88 kB
        5. MDL-73198_step 6_a1.png
          MDL-73198_step 6_a1.png
          161 kB
        6. MDL-73198_step 6_a2.png
          MDL-73198_step 6_a2.png
          161 kB
        7. MDL-73198.patch
          8 kB

            jfederico Jesus Federico
            vmdef Victor Déniz Falcón
            Laurent DAVID Laurent DAVID
            Victor Déniz Falcón Victor Déniz Falcón
            Angelia Dela Cruz Angelia Dela Cruz
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 2 hours, 30 minutes
                2h 30m

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.