MapColonies / MapColonies/infra-tools
Persistent result cache and request concurrency cap
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 0
- Forks
- 0
- Avg merge
- 22h 52m
- Merged PRs (30d)
- 13
Description
## Parent
#17
## What to build
The feature stops costing a registry request every time a file is opened. Rate limits are a real design constraint here, not a footnote — Docker Hub counts manifest fetches against pull limits, roughly 100 per six hours anonymously per IP address and 200 on an authenticated free account, and a checkmark on every good image in every file would spend that budget fast.
Results persist across window reloads, with expiry that differs by verdict. Confirmed results last on the order of a day, because a tag that resolved once is effectively immutable. Not-found expires in about a minute, because the developer is very likely about to push exactly that tag and should not stay red all day waiting. Unverifiable expires in tens of seconds. That asymmetry is what makes the whole design affordable: the steady state of a green workspace costs roughly one request per image per day rather than one per file open.
At most six requests in flight at once, so a values file with many references does not saturate the connection.
The chart metadata watcher becomes a cache eviction rather than only a re-run, so bumping `appVersion` invalidates that chart's entries instead of being masked by a day-long positive result.
## Acceptance criteria
- [ ] Reopening a file with unchanged references issues no registry requests
- [ ] Cached results survive a window reload
- [ ] A confirmed result is reused for about a day
- [ ] A not-found result is re-checked after about a minute, so a freshly pushed tag goes green without a manual refresh
- [ ] An unverifiable result is re-checked after tens of seconds
- [ ] No more than six requests are in flight at once for a file with many references
- [ ] Changing `appVersion` evicts that chart's cached entries rather than relying on expiry
## Blocked by
- #24 — Chart context: file scope and `appVersion`-derived tags
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the blocked chart-context work in #24, then trace the existing registry-request path used when a values file is opened. No files or tests are named in this issue; completion is defined by the acceptance criteria: persistent verdict-specific expiry, reload survival, six-request concurrency, and appVersion-driven eviction.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, typescript
- Domain
- devtools, performance
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100