[fix][broker] Update topic partition failed when config maxNumPartitionsPerPartitionedTopic<0#22397
Merged
lhotari merged 3 commits intoApr 9, 2024
Conversation
…onsPerPartitionedTopic<0
Contributor
Author
|
/pulsarbot rerun-failure-checks |
Member
|
Closing and reopening to trigger a completely new build with changes from master since more than 3 days has passed when the build was run (shared build artifacts will no longer be available). |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #22397 +/- ##
============================================
- Coverage 73.57% 73.15% -0.42%
+ Complexity 32624 32182 -442
============================================
Files 1877 1885 +8
Lines 139502 143509 +4007
Branches 15299 16306 +1007
============================================
+ Hits 102638 104989 +2351
- Misses 28908 30309 +1401
- Partials 7956 8211 +255
Flags with carried forward coverage won't be shown. Click here to find out more.
|
mukesh-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Apr 23, 2024
…onsPerPartitionedTopic<0 (apache#22397) (cherry picked from commit fb5caeb) (cherry picked from commit 386f6f0)
srinath-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Apr 23, 2024
…onsPerPartitionedTopic<0 (apache#22397) (cherry picked from commit fb5caeb) (cherry picked from commit 386f6f0)
hanmz
added a commit
to hanmz/pulsar
that referenced
this pull request
Feb 12, 2025
…onsPerPartitionedTopic<0 (apache#22397)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
When the configuration
maxNumPartitionsPerPartitionedTopic <= 0, we should consider the check to be disabled.However, the behavior has been modified in this PR: #19166
This will cause an error when update topic partition if
maxNumPartitionsPerPartitionedTopic<0.When
maxNumPartitionsPerPartitionedTopic=-1try to update topicpersistent://test-tenant/test-ns/test-topicpartition number from 1 to 2. We will see the following log:2024-04-02T19:42:01,593+0800 [pulsar-web-47-12] ERROR org.apache.pulsar.broker.admin.v2.PersistentTopics (PersistentTopics.java:844) - [null][persistent://test-tenant/test-ns/test-topic] Failed to update partition to 2 java.util.concurrent.CompletionException: org.apache.pulsar.broker.web.RestException: Desired partitions 2 can't be greater than the maximum partitions per topic -1.Modifications
brokerMaximumPartitionsPerTopic != 0=>brokerMaximumPartitionsPerTopic > 0Documentation
docdoc-requireddoc-not-neededdoc-complete