sjhajharia commented on code in PR #20180:
URL: https://github.com/apache/kafka/pull/20180#discussion_r2231662307
##########
server/src/main/java/org/apache/kafka/server/share/session/ShareSessionKey.java:
##########
@@ -21,23 +21,12 @@
import java.util.Objects;
-public class ShareSessionKey {
- private final String groupId;
- private final Uuid memberId;
-
+public record ShareSessionKey(String groupId, Uuid memberId) {
public ShareSessionKey(String groupId, Uuid memberId) {
this.groupId = Objects.requireNonNull(groupId);
this.memberId = Objects.requireNonNull(memberId);
}
- public String groupId() {
- return groupId;
- }
-
- public Uuid memberId() {
- return memberId;
- }
-
@Override
public int hashCode() {
Review Comment:
Sorry, I was reading the code a bit wrong. I see the point you are trying to
make. I have updated the PR accordingly.
--
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]