apoorvmittal10 commented on code in PR #22436:
URL: https://github.com/apache/kafka/pull/22436#discussion_r3340083345
##########
group-coordinator/src/main/java/org/apache/kafka/coordinator/group/modern/share/ShareGroupConfigProvider.java:
##########
@@ -98,4 +98,17 @@ public ShareGroupAutoOffsetResetStrategy
autoOffsetReset(String groupId) {
.flatMap(GroupConfig::shareAutoOffsetReset)
.orElseGet(GroupConfig::defaultShareAutoOffsetReset);
}
+
+ /**
+ * The method is used to get the name of the configured DLQ topic on the
share group. If the group config
+ * is present, then the value from the group config is used. Otherwise,
the default value is used.
+ *
+ * @param groupId The group id for which the DLQ topic name is to be
fetched.
+ * @return DLQ topic name for the share group.
+ */
+ public String errorsDLQTopicName(String groupId) {
+ return manager.groupConfig(groupId)
+ .map(GroupConfig::errorsDLQTopicName)
+ .orElse(GroupConfig.ERRORS_DEADLETTERQUEUE_TOPIC_NAME_DEFAULT); //
In case no group config
Review Comment:
But when there is never default to be supported then why do you need to
return the default value from this method?
--
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]