-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Add datasegment copier interface and s3 impl #17430
base: master
Are you sure you want to change the base?
Add datasegment copier interface and s3 impl #17430
Conversation
3cd35c3
to
a2534fb
Compare
a2534fb
to
49c7941
Compare
Thanks for the PR @jtuglu-netflix ! |
); | ||
} | ||
catch (Exception e) { | ||
Throwables.propagateIfInstanceOf(e, AmazonServiceException.class); |
Check notice
Code scanning / CodeQL
Deprecated method or constructor invocation Note
Throwables.propagateIfInstanceOf
} | ||
catch (Exception e) { | ||
Throwables.propagateIfInstanceOf(e, AmazonServiceException.class); | ||
Throwables.propagateIfInstanceOf(e, SegmentLoadingException.class); |
Check notice
Code scanning / CodeQL
Deprecated method or constructor invocation Note
Throwables.propagateIfInstanceOf
|
||
private MockAmazonS3Client() | ||
{ | ||
super(new AmazonS3Client(), new NoopServerSideEncryption()); |
Check notice
Code scanning / CodeQL
Deprecated method or constructor invocation Note test
AmazonS3Client.AmazonS3Client
af56f75
to
ec80d2f
Compare
This PR creates a DataSegmentCopier interface, and corresponding S3DataSegmentCopier implementation. The goal here is to provide an alternative for those wishing to move datasegments around between clusters. These classes are used in a CLI tool for copying datasources between clusters that was similar to the older, now-deprecated migration tool and plan to release that to open-source soon as well.
Description
Currently, Druid only provides a means of moving (deleting from the source) a datasegment from one deep storage location to another. This adds flexibility to copy instead, while refactoring the code between
S3DataSegmentMover
andS3DataSegmentCopier
to be shared insideS3DataSegmentTransferUtility
.Release note
Key changed/added classes in this PR
extensions-core/s3-extensions/src/main/java/org/apache/druid/storage/s3/S3DataSegmentCopier.java
extensions-core/s3-extensions/src/main/java/org/apache/druid/storage/s3/S3DataSegmentMover.java
extensions-core/s3-extensions/src/main/java/org/apache/druid/storage/s3/S3DataSegmentTransferUtility.java
extensions-core/s3-extensions/src/test/java/org/apache/druid/storage/s3/S3DataSegmentCopierTest.java
processing/src/main/java/org/apache/druid/segment/loading/DataSegmentCopier.java
This PR has: