Skip to content

feat(cache): Make http cache providers respect cache-control header #33848

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 12 commits into from
Mar 6, 2025

Conversation

zharinov
Copy link
Collaborator

@zharinov zharinov commented Jan 26, 2025

Changes

This PR adds support for skipping cache when cache-control response header miss the public value.

In package-level caching, it's important to separate private packages, so this check is enabled by default.

Context

Documentation (please check one with an [x])

  • I have updated the documentation, or
  • No documentation update is required

How I've tested my work (please select one)

I have verified these changes via:

  • Code inspection only, or
  • Newly added/modified unit tests, or
  • No unit tests but ran on a real repository, or
  • Both unit tests + ran on a real repository

@zharinov zharinov requested review from viceice and rarkins January 26, 2025 13:47
Copy link
Member

@viceice viceice left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will it cause less caching/ more requests?

can you please expand the PR description why this is needed?

@zharinov
Copy link
Collaborator Author

will it cause less caching/ more requests?

No, current functionality will work as ususal

@zharinov zharinov requested a review from viceice January 26, 2025 18:29
# Conflicts:
#	lib/util/http/cache/package-http-cache-provider.spec.ts
@zharinov zharinov requested a review from viceice February 10, 2025 14:51
@zharinov
Copy link
Collaborator Author

Please merge it

@rarkins rarkins enabled auto-merge February 22, 2025 12:59
@rarkins rarkins added this pull request to the merge queue Mar 6, 2025
Merged via the queue into renovatebot:main with commit a7831ab Mar 6, 2025
39 checks passed
@rarkins rarkins deleted the feat/cache-provider-cache-control branch March 6, 2025 16:02
@renovate-release
Copy link
Collaborator

🎉 This PR is included in version 39.189.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

ivankatliarchuk added a commit to ivankatliarchuk/renovate that referenced this pull request Mar 7, 2025
* main: (84 commits)
  chore(deps): update dependency pdm to v2.22.4 (main) (renovatebot#34672)
  fix(helmv3): non http alias in Helm (renovatebot#34634)
  fix: improve coverage (renovatebot#34667)
  feat: new manager pixi (renovatebot#34400)
  feat(cache): Make http cache providers respect `cache-control` header (renovatebot#33848)
  chore(deps): update docker/dockerfile:1.14.0 docker digest to 4c68376 (main) (renovatebot#34660)
  chore(deps): update dependency @vitest/eslint-plugin to v1.1.36 (main) (renovatebot#34659)
  fix(gomod): read contraints from new `go.mod` (renovatebot#34655)
  fix: optimize type checks (renovatebot#34654)
  fix(manager/composer): use `intersects()` instead of `matches()` to compare tool constraint (renovatebot#34256)
  chore: fix Debugger launchers (renovatebot#34647)
  fix(devbox): use new --no-install flag to prevent devbox from using the nix store (renovatebot#34257)
  chore(deps): update dependency pnpm to v10.5.2 (main) (renovatebot#34648)
  chore(deps): update dependency @vitest/eslint-plugin to v1.1.35 (main) (renovatebot#34644)
  docs(managers): clarify multi-line mode is not supported in regex custom manager (renovatebot#34571)
  chore(deps): update dependency @vitest/eslint-plugin to v1.1.34 (main) (renovatebot#34639)
  fix(global): import config file as url (renovatebot#34637)
  feat: add RENOVATE_ prefix to Github com token and env host rules (renovatebot#34568)
  chore(deps): update dependency pnpm to v10.5.1 (main) (renovatebot#34631)
  feat(config): support `.mjs` config files (renovatebot#34626)
  ...
mjobst-necls pushed a commit to mjobst-necls/renovate that referenced this pull request Mar 17, 2025
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 6, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants