Skip to content

Cache per-version artifacthub response in Helm ecosystem - #1783

Merged
andrew merged 1 commit into
mainfrom
helm-dedupe-version-fetch
Aug 12, 2026
Merged

Cache per-version artifacthub response in Helm ecosystem#1783
andrew merged 1 commit into
mainfrom
helm-dedupe-version-fetch

Conversation

@andrew

@andrew andrew commented Aug 12, 2026

Copy link
Copy Markdown
Member

Helm#versions_metadata and Helm#dependencies_metadata both fetched /api/v1/packages/helm/{repo}/{name}/{version} for each new version (once for content_url, again for dependencies), so a package with N new versions made 1 + 2N artifacthub requests per sync. At rate_limit: 1 that still produced ~10 429/min because each helm sync was averaging ~25 calls.

fetch_version_details memoizes the per-version response on the ecosystem instance so both callers share one fetch, halving the per-version request count to 1 + N. Errors are cached as nil so a failed version fetch is not retried within the same job.

versions_metadata and dependencies_metadata both fetched
/api/v1/packages/helm/{repo}/{name}/{version} for each new version,
so a package with N new versions made 1 + 2N artifacthub requests
per sync. At rate_limit=1 that still produced ~10 429/min because
each helm sync was making ~25 calls.

fetch_version_details memoizes the per-version response on the
ecosystem instance so both callers share one fetch, halving the
per-version request count to 1 + N. Errors are cached as nil so a
failed version fetch is not retried within the same job.
@andrew
andrew merged commit 055af3b into main Aug 12, 2026
7 checks passed
@andrew
andrew deleted the helm-dedupe-version-fetch branch August 12, 2026 14:30
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