-
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
Fixed a bug in HttpPostEmitter leading to ClassCastException #8205
Conversation
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.
@ArtyomyuS could you please apply the same changes in comments as I did in https://github.com/apache/incubator-druid/pull/8207/files?
@leventov I updated. Thanks. |
@Test | ||
@SuppressWarnings("unchecked") | ||
public void testRecoveryEmitAndReturnBatch() | ||
throws InterruptedException, IOException, NoSuchFieldException, IllegalAccessException |
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.
Side note: in Druid, we usually just add throws Exception
if there is more than one. I don't think there may be any harm in doing that.
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.
Thanks for the patch with a test!
…8205) * Issue 8206: Fixed class cast exception in case of batch recovery * Issue 8206: Added HttpPostEmitterTest license header * Issue 8206: Updated comments accordingly to code review. * Issue 8206: Updated HttpPostEmitterTest accordingly to new modifications.
…8220) * Issue 8205: Fixed class cast exception in case of batch recovery * Issue 8205: Added HttpPostEmitterTest license header * Issue 8205: Updated comments accordingly to code review. * Issue 8205: Updated HttpPostEmitterTest accordingly to new modifications.
Fixes #8204
Description
Fix
HttpPostEmitter
class cast exception while trying to recover a batch. The fix is straightforward just changedInteger
check for a batch number to recover intoLong
.This PR has:
For reviewers: the key changed/added classes in this PR are
HttpPostEmitter
andHttpPostEmitterTest
.(Add this section in big PRs to ease navigation in them for reviewers.)