-
Notifications
You must be signed in to change notification settings - Fork 3
feat: support not enabling aws default features #46
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
Conversation
4835f18 to
7d126f2
Compare
jlizen
left a comment
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.
Core implementation looks good but need:
- confirmation of testing of existing functionality without new features
- cleanup of the example code w/r/t conditional compilation noise
| - "1.85" # Current MSRV due to Cargo MSRV feature | ||
| - stable | ||
| flags: | ||
| - "--all-features" |
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.
I was surprised to see that these passed out of box, but I guess we don't actually test any network calls? Looks like we validate metadata parsing only, and nothing to do with s3?
Probably having an integration test that validates these directly e2e using real auth would be nice, but separate scope. I can cut an issue (low priority).
Without that, can you confirm that you've manually validated that the existing functionality (without the new features) works properly? IE no regression for old APIs.
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.
yea, the tests don't have network access. I'm not in the mood of setting up an AWS account so I can do AWS-in-the-loop tests.
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.
No worries, we can maybe do #47 someday
From offline - thanks for confirming that you tested locally e2e and existin gfunctionality works.
CHANGELOG.md
Outdated
|
|
||
| - add support for stopping the profiler | ||
| - make native memory profiling interval configurable | ||
| - add Cargo features to allow not enabling AWS/reqwest default features |
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.
this should go in unreleased section no? also can we add the new feature name(s) into this verbiage?
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.
I thought the 0.1.5 release failed. Apparently it fake failed. Will remove it from the changelog, and release-plz will re-insert it.
| .args(["local", "bucket"]), | ||
| ))] | ||
| struct Args { | ||
| #[cfg(feature = "s3-no-defaults")] |
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.
All of these feature flags make the example very hard to follow. Can we move all s3 features into their own struct, #[derive(Arg)] on it, and flatten it from the parent struct? That way we can just feature gate the one field in the top-level struct.
examples/simple/main.rs
Outdated
| args.bucket_owner, | ||
| args.profiling_group, | ||
| ) { | ||
| #[cfg(feature = "s3-no-defaults")] |
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.
This is pretty unreadable as well. Can we refactor to only need one of each cfg flag (enabled vs not enabled)?
For instance, add a struct that we derive default on and use default implementation for if feature is disabled. Or delegate to a function.
📬 Issue #, if available:
✍️ Description of changes:
🔏 By submitting this pull request