Skip to content

Commit cae74c5

Browse files
author
Tom Jorissen
authored
[Issue 1105][pulsaradmin] fix AutoTopicCreation for type non-partitioned (#1107)
Fixes #1105 ### Motivation To allow setting the AutoTopicCreation policy to non-partitioned it is required to not send the partitions parameter, by making Partitions a pointer instead of an int this is possible. ### Modifications Change the type of Partitions in TopicAutoCreationConfig from int to *int
1 parent 3a1a766 commit cae74c5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pulsaradmin/pkg/utils/topic_auto_creation_config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,5 @@ package utils
2020
type TopicAutoCreationConfig struct {
2121
Allow bool `json:"allowAutoTopicCreation"`
2222
Type TopicType `json:"topicType"`
23-
Partitions int `json:"defaultNumPartitions"`
23+
Partitions *int `json:"defaultNumPartitions"`
2424
}

0 commit comments

Comments
 (0)