-
-
Notifications
You must be signed in to change notification settings - Fork 6
TopicConfigBuilder does not produce the expected configuration for a compacted topic #179
Copy link
Copy link
Closed
Labels
Description
Describe the bug
Trying to create a topic with the following parameters:
- cleanup.policy=compact,delete
- delete.retention.ms=100
- segment.ms=100
- min.cleanable.dirty.ratio=0.01
fails with an exception.
To Reproduce
Steps to reproduce the behavior:
- Execute the following snippet:
var topic = new NewTopic(topicName, partitions, replicationFactor);
topic = topic.Configs(TopicConfigBuilder.Create().WithCleanupPolicy(TopicConfig.CleanupPolicy.Compact | TopicConfig.CleanupPolicy.Delete)
.WithDeleteRetentionMs(100)
.WithMinCleanableDirtyRatio(0.01)
.WithSegmentMs(100));- and use the result to create the topic like in:
Properties props = AdminClientConfigBuilder.Create().WithBootstrapServers(serverToUse).ToProperties();
using (IAdmin admin = KafkaAdminClient.Create(props))
{
// Create a compacted topic
CreateTopicsResult result = admin.CreateTopics(coll);
}- See errors:
MinCleanableDirtyRatioexpect adouble,CleanupPolicyis not recognized.
Expected behavior
The topic shall be created with the expected parameters.
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
- OS: Windows 10
- Version: latest
Additional context
N/A
Reactions are currently unavailable