-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Description
Describe the bug
Unable to create partitioned topic which is a substring of an existing topic
To Reproduce
- Create a partitioned topic using below command
./pulsar-admin topics create-partitioned-topic persistent://public/default/create_substring_topic -p 1 - Create another partitioned topic using below command. The topic name is a substring of above created topic
./pulsar-admin topics create-partitioned-topic persistent://public/default/substring_topic -p 1
Below error is thrown in the console
10:14:38.692 [AsyncHttpClient-5-1] WARN org.apache.pulsar.client.admin.internal.BaseResource - [https://itomdipulsar-proxy:8443/admin/v2/persistent/public/default/substring_topic/partitions] Failed to perform http put request: javax.ws.rs.ClientErrorException: HTTP 412 Precondition Failed
Already have topic persistent://public/default/create_substring_topic-partition-0 which contains partition suffix '-partition-' and end with numeric value, Creation of partitioned topic substring_topic could cause conflict.
Reason: Already have topic persistent://public/default/create_substring_topic-partition-0 which contains partition suffix '-partition-' and end with numeric value, Creation of partitioned topic substring_topic could cause conflict.
Expected behavior
Partitioned topic should get created even if its a substring of existing topic