Skip to content
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

[QOL-8518] [QOL-8612] Multiple fixes (Redis ignore exceptions, speed improvements, cleanup s3 acl flags) #80

Merged
merged 61 commits into from
Feb 11, 2022

Conversation

duttonw
Copy link
Member

@duttonw duttonw commented Feb 9, 2022

  • Add plugin features to manage S3 visibility
    • Ensure old resources can be hidden via property flag
    • Allow non-referenced resources be removed just like an upload with same name.
  • Don't crash on full redis server when link download is being requested (ignore error on put/get/delete)
  • Skip initialising s3 sub-system when url already exists in redis when download link is requested
  • Cache is_private flag for dataset to skip after_package updates when no change occurred. (Since Validation and XLoader Plugins causes dataset/package to be updated from enqueued jobs)

ThrawnCA and others added 30 commits January 31, 2022 13:20
- link resources may create a FileStorage object representing a zero-length binary stream, but they should not be treated as uploads
- attributes cannot be asserted directly, use 'hasattr' with assert_false
- combine near-identical tests that only use different resource inputs
[QOL-8518] handle link resources using placeholder empty FileStorage
- this makes it easier to wipe the 'all objects' cache when uploading a new object
… ckan this is fine but with Archiver, Validator and QA the meta data is Huge
…date-all-resource-visibility

Feature/qol 8612 add cli to update all resource visibility
- ACLs can have a very long expiry, since they should only change when a resource or dataset is changed,
will will override the cache settings anyway.
ThrawnCA and others added 20 commits February 7, 2022 15:44
QOL-8612 make non-current S3 objects private
- otherwise the Redis helper will ignore it
- don't provide a 'queue' arg unless we have a value
- 'on_failure' and 'failure_ttl' require newer rq, so they only work on CKAN 2.9+
- 'title' should be passed at the top level, not injected into 'kwargs' or 'rq_kwargs'
- looks like the default is set before our tests can intercept the config
- CKAN 2.7 can't accept 'rq_kwargs' at all
- even CKAN 2.9 doesn't have new enough RQ to accept 'on_failure'
QOL-8612 fix enqueuing of visibility updates
Copy link
Contributor

@ThrawnCA ThrawnCA left a comment

Choose a reason for hiding this comment

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

Looks good to me, but then again I wrote most of it, so we should get someone else's opinion for it to be a proper peer review.

@ThrawnCA ThrawnCA merged commit 661f720 into master Feb 11, 2022
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.

3 participants