Opened 8 years ago

Closed 6 years ago

#1079 closed defect (fixed)

I2PSnark directory listing is slow

Reported by: zzz Owned by: zzz
Priority: trivial Milestone: 0.9.23
Component: apps/i2psnark Version:
Keywords: performance Cc:
Parent Tickets: Sensitive: no


I2PSnarkServlet.getListHTML() iterates through the files in the directory, not the files in the torrent, and then calls Storage.remaining() which iterates through the files in the torrent, thus O(n2) and noticeable in big directories (500+).

Can we collapse this? getListHTML() was adapted from Jetty to display a directory. Do we need to report on unknown files in the directory or can we just report on the torrent files directly?


Change History (2)

comment:1 Changed 7 years ago by str4d

Keywords: performance added
Milestone: 0.9.12

comment:2 Changed 6 years ago by zzz

Milestone: 0.9.23
Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.