ericmerrill / moodle-mod_webexactivity

A Cisco WebEx activity module for Moodle
https://moodle.org/plugins/view.php?plugin=mod_webexactivity
9 stars 13 forks source link

Recording not appearing #22

Open sam-suresh opened 4 years ago

sam-suresh commented 4 years ago

I'm using Moodle 3.8 and Webex mod 3.8 2019120500.

My hosts are able to create and host meetings. The recording is set to available for students. However after the meeting the recording is not visible in the activity.

I also tried to set "Allow manage all recording" still recording not visible. If I login to the Webex web interface, I can see there is a recording for the said activity.

I also checked if the specific Moodle capability to view recording- but there is none. Is there anything to set in Webex Admin?

Am I missing anything?

eneskatitas commented 4 years ago

I have the same problem. moodle pulls user information but does not show records.

ericmerrill commented 4 years ago

Is your Moodle cron running? That is used to fetch recordings.

partecipazionelab commented 3 years ago

Same issue here. The cron are running correctly however no recordings are displayed inside moodle neither in the activity than in the site administration.

Is there any way to troubleshoot this issue?

ericmerrill commented 3 years ago

Can you paste the contends shown in the task log for the various webex recording sync tasks?

partecipazionelab commented 3 years ago

Dear Erik,

different tasks have different behaviours.

The task "update_recent_recordings" exits correctly but can't find any recording:

Execute scheduled task: Aggiorna le registrazioni terminate recentemente (mod_webexactivity\task\update_recent_recordings) ... started 11:30:44. Current memory use 13.3MB. Getting WebEx recordings for 05/24/2021 09:30:44 through 06/03/2021 21:30:44 ... used 0 dbqueries ... used 2.642322063446 seconds Scheduled task complete: Aggiorna le registrazioni terminate recentemente (mod_webexactivity\task\update_recent_recordings)

The task "update_medium_recordings" fails with an error (mysql has gone away) but only after not finding any recording (I have added some mtraces and prints here and there and what I understood is that I am getting the "No records found (000015)" every time)

Skip to main content Update medium past recordings Execute scheduled task: Aggiorna le registrazioni terminate da un medio periodo (mod_webexactivity\task\update_medium_recordings) ... started 11:28:28. Current memory use 13.3MB. Getting WebEx recordings for 02/03/2021 09:28:28 through 02/18/2021 09:28:27 Getting WebEx recordings for 02/18/2021 09:28:28 through 03/05/2021 09:28:27 Getting WebEx recordings for 03/05/2021 09:28:28 through 03/20/2021 09:28:27 Getting WebEx recordings for 03/20/2021 09:28:28 through 04/04/2021 09:28:27 Getting WebEx recordings for 04/04/2021 09:28:28 through 04/19/2021 09:28:27 Getting WebEx recordings for 04/19/2021 09:28:28 through 05/04/2021 09:28:27 Getting WebEx recordings for 05/04/2021 09:28:28 through 05/19/2021 09:28:27 Getting WebEx recordings for 05/19/2021 09:28:28 through 06/03/2021 09:28:27 Getting WebEx recordings for 06/03/2021 09:28:28 through 06/03/2021 21:28:28 ... used 0 dbqueries ... used 14.061851024628 seconds Scheduled task complete: Aggiorna le registrazioni terminate da un medio periodo (mod_webexactivity\task\update_medium_recordings)

Warning: mysqli::query(): MySQL server has gone away in /home/partecipazione/web/mysite.org/public_html/lib/dml/mysqli_native_moodle_database.php on line 1355

