Skip to content

Persist negative package and build records with bbolt - #1411

Merged
ije merged 1 commit into
mainfrom
ije/persistent-negative-cache
Sep 17, 2026
Merged

ije merged 1 commit into
mainfrom
ije/persistent-negative-cache

Conversation

@ije

@ije ije commented Sep 17, 2026

Copy link
Copy Markdown
Member

Persist negative install and build results in bbolt so repeated requests skip oversized archives and known missing paths. GitHub size records are scoped to the exact branch, tag, or hash; npm size records use the exact version. Missing paths are cached per exact package version and build variant, while package-not-found records expire after 10 minutes.

Store records in <workDir>/negative-cache.db, clear matching records on package purge, and reject cached build misses before they enter the build queue. Apply both download and expanded archive limits to npm packages. Move disk housekeeping to server startup so creating a router does not leave background work running.

Validation:

  • go test ./server/...
  • Targeted race tests for negative-cache persistence and expiry, npm/GitHub size limits, path and version isolation, purge behavior, and build queues.

@ije
ije merged commit 2a1db30 into main Sep 17, 2026
12 of 15 checks passed
@ije
ije deleted the ije/persistent-negative-cache branch September 17, 2026 07:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant