Skip to content

Perf Bug: When viewing a single photo, a gigantic XML file is loaded every single time #520

Open
@thenickname

Description

When viewing a photo, in the background also an XML is requested that seems to contain the complete directory structure info (endpoint remote.php/dav/files/<user>/Photos/). This same file is being requested over and over again every single time I click on a photo to open the viewer.

Now, as my /Photos/ folder contains a lot of files (roughly 15000), the XML response is gigantic: somewhere around 15 MB. This means, that every single time when I click on a photo, the browser redundantly requests that same huge XML file. This same file, btw. is also requested when first entering the directoy. So why requesting it over and over again?

The result, of course is unbearably slow response times and lag when trying to view a single photo from within a big directory.

To Reproduce
Steps to reproduce the behavior:

  1. Open browser network tab in dev tools and look for remote.php/dav/files/<user>/Photos/
  2. Go to a folder with lots of files
  3. Click on a photo to trigger the viewer
  4. Note, that a gigantic XML file is requested and that the photo is not shown until the XML is fully loaded
  5. Note that when closing the viewer and opening another photo, this same request of the XML file is fired again
  6. Note, how slow displaying an image becomes due to the redundant loading of the XML file
  7. Note, that when using the arrow buttons to switch to another photo, the XML is not requested again. It only happens during activation of the viewer

Expected behavior
Image in viewer loads quickly

Screenshots
grafik

Possible quick fix / workaround
The image file itself loads rather quickly. Maybe it is possible to display the image and not wait until the entirety of the XML is loaded (in case the redundant requests of the same XML file serve a purpose)

Metadata

Assignees

No one assigned

    Labels

    1. to developAccepted and waiting to be taken care ofbugSomething isn't workingmediumMedium priorityperformancesPerformances issues and optimisations

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions