broncowdd / BoZoN

Minimalist Drag & drop file sharing app (version 2.4 build 15)
Other
284 stars 47 forks source link

Possible to speed up directory listing? #229

Open ambipur76 opened 7 years ago

ambipur76 commented 7 years ago

Directory listing seems to be slow on my machine. I am running Debian Jessie on an Intel Atom N270 based home server (I know, it is an old design ...) My web server is lighttpd and PHP version is 5.6.30. APCU support (cache) is enabled with defult configuration. PHP is configured as following: memory_limit = 128M, post_max_size and upload_max_filesize are both configured to 512M. PHP 7 would help much or not? Client machine is on gigabit LAN in a distance not more than 10 meters.

broncowdd commented 7 years ago

The directory listing can be a bit slow with a large amount of files. However, the next version will include a cache system and will list files much quicker ;-)

ambipur76 commented 7 years ago

As I see in your code first the user's whole directory tree is loaded and it is listed in the browser only after getting the whole tree. Suggestion: first try to get a list without subdirectories and display it. After it in the background you could get the whole list. Second possibility: linux commans could also be used to get the directory list, but this case the web server user should have sudo rights to run this command. This can be a secirity risk, but this would be the fastest. Do you have plans when to release the next version?