-
Notifications
You must be signed in to change notification settings - Fork 2
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
PB-1126: Removed the update_interval field from item and collections model #527
base: develop
Are you sure you want to change the base?
Conversation
caacb28
to
cb15243
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yay, code is getting simpler 👍 nice!
app/stac_api/views/mixins.py
Outdated
parts = [i.strip() for i in cache_control_header.split(',')] | ||
args = {i.split('=')[0].strip(): i.split('=')[-1].strip() for i in parts if i} | ||
return {k: True if v == k else v for k, v in args.items()} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
seeing this here I definitely think we should have some validation for that field, see comment here: #528 (comment)
fc1942c
to
48e3b44
Compare
0a05bd8
to
ace467f
Compare
…model Now use the previously new cache_control_header field on the collection model to overwrite the default cache settings of assets, items and collections endpoints. Note that endpoints that aggregate several collections like the search endpoint and the collections list endpoint have now caching disabled to avoid any caching issues and to keep the code simple.
48e3b44
to
6914de5
Compare
Due to performance issue we removed the
update_interval
field on the item and collection level and replace it by a single filedcache_control_header
on the collection level.Now use the previously new cache_control_header field on the collection model
to overwrite the default cache settings of assets, items and collections
endpoints. Note that endpoints that aggregate several collections like the
search endpoint and the collections list endpoint have now caching disabled
to avoid any caching issues and to keep the code simple.