Warning: mysqli::query(): Error reading result set's header in /home/partecipazione/web/mysite.org/public_html/lib/dml/mysqli_native_moodle_database.php on line 1355 ... used 1 dbqueries ... used 14.064002037048 seconds Scheduled task failed: Aggiorna le registrazioni terminate da un medio periodo (mod_webexactivity\task\update_medium_recordings),Si è verificato un errore durante la scrittura nel database (MySQL server has gone away INSERT INTO mdlpp_task_log (type,component,classname,userid,timestart,timeend,dbreads,dbwrites,result,output,hostname,pid) VALUES(?,?,?,?,?,?,?,?,?,?,?,?) [array ( 0 => 0, 1 => 'mod_webexactivity', 2 => 'mod_webexactivity\task\update_medium_recordings', 3 => 0, 4 => 1622712508.9587801, 5 => 1622712523.0233231, 6 => 0, 7 => 0, 8 => 0, 9 => 'Execute scheduled task: Aggiorna le registrazioni terminate da un medio periodo (mod_webexactivity\task\update_medium_recordings) ... started 11:28:28. Current memory use 13.3MB. Getting WebEx recordings for 02/03/2021 09:28:28 through 02/18/2021 09:28:27 Getting WebEx recordings for 02/18/2021 09:28:28 through 03/05/2021 09:28:27 Getting WebEx recordings for 03/05/2021 09:28:28 through 03/20/2021 09:28:27 Getting WebEx recordings for 03/20/2021 09:28:28 through 04/04/2021 09:28:27 Getting WebEx recordings for 04/04/2021 09:28:28 through 04/19/2021 09:28:27 Getting WebEx recordings for 04/19/2021 09:28:28 through 05/04/2021 09:28:27 Getting WebEx recordings for 05/04/2021 09:28:28 through 05/19/2021 09:28:27 Getting WebEx recordings for 05/19/2021 09:28:28 through 06/03/2021 09:28:27 Getting WebEx recordings for 06/03/2021 09:28:28 through 06/03/2021 21:28:28 ... used 0 dbqueries ... used 14.061851024628 seconds Scheduled task complete: Aggiorna le registrazioni terminate da un medio periodo (mod_webexactivity\task\update_medium_recordings) ', 10 => 'vesta.mysite.org', 11 => 141220, )]) Debug info: MySQL server has gone away INSERT INTO mdlpp_task_log (type,component,classname,userid,timestart,timeend,dbreads,dbwrites,result,output,hostname,pid) VALUES(?,?,?,?,?,?,?,?,?,?,?,?) [array ( 0 => 0, 1 => 'mod_webexactivity', 2 => 'mod_webexactivity\task\update_medium_recordings', 3 => 0, 4 => 1622712508.9587801, 5 => 1622712523.0233231, 6 => 0, 7 => 0, 8 => 0, 9 => 'Execute scheduled task: Aggiorna le registrazioni terminate da un medio periodo (mod_webexactivity\task\update_medium_recordings) ... started 11:28:28. Current memory use 13.3MB. Getting WebEx recordings for 02/03/2021 09:28:28 through 02/18/2021 09:28:27 Getting WebEx recordings for 02/18/2021 09:28:28 through 03/05/2021 09:28:27 Getting WebEx recordings for 03/05/2021 09:28:28 through 03/20/2021 09:28:27 Getting WebEx recordings for 03/20/2021 09:28:28 through 04/04/2021 09:28:27 Getting WebEx recordings for 04/04/2021 09:28:28 through 04/19/2021 09:28:27 Getting WebEx recordings for 04/19/2021 09:28:28 through 05/04/2021 09:28:27 Getting WebEx recordings for 05/04/2021 09:28:28 through 05/19/2021 09:28:27 Getting WebEx recordings for 05/19/2021 09:28:28 through 06/03/2021 09:28:27 Getting WebEx recordings for 06/03/2021 09:28:28 through 06/03/2021 21:28:28 ... used 0 dbqueries ... used 14.061851024628 seconds Scheduled task complete: Aggiorna le registrazioni terminate da un medio periodo (mod_webexactivity\task\update_medium_recordings) ', 10 => 'vesta.mysite.org', 11 => 141220, )] Backtrace:

!!! Si è verificato un errore durante la lettura del database !!!

