-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Check for handoff of upgraded segments #16162
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
Changes from all commits
e129773
561f5bb
2b1a54f
f9a148b
1183bb8
20e1672
21bd593
a93c6e2
b18d79c
4ba335c
84cf8b5
0599f3f
1c4859a
09b19de
cca38db
0ab2326
7e8be63
7b212a2
295ce55
5e084ea
4dc1e0e
2dc3b10
c83b7d9
aad03c9
248d614
a676b29
c72ad00
5d911a7
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -43,6 +43,7 @@ | |
| import org.apache.druid.java.util.emitter.EmittingLogger; | ||
| import org.apache.druid.java.util.http.client.response.BytesFullResponseHandler; | ||
| import org.apache.druid.java.util.http.client.response.HttpResponseHandler; | ||
| import org.apache.druid.metadata.PendingSegmentRecord; | ||
| import org.apache.druid.rpc.HttpResponseException; | ||
| import org.apache.druid.rpc.IgnoreHttpResponseHandler; | ||
| import org.apache.druid.rpc.RequestBuilder; | ||
|
|
@@ -57,7 +58,6 @@ | |
| import org.apache.druid.rpc.StandardRetryPolicy; | ||
| import org.apache.druid.rpc.indexing.SpecificTaskRetryPolicy; | ||
| import org.apache.druid.segment.incremental.ParseExceptionReport; | ||
| import org.apache.druid.segment.realtime.appenderator.SegmentIdWithShardSpec; | ||
| import org.jboss.netty.handler.codec.http.HttpMethod; | ||
| import org.jboss.netty.handler.codec.http.HttpResponseStatus; | ||
| import org.joda.time.DateTime; | ||
|
|
@@ -197,13 +197,12 @@ public ListenableFuture<Map<PartitionIdType, SequenceOffsetType>> getEndOffsetsA | |
| @Override | ||
| public ListenableFuture<Boolean> registerNewVersionOfPendingSegmentAsync( | ||
| String taskId, | ||
| SegmentIdWithShardSpec basePendingSegment, | ||
| SegmentIdWithShardSpec newVersionOfSegment | ||
| PendingSegmentRecord pendingSegmentRecord | ||
| ) | ||
| { | ||
| final RequestBuilder requestBuilder | ||
| = new RequestBuilder(HttpMethod.POST, "/pendingSegmentVersion") | ||
| .jsonContent(jsonMapper, new PendingSegmentVersions(basePendingSegment, newVersionOfSegment)); | ||
| .jsonContent(jsonMapper, pendingSegmentRecord); | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why do we need to change this API? The task side doesn't seem to need any info other than the base segment id and the upgraded segment id. Postponing this refactor until later might simplify this PR a bit.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We no longer have the original pending segment's SegmentIdWithShardSpec to continue using this API. |
||
|
|
||
| return makeRequest(taskId, requestBuilder) | ||
| .handler(IgnoreHttpResponseHandler.INSTANCE) | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.