commits
Add a 100ms pause after every 5 pages when more pages remain
to reduce load and avoid overwhelming consumers
Send events as JSON arrays to improve throughput (batch size 50).
Increase PAGE_SIZE to 500 and send queued events in batches.
Update client to handle batched messages and reduce ping interval
to 30s. Adjust progress/logging to report events every 500.
Add pagination error handling and logging, ensure client paginating
state is cleared and errors are sent to clients. Minor refactor and
formatting cleanup.
Cache drizzle-kit in the image to ensure the migrate command is
available,
and add host volume mounts for the SQLite DB, WAL, and SHM files so the
database state is persisted across container restarts.
Replace denoland/deno with node:24, add DENO_INSTALL and PATH env
vars, and update CMD to invoke the deno binary
Include the Authorization header in a logger.warn when admin auth
fails to assist debugging and trace unauthorized requests.
Log unauthorized access attempts
Accept a comma-separated "dids" query param on WebSocket connect and
store per-client DID lists. Apply the DID filter to the initial
paginated query (using drizzle-orm inArray) and to broadcastEvent so
clients only receive matching events. Also fix bufferedAmount typing in
backpressure checks, reduce PAGE_DELAY_MS to 3ms, and remove the
periodic heartbeat timer.
Add pacing and diagnostic features to server and client
- Client: SLOW_MODE, heartbeat handling, reduced log spam, ping timing,
and message rate/progress metrics
- Server: reduce PAGE_SIZE, add MESSAGE_DELAY_MS, heartbeat interval,
safer send with error logging, more frequent backpressure checks and
clearer 1006 diagnostics
Introduce safeSend and waitForBackpressure to avoid write errors and
throttle when socket.bufferedAmount exceeds a 1MB limit. Replace direct
socket.send calls with safeSend, periodically check backpressure during
pagination, and queue/flush logic. Enhance connection close and error
logs to include codes, reasons, and client state for easier debugging.
Serialize batch flushes with a flushPromise and requeue failed
events to enable retries. Clear timers and flush immediately when
batch is full. Reduce batch size to 100 and increase timeout to
100ms.
Update SQLite PRAGMAs: busy_timeout=30000, wal_autocheckpoint=1000,
temp_store=MEMORY
Set PAGE_SIZE to 500 and PAGE_DELAY_MS to 0, add YIELD_EVERY_N_PAGES
to yield periodically between pages. Remove the small initial connection
delay and reduce per-page logging frequency to once every 10 pages.
Increase BATCH_SIZE to 200 and lower BATCH_TIMEOUT_MS to 50. Remove
verbose ping/pong log messages.
Create idx_title_artist_album_albumartist on tracks (title, artist,
album, album_artist) and update the Drizzle schema, migration snapshot,
and journal
Replace paginated listRecords calls with getRepo and parse CAR blocks
using @ipld/car and @ipld/dag-cbor. Add related dependencies (and
multiformats) and update bun.lock (apps/cli version 0.2.0 → 0.3.0).
Call useFollowsQuery for neighbour DIDs (excluding the current DID) and
merge returned follow DIDs into the local follows set using useEffect
Remove tracks array from playlist schema and update types, PKL, and
lexicon files accordingly
Implement /1/submit-listens with Token auth, validate body via zod, and
asynchronously match tracks then publish scrobbles for 'single' listens.
Add /1/validate-token and several stub ListenBrainz-compatible routes.
Add Listenbrainz zod schemas and TypeScript types. Use handle from
getDidAndHandle for token validation.
Capitalize "DID" in the handle error and remove URL underline styling
Exit with a clear error when neither ROCKSKY_HANDLE/ROCKSKY_IDENTIFIER
nor ROCKSKY_PASSWORD is set, showing guidance and a link to create app
passwords. Use default empty strings for these env vars so envalid won't
throw. Also adjust CLI help banner/link formatting and add the hono
dependency
After putScrobbleRecord, poll the database for the scrobble URI. Retry
up to 40 times with a 600ms delay between attempts and log an error if
the record is not detected.
Publish the newest scrobble ID after saving so subscribers can react.
Refactor JS subscriber to call updateUris(ctx, did) and
refreshScrobbles, use the tables namespace for DB queries, add
hashing/logging, and limit syncs to 5 recent scrobbles.
Rename query data to rawNowPlayings and deduplicate by a composite key
(trackId-did-createdAt). Remove the structuralSharing override and use
the composite value as the React key for StoryContainer to ensure
stable, unique list items.
Use _.uniqBy to filter duplicate entries, add lodash import, and update
bun.lock accordingly
When ROCKSKY_IDENTIFIER and ROCKSKY_PASSWORD are present, resolve DID
and handle via the agent, create the user in the local DB if missing,
and print the profile URL. Otherwise fall back to the existing token
file flow.
Accept a comma-separated "dids" query param on WebSocket connect and
store per-client DID lists. Apply the DID filter to the initial
paginated query (using drizzle-orm inArray) and to broadcastEvent so
clients only receive matching events. Also fix bufferedAmount typing in
backpressure checks, reduce PAGE_DELAY_MS to 3ms, and remove the
periodic heartbeat timer.
Add pacing and diagnostic features to server and client
- Client: SLOW_MODE, heartbeat handling, reduced log spam, ping timing,
and message rate/progress metrics
- Server: reduce PAGE_SIZE, add MESSAGE_DELAY_MS, heartbeat interval,
safer send with error logging, more frequent backpressure checks and
clearer 1006 diagnostics
Introduce safeSend and waitForBackpressure to avoid write errors and
throttle when socket.bufferedAmount exceeds a 1MB limit. Replace direct
socket.send calls with safeSend, periodically check backpressure during
pagination, and queue/flush logic. Enhance connection close and error
logs to include codes, reasons, and client state for easier debugging.
Set PAGE_SIZE to 500 and PAGE_DELAY_MS to 0, add YIELD_EVERY_N_PAGES
to yield periodically between pages. Remove the small initial connection
delay and reduce per-page logging frequency to once every 10 pages.
Increase BATCH_SIZE to 200 and lower BATCH_TIMEOUT_MS to 50. Remove
verbose ping/pong log messages.
Implement /1/submit-listens with Token auth, validate body via zod, and
asynchronously match tracks then publish scrobbles for 'single' listens.
Add /1/validate-token and several stub ListenBrainz-compatible routes.
Add Listenbrainz zod schemas and TypeScript types. Use handle from
getDidAndHandle for token validation.