-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Use headers to be part of the cache key #2753
Comments
…eOnlyResponseCodes per method and the ability to use headers as part of the cache key (#2753 #2763) (#2754) Example of a use-case: We want to cache put/post methods that receive 401 or 403. Next time the same request is received we will return the response from the cache unless they change the authorization or tenant headers. This PR contains: - Cache support for all of the methods, it can be set from the endpoint designer - Each cache endpoint can have its own list of ResponseCodes that will override the main API cache list for this endpoint - Added a list of headers per endpoint that will be inserted (with header values) into the cache key - Some refactoring to reuse some methods - Tests More info can be found in the feature requests #2753 and #2763 Closes #2753 Closes #2763
…eOnlyResponseCodes per method and the ability to use headers as part of the cache key (#2753 #2763) (#2754) Example of a use-case: We want to cache put/post methods that receive 401 or 403. Next time the same request is received we will return the response from the cache unless they change the authorization or tenant headers. This PR contains: - Cache support for all of the methods, it can be set from the endpoint designer - Each cache endpoint can have its own list of ResponseCodes that will override the main API cache list for this endpoint - Added a list of headers per endpoint that will be inserted (with header values) into the cache key - Some refactoring to reuse some methods - Tests More info can be found in the feature requests #2753 and #2763 Closes #2753 Closes #2763
@buger On endpoint designer we can only enable cache
|
@ilijabojanovic and @buger , |
@ilijabojanovic can't replicate it. So far works for me. Also, your video does not show error as well. |
Done |
…eOnlyResponseCodes per method and the ability to use headers as part of the cache key (#2753 #2763) (#2754) Example of a use-case: We want to cache put/post methods that receive 401 or 403. Next time the same request is received we will return the response from the cache unless they change the authorization or tenant headers. This PR contains: - Cache support for all of the methods, it can be set from the endpoint designer - Each cache endpoint can have its own list of ResponseCodes that will override the main API cache list for this endpoint - Added a list of headers per endpoint that will be inserted (with header values) into the cache key - Some refactoring to reuse some methods - Tests More info can be found in the feature requests #2753 and #2763 Closes #2753 Closes #2763 (cherry picked from commit dcc58b1)
Is your feature request related to a problem? Please describe.
We are working in a multi-tenancy environment. The tenant is defined by a custom header.
We want the ability to manage the cache per tenant.
Describe the solution you'd like
We would like to have a field per API that can be populated by header names.
The headers values should be part of the cache key so in case of changed value a new cache key will be generated.
Describe alternatives you've considered
None
Additional context
Nope
The text was updated successfully, but these errors were encountered: