WWBN / AVideo

Create Your Own Broadcast Network With AVideo Platform Open-Source. OAVP OVP
https://avideo.tube/AVideo_OpenSource
Other
1.9k stars 971 forks source link

Zoom recorder plugin pulling files multiple times. #5500

Closed nathantolene closed 3 years ago

nathantolene commented 3 years ago

The zoomrecorderplugin is pulling the same files over and over again. The files are largeish and will get larger as I put the box into production. Not sure what is causing it to re-download the same files. Ex. I have a meeting that has ended and zoom shows 3 different files Speaker view, Gallery view, and audio-only. Every minute(s) it will redownload each file and drop it on my encoder, which takes some time to encode and then my queue just continues to get larger. In my most recent attempt, the plugin downloaded the same files 12 times.

thanks!

DanielnetoDotCom commented 3 years ago

Hi

the streamer only requests a download when it is notified by Zoom, check if you do not have multiple webhooks on it (Event notification endpoint URL)

make sure you keep just one

nathantolene commented 3 years ago

Hi,

Thanks for the reply and I love your product.

I checked and I only have one webhook enabled.

But I think I have figured out what is happening. The webhook from zoom is kicked off for each recording when it finishes encoding on the zoom cloud. As zoom makes multiple versions of the meeting (speaker view, gallery view, active speaker, active speaker with screen share, audio-only, and an audio transcript). Each time one of the versions is made the webhook gets a notification and the plugin tries to download all the versions. So say I have all the versions being encoded by zoom the plugin will go out and try and download them for each notification ie. 6 different versions 6 notifications 36 files. The zoom webhook description reads as it should only notify when ALL recordings are complete but that's not what is happening. I looked up the API reference on zoom and it reads as follows "The Recording Completed event is triggered every time a recording of a meeting or webinar becomes available to view and/or download." So the label "All recordings have completed" is misleading.

I'm not sure how to address this, as it seems your plugin is working as designed. Would it be possible to trigger the retrieval of recordings via a cron job? Any help is appreciated.

DanielnetoDotCom commented 3 years ago

I just checked into the zoomrecorder code and it saves with a webhook event recording.completed

I guess you can change something on zoom side and make it work properly

nathantolene commented 3 years ago

So I changed the zoom side to only record one version of the meeting, and it's still downloading the same file 3 times.

nathantolene commented 3 years ago

OK, I'm reopening this, as I hope I have more info that could help.
After looking at the logs on the zoom webhooks side it does seem that it is notifying avideo 4 times about the recordings being completed. 1st when encoding is completed, 5 mins later, 20 mins after that, and then 60 mins after that. Unless the webhook gets a response signal of 200 from avideo. It does seem that (zoom webhook logs) avideo is sending a response signal but after a long period time.
At what point does avideo give the 200 response? After encoding?

thanks!!

DanielnetoDotCom commented 3 years ago

the zoom is only triggered by the webhook.

try to check the access log and filter the webhook to see when does this happens.

nathantolene commented 3 years ago

So looking at the access log (which I have not been looking at before) the 200 post is going out to zoom at the moment of download. Zoom webhook logs show sometimes a 200 post and most times a 500 error. Any ideas?

DanielnetoDotCom commented 3 years ago

All that returns 500 error check the Apache error log and the streamer error log at the same time as the access log error

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

nathantolene commented 3 years ago

Just wanted to say I did discover the underlying issue. It was not with your plug-in or your code, but a networking issue on my end.
Thank you for taking the time to help me with troubleshooting this problem.
I love your product and thank you for all the work you do.

God Bless.