brandboat commented on code in PR #16524:
URL: https://github.com/apache/kafka/pull/16524#discussion_r1667234615
##########
group-coordinator/src/main/java/org/apache/kafka/coordinator/group/GroupCoordinatorConfig.java:
##########
@@ -213,82 +214,151 @@ public class GroupCoordinatorConfig {
*/
public static final int CLASSIC_GROUP_NEW_MEMBER_JOIN_TIMEOUT_MS = 5 * 60
* 1000;
- private final AbstractConfig config;
+ private final int numThreads;
+ private final int appendLingerMs;
+ private final int consumerGroupSessionTimeoutMs;
+ private final int consumerGroupHeartbeatIntervalMs;
+ private final int consumerGroupMaxSize;
+ private final List<ConsumerGroupPartitionAssignor> consumerGroupAssignors;
+ private final int offsetsTopicSegmentBytes;
+ private final int offsetMetadataMaxSize;
+ private final int classicGroupMaxSize;
+ private final int classicGroupInitialRebalanceDelayMs;
+ private final int classicGroupMinSessionTimeoutMs;
+ private final int classicGroupMaxSessionTimeoutMs;
+ private final long offsetsRetentionCheckIntervalMs;
+ private final long offsetsRetentionMs;
+ private final int offsetCommitTimeoutMs;
+ private final ConsumerGroupMigrationPolicy consumerGroupMigrationPolicy;
+ private final CompressionType offsetTopicCompressionType;
+ private final int offsetsLoadBufferSize;
+ private final int offsetsTopicPartitions;
+ private final short offsetsTopicReplicationFactor;
+ private final short offsetCommitRequiredAcks;
+ private final int consumerGroupMinSessionTimeoutMs;
+ private final int consumerGroupMaxSessionTimeoutMs;
+ private final int consumerGroupMinHeartbeatIntervalMs;
+ private final int consumerGroupMaxHeartbeatIntervalMs;
public GroupCoordinatorConfig(AbstractConfig config) {
- this.config = config;
+ this.numThreads =
config.getInt(GroupCoordinatorConfig.GROUP_COORDINATOR_NUM_THREADS_CONFIG);
+ this.appendLingerMs =
config.getInt(GroupCoordinatorConfig.GROUP_COORDINATOR_APPEND_LINGER_MS_CONFIG);
+ this.consumerGroupSessionTimeoutMs =
config.getInt(GroupCoordinatorConfig.CONSUMER_GROUP_SESSION_TIMEOUT_MS_CONFIG);
+ this.consumerGroupHeartbeatIntervalMs =
config.getInt(GroupCoordinatorConfig.CONSUMER_GROUP_HEARTBEAT_INTERVAL_MS_CONFIG);
+ this.consumerGroupMaxSize =
config.getInt(GroupCoordinatorConfig.CONSUMER_GROUP_MAX_SIZE_CONFIG);
+ this.consumerGroupAssignors =
config.getConfiguredInstances(GroupCoordinatorConfig.CONSUMER_GROUP_ASSIGNORS_CONFIG,
ConsumerGroupPartitionAssignor.class);
Review Comment:
> @brandboat Have you added test for CONSUMER_GROUP_ASSIGNORS_CONFIG?
I think It's already there before I submit this pr.
> For another, could you make consumerGroupAssignors immutable?
Will do
--
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]