[improve][admin]internalGetMessageById shouldn't be allowed on partitioned topic - #19013
Merged
Conversation
Technoboy-
reviewed
Dec 21, 2022
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## master #19013 +/- ##
============================================
- Coverage 47.73% 47.67% -0.06%
- Complexity 10819 10825 +6
============================================
Files 712 712
Lines 69645 69650 +5
Branches 7481 7480 -1
============================================
- Hits 33242 33203 -39
- Misses 32699 32758 +59
+ Partials 3704 3689 -15
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
Technoboy-
reviewed
Dec 22, 2022
congbobo184
reviewed
Dec 23, 2022
congbobo184
left a comment
Contributor
There was a problem hiding this comment.
could you please add the test for it?
liangyepianzhou
approved these changes
Dec 26, 2022
liangyepianzhou
left a comment
Contributor
There was a problem hiding this comment.
Overall right, and it is better if you can add a unit test to verify it.
poorbarcode
reviewed
Dec 26, 2022
gaozhangmin
force-pushed
the
getMessageById
branch
from
January 4, 2023 06:42
eddad52 to
73a5586
Compare
Contributor
Author
org.apache.pulsar.broker.admin.PersistentTopicsTest#testGetMessageById |
gaozhangmin
requested review from
Technoboy-,
congbobo184 and
poorbarcode
and removed request for
poorbarcode
January 4, 2023 06:47
AnonHxy
reviewed
Jan 4, 2023
AnonHxy
approved these changes
Jan 5, 2023
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
Now, if a topic without partition index provided when querying
internalGetMessageById, errorTopic not foundwill be thrown out. It will confuse users.We'd better forbidden
internalGetMessageByIdon partitioned-topic.Modifications
If a partitioned-topic is provided,
Status.METHOD_NOT_ALLOWEDwill be thrown outVerifying this change
(Please pick either of the following options)
This change is a trivial rework / code cleanup without any test coverage.
(or)
This change is already covered by existing tests, such as (please describe tests).
(or)
This change added tests and can be verified as follows:
(example:)
Does this pull request potentially affect one of the following parts:
If the box was checked, please highlight the changes
Documentation
docdoc-requireddoc-not-neededdoc-completeMatching PR in forked repository
gaozhangmin#5