Debug info: MySQL server has gone away SELECT FROM mdlpp_task_scheduled WHERE classname = ? [array ( 0 => '\mod_webexactivity\task\update_medium_recordings', )] Error code: dmlreadexception Stack trace: line 486 of /lib/dml/moodle_database.php: dml_read_exception thrown

Fatal error: Uncaught Error: Call to a member function real_escape_string() on null in /home/partecipazione/web/mysite.org/public_html/lib/dml/mysqli_native_moodle_database.php:1140 Stack trace:

0 /home/partecipazione/web/mysite.org/public_html/lib/dml/mysqli_native_moodle_database.php(1269): mysqli_native_moodle_database->emulate_boundparams('SELECT RELEASE...', Array)

1 /home/partecipazione/web/mysite.org/public_html/lib/dml/moodle_database.php(1671): mysqli_native_moodle_database->get_recordssql('SELECT RELEASE...', Array, 0, 0)

2 /home/partecipazione/web/mysite.org/public_html/lib/classes/lock/mysql_lock_factory.php(161): moodle_database->get_recordsql('SELECT RELEASE...', Array)

3 /home/partecipazione/web/mysite.org/public_html/lib/classes/lock/lock.php(107): core\lock\mysql_lock_factory->release_lock(Object(core\lock\lock))

4 /home/partecipazione/web/mysite.org/public_html/lib/classes/lock/lock.php(121): core\lock\lock->release()

5 [intern in /home/partecipazione/web/mysite.org/public_html/lib/dml/mysqli_native_moodle_database.php on line 1140

Back to scheduled tasks

ericmerrill commented 3 years ago

So those errors at the bottom are interesting. They indicate that mysql maybe timing out or something while the cron is running.

I would try using something like postman to send a request to the webex endpoint to see if you get a useful response:

<?xml version="1.0" encoding="utf-8"?>
<serv:message xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:serv="http://www.webex.com/schemas/2002/06/service">
  <header>
    <securityContext>
      <webExID>WEBEXADMINUSERNAME</webExID>
      <password>WEBEXADMINPASSWORD</password>
      <siteName>SITENAME</siteName>
    </securityContext>
  </header>
  <body>
    <bodyContent xsi:type="java:com.webex.service.binding.ep.LstRecording">
      <listControl>
        <startFrom>0</startFrom>
        <maximumNum>100</maximumNum>
      </listControl>
      <returnSessionDetails>false</returnSessionDetails>
    </bodyContent>
  </body>
</serv:message>

The endpoint url should be https://SITENAME.webex.com/WBXService/XMLService

partecipazionelab commented 3 years ago

Dear Erik,

I've initially tried to send out a request with your XML but I got this error:

<serv:header>
        <serv:response>
            <serv:result>FAILURE</serv:result>
            <serv:reason>Sorry, no record found</serv:reason>
            <serv:gsbStatus>PRIMARY</serv:gsbStatus>
            <serv:exceptionID>000015</serv:exceptionID>
        </serv:response>
    </serv:header>

Reading through the documentation, I've realized that your call is missing this parameter:

<serviceTypes>
        <serviceType>MeetingCenter</serviceType>
   </serviceTypes>

With this I am correctly getting the list of recordings. Yet the response does not contain the key <ep:sessionKey> and therefore I still get stuck shortly after. I've red and tried every possible combination of parameters and I got to the conclusion that the API must have been changed because even in the examples from CISCO, you never get the sessionKey in the response (this is because 1 session key might have more than 1 recording associated and therefore you can search recordings by the sessionKey and get multiple results). The only way to associate a recording to an actual concluded session, is probably the "ConfID" which is not stored in the database.

Am I missing something here? Please note that I am not, by any mean, a software developer so my troubleshooting probably lacks of method......

ericmerrill commented 3 years ago

I find it odd that serviceTypes is seemingly required. Their docs indicate it is optional.

What happens if you change returnSessionDetails to true (with or without serviceTypes set)? Do you get the session key info?