Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Improve the performance of the tool-versions version resolution

Aperta
#7,908 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
docker, typescript

Direzione di ricerca

Start by reading the changes in #7825 and #7826, then inspect the tool-versions resolution paths and the follow-ups to #7887. Measure which resolution paths and parsing costs affect actual install-tool requests before choosing an optimization; done means reducing unnecessary resolution cost while preserving fresh releases and the documented fallback behavior.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

What would you like containerbase to do?

Keep the version resolution through the tool-versions data cheap, as hosted Renovate runs install-tool millions of times a day and every run starts without a cache.

Costs per run since #7825 and #7826, for tools without their own resolver (exact versions read nothing):

  • latest or a missing version: one HTTP request to the online tool-versions data, tens to hundreds of ms, up to the 30 s timeout when the network stalls, plus an embedded read as fallback
  • a partial version: one embedded read and parse, plus the HTTP request unless the embedded data lists the version
  • an embedded read: JSON.parse and the zod check of one <tool>.json, below 0.5 ms typical, ~8 ms for the largest file (renovate.json)

Ideas

  • skip the online lookup when the embedded data is recent enough, needs the release time of the data (containerbase/tool-versions#149)
  • measure the zod check at runtime again and drop it if it matters (the image build already checks the data)
  • check which versions Renovate requests from install-tool (exact, partial or latest) to know which paths matter
  • measure the cost of the follow-ups of #7887 once more tools resolve through the data
  • any cache of the online data that outlives one resolve (per process, or on disk like HttpService.download()) needs an expiry time, so long running processes pick up new releases; today getJson() doesn't cache and the ToolVersionsService cache only lasts one resolve
  • warn when the v1 format is deprecated (with its removalDate) in the root index.json; the online lookup fetches v1/<tool>.json directly and after a removal would silently fall back to the embedded data on the 404. Not on every run, eg. only after a 404 or at most once a day

Drafted by Claude Opus 5.5 (Claude Code) for @viceice.

Lingua principale
TypeScript
Stelle
58
Fork
65
Merge medio
11h 54m
PR unite (30g)
428

Preparare l'ambiente

Apri in Codespaces

Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.

  • Include un Dockerfile o un file Docker Compose
  • Nessun modello di pull request
  • Nessuna guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di containerbase/base

Tutte le issue di containerbase/base

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.