chia7712 commented on code in PR #21758:
URL: https://github.com/apache/kafka/pull/21758#discussion_r2936934349
##########
group-coordinator/src/main/java/org/apache/kafka/coordinator/group/GroupConfigManager.java:
##########
@@ -64,6 +64,11 @@ public void updateGroupConfig(String groupId, Properties
newGroupConfig) {
throw new InvalidRequestException("Group name can't be empty.");
}
+ if (newGroupConfig.isEmpty()) {
Review Comment:
Please refactor the following code by lambda function to avoid race condition
https://github.com/apache/kafka/blob/cae9e80343958c87df5d1486f315649f4cecb7a5/core/src/main/java/kafka/server/share/SharePartition.java#L3043
for example:
```java
ShareGroupAutoOffsetResetStrategy offsetResetStrategy =
groupConfigManager.groupConfig(groupId)
.map(GroupConfig::shareAutoOffsetReset)
.orElse(GroupConfig.defaultShareAutoOffsetReset());
```
--
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]