https://gitlab.synchro.net/main/sbbs/-/commit/6bb3b32af0bffc0f7ff22e53
Modified Files:
docs/v322_new.md exec/gopherservice.js
Log Message:
gopherservice: list a message area a page at a time
Listing a sub read every header with get_all_msg_headers() and returned
one line per message, so each request for a large sub (a crawler's, say)
read and sent the whole area: 1.9 s just to read the headers of a 159,537-message sub, and a 159,537-line reply.
List the newest messages first, max_msgs at a time (default 100), by
walking the index offsets down from the end, then link to the next page
with the new selector sub:<code>:before:<number>, which binary-searches
the index for its starting point. The new -maxmsgs=N option sets the page
size; 0 lists the whole area as before. Message selectors
(sub:<code>:<number>) are unchanged.
The first page of that sub now takes 0.07 s. Paging through three subs
listed every message exactly once, newest first.
Part of #1340.
Co-Authored-By: Claude Opus 5.5 <
noreply@anthropic.com>
---
þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net