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 2023/01/08 06:52:18 UTC
[GitHub] [pulsar] horizonzy opened a new pull request, #19156: [fix][broker] Support zookeeper read-only config.
horizonzy opened a new pull request, #19156:
URL: https://github.com/apache/pulsar/pull/19156
Fixes #16489
Master Issue: #16489
### Motivation
Export config `metadataStoreAllowReadOnlyOperations` and `zooKeeperAllowReadOnlyOperations`.
### Does this pull request potentially affect one of the following parts:
<!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
*If the box was checked, please highlight the changes*
- [ ] Dependencies (add or upgrade a dependency)
- [ ] The public API
- [ ] The schema
- [ ] The default values of configurations
- [ ] The threading model
- [ ] The binary protocol
- [ ] The REST endpoints
- [ ] The admin CLI options
- [ ] The metrics
- [ ] Anything that affects deployment
### Documentation
<!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
- [ ] `doc` <!-- Your PR contains doc changes. Please attach the local preview screenshots (run `sh start.sh` at `pulsar/site2/website`) to your PR description, or else your PR might not get merged. -->
- [ ] `doc-required` <!-- Your PR changes impact docs and you will update later -->
- [ ] `doc-not-needed` <!-- Your PR changes do not impact docs -->
- [ ] `doc-complete` <!-- Docs have been already added -->
### Matching PR in forked repository
PR in forked repository: <!-- ENTER URL HERE -->
<!--
After opening this PR, the build in apache/pulsar will fail and instructions will
be provided for opening a PR in the PR author's forked repository.
apache/pulsar pull requests should be first tested in your own fork since the
apache/pulsar CI based on GitHub Actions has constrained resources and quota.
GitHub Actions provides separate quota for pull requests that are executed in
a forked repository.
The tests will be run in the forked repository until all PR review comments have
been handled, the tests pass and the PR is approved by a reviewer.
-->
--
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] hangc0276 commented on pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by "hangc0276 (via GitHub)" <gi...@apache.org>.
hangc0276 commented on PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#issuecomment-1445855076
@horizonzy Do we need to set the default value for `zooKeeperAllowReadOnlyOperations`?
--
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] horizonzy commented on pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
horizonzy commented on PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#issuecomment-1381542937
This is part 1, introduce `zooKeeperAllowReadOnlyOperations`. It should cherry-pick to branch-2.9, branch-2.10, branch-2.11.
After the cherry-pick works done, I will submit a new pr to deprecated `zooKeeperAllowReadOnlyOperations` and introduce `metadataStoreAllowReadOnlyOperations`.
--
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] horizonzy commented on pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by "horizonzy (via GitHub)" <gi...@apache.org>.
horizonzy commented on PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#issuecomment-1445857384
> zooKeeperAllowReadOnlyOperations
No need, we use the boolean default value `false` as the `zooKeeperAllowReadOnlyOperations ` default value.
--
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] AnonHxy commented on a diff in pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
AnonHxy commented on code in PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#discussion_r1064271316
##########
pulsar-broker-common/src/main/java/org/apache/pulsar/broker/ServiceConfiguration.java:
##########
@@ -461,6 +467,15 @@ The delayed message index bucket time step(in seconds) in per bucket snapshot se
)
private int zooKeeperCacheExpirySeconds = -1;
+ @Deprecated
Review Comment:
Could we remove the `zooKeeperAllowReadOnlyOperations` config? Because there seems is no compatible issue
--
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] horizonzy commented on a diff in pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
horizonzy commented on code in PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#discussion_r1064095973
##########
pulsar-broker-common/src/main/java/org/apache/pulsar/broker/ServiceConfiguration.java:
##########
@@ -461,6 +467,15 @@ The delayed message index bucket time step(in seconds) in per bucket snapshot se
)
private int zooKeeperCacheExpirySeconds = -1;
+ @Deprecated
Review Comment:
If the user uses the old properties, it just add `zookeeperAllowReadOnlyOperations` config.
--
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] codecov-commenter commented on pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
codecov-commenter commented on PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#issuecomment-1375030214
# [Codecov](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
> Merging [#19156](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (194fe09) into [master](https://codecov.io/gh/apache/pulsar/commit/da87e40aca848c0cb1ede7ba56605bdcd5f96137?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (da87e40) will **increase** coverage by `23.76%`.
> The diff coverage is `16.66%`.
[](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
```diff
@@ Coverage Diff @@
## master #19156 +/- ##
=============================================
+ Coverage 46.42% 70.19% +23.76%
+ Complexity 10437 436 -10001
=============================================
Files 703 26 -677
Lines 68816 2251 -66565
Branches 7377 245 -7132
=============================================
- Hits 31950 1580 -30370
+ Misses 33252 497 -32755
+ Partials 3614 174 -3440
```
| Flag | Coverage Δ | |
|---|---|---|
| unittests | `70.19% <16.66%> (+23.76%)` | :arrow_up: |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
| [Impacted Files](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
|---|---|---|
| [...a/org/apache/pulsar/proxy/server/ProxyService.java](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLXByb3h5L3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9wdWxzYXIvcHJveHkvc2VydmVyL1Byb3h5U2VydmljZS5qYXZh) | `79.26% <0.00%> (-1.67%)` | :arrow_down: |
| [...apache/pulsar/proxy/server/ProxyConfiguration.java](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLXByb3h5L3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9wdWxzYXIvcHJveHkvc2VydmVyL1Byb3h5Q29uZmlndXJhdGlvbi5qYXZh) | `97.05% <50.00%> (-0.40%)` | :arrow_down: |
| [...java/org/apache/pulsar/proxy/stats/TopicStats.java](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLXByb3h5L3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9wdWxzYXIvcHJveHkvc3RhdHMvVG9waWNTdGF0cy5qYXZh) | `58.82% <0.00%> (-41.18%)` | :arrow_down: |
| [...org/apache/pulsar/proxy/server/ProxyClientCnx.java](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLXByb3h5L3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9wdWxzYXIvcHJveHkvc2VydmVyL1Byb3h5Q2xpZW50Q254LmphdmE=) | `46.51% <0.00%> (ø)` | |
| [...rg/apache/pulsar/proxy/server/ProxyConnection.java](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLXByb3h5L3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9wdWxzYXIvcHJveHkvc2VydmVyL1Byb3h5Q29ubmVjdGlvbi5qYXZh) | `55.21% <0.00%> (ø)` | |
| [...n/java/org/apache/pulsar/broker/PulsarService.java](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWJyb2tlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2Jyb2tlci9QdWxzYXJTZXJ2aWNlLmphdmE=) | | |
| [.../pulsar/client/impl/MessagePayloadContextImpl.java](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2NsaWVudC9pbXBsL01lc3NhZ2VQYXlsb2FkQ29udGV4dEltcGwuamF2YQ==) | | |
| [...a/org/apache/pulsar/client/impl/MessageIdImpl.java](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2NsaWVudC9pbXBsL01lc3NhZ2VJZEltcGwuamF2YQ==) | | |
| [...apache/pulsar/client/impl/auth/oauth2/KeyFile.java](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-cHVsc2FyLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcHVsc2FyL2NsaWVudC9pbXBsL2F1dGgvb2F1dGgyL0tleUZpbGUuamF2YQ==) | | |
| ... and [674 more](https://codecov.io/gh/apache/pulsar/pull/19156?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | |
--
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 a diff in pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
Technoboy- commented on code in PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#discussion_r1064333970
##########
pulsar-broker-common/src/main/java/org/apache/pulsar/broker/ServiceConfiguration.java:
##########
@@ -461,6 +467,15 @@ The delayed message index bucket time step(in seconds) in per bucket snapshot se
)
private int zooKeeperCacheExpirySeconds = -1;
+ @Deprecated
Review Comment:
Seems we need to remove it.
--
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] horizonzy commented on pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
horizonzy commented on PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#issuecomment-1379741543
> LGTM,
>
> But I have to mention one thing If you want to cherry-pick this PR to branch-2.9, you've got to support and cherry-pick `zooKeeperAllowReadOnlyOperations` configuration first and then push another PR to introduce `metadataStoreAllowReadOnlyOperations` and deprecate the previous one.
>
> The reason is that branch-2.9 has no `metadata****` configuration. So, if we introduce a new config named `metadata****`, it's weird.
Thanks for your reminder. In branch-2.9, only introduce `zooKeeperAllowReadOnlyOperations` without @deprecated annotation.
--
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- closed pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
Technoboy- closed pull request #19156: [fix][broker] Support zookeeper read-only config.
URL: https://github.com/apache/pulsar/pull/19156
--
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] horizonzy commented on a diff in pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
horizonzy commented on code in PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#discussion_r1064095973
##########
pulsar-broker-common/src/main/java/org/apache/pulsar/broker/ServiceConfiguration.java:
##########
@@ -461,6 +467,15 @@ The delayed message index bucket time step(in seconds) in per bucket snapshot se
)
private int zooKeeperCacheExpirySeconds = -1;
+ @Deprecated
Review Comment:
If the user uses the old properties, it config `zookeeperAllowReadOnlyOperations=true` enough, instead to comprehend the new config.
--
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] Jason918 commented on a diff in pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
Jason918 commented on code in PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#discussion_r1064095716
##########
pulsar-broker-common/src/main/java/org/apache/pulsar/broker/ServiceConfiguration.java:
##########
@@ -461,6 +467,15 @@ The delayed message index bucket time step(in seconds) in per bucket snapshot se
)
private int zooKeeperCacheExpirySeconds = -1;
+ @Deprecated
Review Comment:
Why are we add deprecated fields? Seems not necessary.
--
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] horizonzy commented on pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
horizonzy commented on PR #19156:
URL: https://github.com/apache/pulsar/pull/19156#issuecomment-1376712647
@Technoboy- 2.9.x 2.10.x 2.11.x also need this pr.
--
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- merged pull request #19156: [fix][broker] Support zookeeper read-only config.
Posted by GitBox <gi...@apache.org>.
Technoboy- merged PR #19156:
URL: https://github.com/apache/pulsar/pull/19156
--
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