-
Notifications
You must be signed in to change notification settings - Fork 181
SNOW-2032706: Implement AWS SDK strategy for GCS #2228
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
base: master
Are you sure you want to change the base?
SNOW-2032706: Implement AWS SDK strategy for GCS #2228
Conversation
ca55888
to
862b01a
Compare
src/main/java/net/snowflake/client/jdbc/cloud/storage/GCSAccessStrategyAwsSdk.java
Outdated
Show resolved
Hide resolved
} else { | ||
logger.debug("no credentials provided, configuring bucket client without credentials"); | ||
amazonS3Builder.withCredentials( | ||
new AWSStaticCredentialsProvider(new BasicAWSCredentials("", ""))); | ||
} |
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 don't think this code branch can ever succeed. Can we throw an exception instead?
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.
It was implemented for the GCS part. Not sure how to trigger it
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.
It used to be possible to have signed URLs in ~2022, but this case should not happen now. This should really never happen. I would rather remove the check altogether with the assumption that the token is always present, instead of this fallback to the empty string.
src/main/java/net/snowflake/client/jdbc/cloud/storage/AwsSdkGCPSigner.java
Show resolved
Hide resolved
src/main/java/net/snowflake/client/jdbc/cloud/storage/GCSAccessStrategyAwsSdk.java
Outdated
Show resolved
Hide resolved
862b01a
to
b06f65a
Compare
src/main/java/net/snowflake/client/jdbc/cloud/storage/GCSAccessStrategyAwsSdk.java
Outdated
Show resolved
Hide resolved
src/main/java/net/snowflake/client/jdbc/cloud/storage/GCSAccessStrategyAwsSdk.java
Outdated
Show resolved
Hide resolved
src/main/java/net/snowflake/client/jdbc/cloud/storage/AwsSdkGCPSigner.java
Show resolved
Hide resolved
src/main/java/net/snowflake/client/jdbc/cloud/storage/GCSAccessStrategyAwsSdk.java
Outdated
Show resolved
Hide resolved
src/main/java/net/snowflake/client/jdbc/cloud/storage/GCSAccessStrategyAwsSdk.java
Outdated
Show resolved
Hide resolved
b06f65a
to
a64035d
Compare
Can you add tests for the new class please? |
c06b030
to
33f17e6
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.
LGTM
Overview
SNOW-2032706
Implement strategy to access GCS bucket via XML api and virtual style URLs on SPCS using AWS SDK.
Pre-review self checklist
master
branchmvn -P check-style validate
)mvn verify
and inspecttarget/japicmp/japicmp.html
)SNOW-XXXX:
External contributors - please answer these questions before submitting a pull request. Thanks!
What GitHub issue is this PR addressing? Make sure that there is an accompanying issue to your PR.
Issue: #NNNN
Fill out the following pre-review checklist:
@SnowflakeJdbcInternalApi
(note that public/protected methods/fields in classes marked with this annotation are already internal)Please describe how your code solves the related issue.
Please write a short description of how your code change solves the related issue.