lucasbru commented on code in PR #15525:
URL: https://github.com/apache/kafka/pull/15525#discussion_r1537350070
##########
clients/src/main/java/org/apache/kafka/clients/consumer/internals/events/ListOffsetsEvent.java:
##########
@@ -32,8 +32,7 @@
* {@link OffsetAndTimestamp} found (offset of the first message whose
timestamp is greater than
* or equals to the target timestamp)
*/
-public class ListOffsetsEvent extends
CompletableApplicationEvent<Map<TopicPartition, OffsetAndTimestamp>> {
-
+public class ListOffsetsEvent<T> extends
CompletableApplicationEvent<Map<TopicPartition, T>> {
Review Comment:
How about using two separate events `ListOffsets` and
`ListOffsetsWithTimestamps`? We could save the "requireTimestamps" boolean and
the use of generics here, which I think would simplify the code. That would
also get rid of some `unchecked` warnings, that you are currently suppressing,
I'd expect.
##########
clients/src/main/java/org/apache/kafka/clients/consumer/internals/MembershipManagerImpl.java:
##########
@@ -411,8 +411,8 @@ public int memberEpoch() {
public void onHeartbeatSuccess(ConsumerGroupHeartbeatResponseData
response) {
if (response.errorCode() != Errors.NONE.code()) {
String errorMessage = String.format(
- "Unexpected error in Heartbeat response. Expected no
error, but received: %s",
Review Comment:
nit: White space change in a file you aren't otherwise changing, I'd avoid
it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]