Conversation
There was a problem hiding this comment.
CodeQL found more than 20 potential problems in the proposed changes. Check the Files changed tab for more details.
84db439 to
bd6cd75
Compare
...ns-core/s3-extensions/src/test/java/org/apache/druid/storage/s3/S3DataSegmentPullerTest.java
Fixed
Show fixed
Hide fixed
...ns-core/s3-extensions/src/test/java/org/apache/druid/storage/s3/S3DataSegmentPullerTest.java
Fixed
Show fixed
Hide fixed
...ns-core/s3-extensions/src/test/java/org/apache/druid/storage/s3/S3DataSegmentPullerTest.java
Fixed
Show fixed
Hide fixed
...sions-core/s3-extensions/src/test/java/org/apache/druid/data/input/s3/S3InputSourceTest.java
Fixed
Show fixed
Hide fixed
...sions-core/s3-extensions/src/test/java/org/apache/druid/data/input/s3/S3InputSourceTest.java
Fixed
Show fixed
Hide fixed
...-core/s3-extensions/src/main/java/org/apache/druid/storage/s3/output/S3StorageConnector.java
Fixed
Show fixed
Hide fixed
...-core/s3-extensions/src/main/java/org/apache/druid/storage/s3/output/S3StorageConnector.java
Fixed
Show fixed
Hide fixed
extensions-core/s3-extensions/src/main/java/org/apache/druid/storage/s3/S3DataSegmentMover.java
Fixed
Show fixed
Hide fixed
...exing-service/src/test/java/org/apache/druid/indexing/kinesis/KinesisRecordSupplierTest.java
Fixed
Show fixed
Hide fixed
...exing-service/src/test/java/org/apache/druid/indexing/kinesis/KinesisRecordSupplierTest.java
Fixed
Show fixed
Hide fixed
pom.xml
Outdated
There was a problem hiding this comment.
Should we upgrade to the latest aws v2 sdk version ?
There was a problem hiding this comment.
Yes I will bump it to 2.40 minor release. Wanted to minimize chances of upstream bugs by using a stable version for testing.
3e2092e to
e2afbe4
Compare
cloud/aws-common/src/main/java/org/apache/druid/common/aws/AWSCredentialsUtils.java
Show resolved
Hide resolved
cloud/aws-common/src/test/java/org/apache/druid/common/aws/AWSClientUtilTest.java
Outdated
Show resolved
Hide resolved
...ons-core/s3-extensions/src/main/java/org/apache/druid/storage/s3/S3ServerSideEncryption.java
Show resolved
Hide resolved
|
Very good job @jtuglu1! I have no objections, PR looks good from my perspective! |
|
👍 I'd still like to add 1-2 ITs that fully cover the newer S3 changes, but overall think it's basically there. |
e2afbe4 to
009f34e
Compare
|
Due to the criticality of the change, I think we should get 2 approvals for this PR. |
There was a problem hiding this comment.
Left a partial review.
Wanted to ask the following questions:
Did we test this patch on any cluster with the following things with we have s3 as the deep storage.
- Kinesis Ingestion.
- MSQ with Durable storage.
- MSQ select with durable storage as the destination.
- Segment getting nuked out.
- Task logs being viewable and getting purged out on S3.
- Segment ingestion.
Also have you tried this patch in any of the production clusters ?
|
|
||
| @Override | ||
| public void refresh() | ||
| private void refresh() |
There was a problem hiding this comment.
Who calls the refresh method now ?
There was a problem hiding this comment.
This refresh() is done now solely through a preexisting scheduled on the class. This is equivalent behavior as before, where FileSessionCredentialsProvider handles its own refresh internally on its scheduler. I don't believe the standalone method was used explicitly either; the v1 AWSCredentialsProviderChain didn't proactively call refresh() on providers during getCredentials() resolution — it just iterated through providers catching exceptions (from what I can tell).
...-indexing-service/src/main/java/org/apache/druid/indexing/kinesis/KinesisRecordSupplier.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Feels a bit weird that in the constructor we are calling these methods.
Should we call these in hasNext() ?
There was a problem hiding this comment.
I've moved out of ctor and into an initialize method. Iterators are expected to be single-threaded access, I'll make the initialized indicator thread-safe just in case.
| return true; | ||
| } | ||
|
|
||
| // Recognize s3sync.rb directory placeholders by MD5/ETag value. |
There was a problem hiding this comment.
Could you please share relevant docs for these placeholders ?
There was a problem hiding this comment.
Sure, I believe Gian added these a while back: #9098 (comment)
|
Hi @cryptoe. Yes, I'm testing this on our production clusters running Kafka + S3. We don't have production clusters using Kinesis. I've only been able to run tests locally. I wonder if you folks might have some Kinesis clusters to test the new logic out on? |
Thanks for this. Do keep us posted about the findings.
We also don't have active kinesis clusters but let me get back to you on this. |
009f34e to
4d435b6
Compare
|
Hi, update here: I've left this internally on a few of our clusters and things are working fine. Confirmed I've tested a superset of the following:
I will see if I can get the kinesis tested, but otherwise things are looking good. I will address rest of comments and then should be ready to go. |
64f5bf8 to
4266168
Compare
4266168 to
5aac98b
Compare
Closes #16903.
Description
Upgrade to AWS SDK v2.40.0. Looks like dependencies hdfs-storage + ranger have transitive dependencies on V1. Those will need to be excluded or upgraded as well. Core modules/extensions required for runtime are not reliant on V1.
Migrated to strictly synchronous APIs (to maintain backwards-compatibility with V1). A follow-up PR should be able to make use of async APIs where suitable. S3TransferManager is the only case where an async client may be used.
Hiccups
KinesisAggregatorV2not available in Maven – Maven via JitPack: amazon-kinesis-aggregator-2.0.2 has v1 code, amazon-kinesis-deaggregator-2.0.2 unavailable awslabs/kinesis-aggregation#120. Doesn't look like anything usesaggregation=true, so added a warning message. Seems like [FLINK-32097][Connectors/Kinesis] Implement support for Kinesis deaggregation flink-connector-aws#188 also ran into similar issues, but implemented their own unmerged approach. Per the warning on the https://github.com/awslabs/kinesis-aggregation repo, looks like data loss can occur anyways when using this mode: https://github.com/awslabs/kinesis-aggregation/blob/master/potential_data_loss.md so don't think that's really a desired feature anyways.Release note
Upgrade to AWS SDK v2.40.0
This PR has: