Skip to content

[improve][cli] Expose updateLocalTopicOnly to UpdatePartitionedCmd - #19162

Merged
nodece merged 1 commit into
apache:masterfrom
aloyszhang:update-partition
Jan 10, 2023
Merged

nodece merged 1 commit into
apache:masterfrom
aloyszhang:update-partition

Conversation

@aloyszhang

@aloyszhang aloyszhang commented Jan 9, 2023 •

Copy link
Copy Markdown
Contributor

Motivation

We can set updateLocalTopicOnly when updating partitions by PulsarAdmin like

 admin.topics().updatePartitionedTopic(partitionedTopicName, newPartitions, false, false);

But updateLocalTopicOnly is not exposed to CLI command UpdatePartitionedCmd

$ bin/pulsar-admin topics update-partitioned-topic

  Options:
    -f, --force
      Update forcefully without validating existing partitioned topic
      Default: false
  * -p, --partitions
      Number of partitions for the topic
      Default: 0

Modifications

exposeupdateLocalTopicOnly to CLI command UpdatePartitionedCmd by adding a new option "--update-local-only" or "-ulo".

Verifying this change

  • Make sure that the change passes the CI checks.

Documentation

  • doc-not-needed

Matching PR in forked repository

PR in forked repository: aloyszhang#12

@github-actions github-actions Bot added the doc-not-needed Your PR changes do not impact docs label Jan 9, 2023
@Technoboy- Technoboy- added this to the 2.12.0 milestone Jan 10, 2023
@Technoboy- Technoboy- closed this Jan 10, 2023
@Technoboy- Technoboy- reopened this Jan 10, 2023
@Technoboy- Technoboy- changed the title [Improve][CLI]expose updateLocalTopicOnly to UpdatePartitionedCmd [Improve][cli] Expose updateLocalTopicOnly to UpdatePartitionedCmd Jan 10, 2023
@Technoboy- Technoboy- changed the title [Improve][cli] Expose updateLocalTopicOnly to UpdatePartitionedCmd [improve][cli] Expose updateLocalTopicOnly to UpdatePartitionedCmd Jan 10, 2023
@codecov-commenter

codecov-commenter commented Jan 10, 2023 •

Copy link
Copy Markdown

Codecov Report

Merging #19162 (6d4ddcf) into master (c862356) will increase coverage by 0.88%.
The diff coverage is 0.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #19162      +/-   ##
============================================
+ Coverage     46.50%   47.39%   +0.88%     
- Complexity    10297    10712     +415     
============================================
  Files           687      713      +26     
  Lines         67425    69694    +2269     
  Branches       7237     7485     +248     
============================================
+ Hits          31357    33029    +1672     
- Misses        32544    32942     +398     
- Partials       3524     3723     +199     
Flag Coverage Δ
unittests 47.39% <0.00%> (+0.88%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...sar/broker/service/persistent/PersistentTopic.java 61.59% <0.00%> (-0.19%) ⬇️
.../pulsar/broker/service/SharedConsumerAssignor.java 3.70% <0.00%> (-74.08%) ⬇️
...apache/pulsar/broker/service/EntryAndMetadata.java 0.00% <0.00%> (-40.75%) ⬇️
...e/pulsar/broker/service/EntryBatchIndexesAcks.java 82.14% <0.00%> (-10.72%) ⬇️
...sistent/PersistentDispatcherMultipleConsumers.java 51.96% <0.00%> (-8.21%) ⬇️
...ersistentStickyKeyDispatcherMultipleConsumers.java 52.45% <0.00%> (-7.36%) ⬇️
...e/HashRangeExclusiveStickyKeyConsumerSelector.java 36.92% <0.00%> (-3.08%) ⬇️
...ervice/persistent/MessageRedeliveryController.java 60.97% <0.00%> (-2.44%) ⬇️
.../pulsar/broker/service/AbstractBaseDispatcher.java 60.57% <0.00%> (-2.29%) ⬇️
...ervice/streamingdispatch/StreamingEntryReader.java 59.64% <0.00%> (-1.76%) ⬇️
... and 58 more

@nodece
nodece merged commit 9ef54fd into apache:master Jan 10, 2023
@aloyszhang
aloyszhang deleted the update-partition branch August 17, 2023 14:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

doc-not-needed Your PR changes do not impact docs ready-to-test

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants