You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Line 277 of main/views.py
def update(request):
call_command("videoscan") # Could potentially be very slow, blocking request.
We do a blocking call to videoscan on every update page request. If a scan is actually necessary, this can take a potentially long time.
Proposed fix:
Trigger this check through AJAX. Have some text indicating the scan is proceeding, and either update the page (or message the user that a refresh is required) if something in the scan was actually found.
Priority:
Low priority. It's a confusing user experience (just hangs for a while) for something that's very infrequent. Otherwise, it's a slight performance hit, but no real worry there.
@gimick This would be something good to check on the Rpi, however; if performance there is poor, we should increase the priority.
The text was updated successfully, but these errors were encountered:
Not sure if this was always so slow on the RPi, or if it has to do with some of the recent signals/cache invalidation stuff, but with a new DB (no VideoFiles), but 2500 videos on disk, the update page takes over 5 minutes to load for the first time.
This definitely got slower. I would suggest two changes:
Run videoscan on server startup, to avoid webpages from hanging. It would be clearer to the admin what's going on. This shouldn't be too much work, as there's a wrapper around the server starting already.
In order for videoscan to do bulk creation, it will need to call into the signal directly from videoscan.
Line 277 of main/views.py
def update(request):
call_command("videoscan") # Could potentially be very slow, blocking request.
We do a blocking call to videoscan on every update page request. If a scan is actually necessary, this can take a potentially long time.
Proposed fix:
Trigger this check through AJAX. Have some text indicating the scan is proceeding, and either update the page (or message the user that a refresh is required) if something in the scan was actually found.
Priority:
Low priority. It's a confusing user experience (just hangs for a while) for something that's very infrequent. Otherwise, it's a slight performance hit, but no real worry there.
@gimick This would be something good to check on the Rpi, however; if performance there is poor, we should increase the priority.
The text was updated successfully, but these errors were encountered: