You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2022/07/25 07:56:37 UTC
[GitHub] [pulsar] TakaHiR07 opened a new pull request, #16769: Enhance grant permission on topic
TakaHiR07 opened a new pull request, #16769:
URL: https://github.com/apache/pulsar/pull/16769
### Motivation
related to https://github.com/apache/pulsar/issues/16768
### Modifications
no need to grant permission on each partition of partitioned-topic
### Does this pull request potentially affect one of the following parts:
*If `yes` was chosen, please highlight the changes*
- Dependencies (does it add or upgrade a dependency): no
- The public API: no
- The schema: no
- The default values of configurations: no
- The wire protocol: no
- The rest endpoints: no
- The admin cli options: no
- Anything that affects deployment: no
### Documentation
Check the box below or label this PR directly.
Need to update docs?
- [ ] `doc-required`
(Your PR needs to update docs and you will update later)
- [x] `doc-not-needed`
(Please explain why)
- [ ] `doc`
(Your PR contains doc changes)
- [ ] `doc-complete`
(Docs have been already added)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] TakaHiR07 commented on pull request #16769: Enhance grant permission on topic
Posted by GitBox <gi...@apache.org>.
TakaHiR07 commented on PR #16769:
URL: https://github.com/apache/pulsar/pull/16769#issuecomment-1193799980
> I think you should commit your PR to the master branch.
@nodece @Technoboy- I have found that revoke permission also has problem. I will open an other pr soon to fix this problem. This pr would be close
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] Technoboy- commented on pull request #16769: Enhance grant permission on topic
Posted by GitBox <gi...@apache.org>.
Technoboy- commented on PR #16769:
URL: https://github.com/apache/pulsar/pull/16769#issuecomment-1193736085
@TakaHiR07 Should you commit to the master branch?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] nodece commented on pull request #16769: Enhance grant permission on topic
Posted by GitBox <gi...@apache.org>.
nodece commented on PR #16769:
URL: https://github.com/apache/pulsar/pull/16769#issuecomment-1193771947
I think you should commit your PR to the master branch.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] nodece commented on a diff in pull request #16769: Enhance grant permission on topic
Posted by GitBox <gi...@apache.org>.
nodece commented on code in PR #16769:
URL: https://github.com/apache/pulsar/pull/16769#discussion_r928626283
##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/PersistentTopicsBase.java:
##########
@@ -283,14 +283,6 @@ protected void internalGrantPermissionsOnTopic(String role, Set<AuthAction> acti
validateAdminAccessForTenant(namespaceName.getTenant());
validatePoliciesReadOnlyAccess();
- PartitionedTopicMetadata meta = getPartitionedTopicMetadata(topicName, true, false);
- int numPartitions = meta.partitions;
- if (numPartitions > 0) {
- for (int i = 0; i < numPartitions; i++) {
- TopicName topicNamePartition = topicName.getPartition(i);
- grantPermissions(topicNamePartition.toString(), role, actions);
- }
- }
grantPermissions(topicName.toString(), role, actions);
Review Comment:
```suggestion
grantPermissions(topicName.getPartitionedTopicName(), role, actions);
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] TakaHiR07 closed pull request #16769: Enhance grant permission on topic
Posted by GitBox <gi...@apache.org>.
TakaHiR07 closed pull request #16769: Enhance grant permission on topic
URL: https://github.com/apache/pulsar/pull/16769
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org