-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to get web service url when split bundle #14668
Comments
We need to make a little change in |
@Technoboy- I see. But do you know what makes the difference between standalone and the cluster mode? The same application runs well in standalone mode. |
@BewareMyPower In standalone, only have one broker, so no matter the readOnly is false or true, the broker will return the correct owner. I'm not sure if this is a breaking change in 2.8.x, 2.9.x, 2.10.x, or for all versions. Which pulsar version you have encountered this issue? |
Oh, sorry, If the bundle does not been loaded before, the issue also happens. |
I tried 2.9.1. I'll test other versions soon. |
But we also have only one broker in my test env. I deployed only one broker, one bookie, one zookeeper. |
Master Issue: #14668 Fixes: #14668 ### Motivation When we split a not loaded namespace bundle, we will meet the below error: ``` Failed to find ownership for ServiceUnit:tenant/namespace/0x00000000_0x10000000 ``` Because when validating namespace bundle ownership with `readonly=true` : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/NamespacesBase.java#L1145-L1151 and if the bundle is not owned by any broker, it will return empty(line-392): https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/namespace/NamespaceService.java#L388-L400 so throw the below exception : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/web/PulsarWebResource.java#L576-L582 ### Modification - Change readonly from `true` to `false` when validating namespace bundle ownership.
Master Issue: #14668 Fixes: #14668 ### Motivation When we split a not loaded namespace bundle, we will meet the below error: ``` Failed to find ownership for ServiceUnit:tenant/namespace/0x00000000_0x10000000 ``` Because when validating namespace bundle ownership with `readonly=true` : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/NamespacesBase.java#L1145-L1151 and if the bundle is not owned by any broker, it will return empty(line-392): https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/namespace/NamespaceService.java#L388-L400 so throw the below exception : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/web/PulsarWebResource.java#L576-L582 ### Modification - Change readonly from `true` to `false` when validating namespace bundle ownership. (cherry picked from commit 4ffef1a)
Master Issue: #14668 Fixes: #14668 ### Motivation When we split a not loaded namespace bundle, we will meet the below error: ``` Failed to find ownership for ServiceUnit:tenant/namespace/0x00000000_0x10000000 ``` Because when validating namespace bundle ownership with `readonly=true` : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/NamespacesBase.java#L1145-L1151 and if the bundle is not owned by any broker, it will return empty(line-392): https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/namespace/NamespaceService.java#L388-L400 so throw the below exception : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/web/PulsarWebResource.java#L576-L582 ### Modification - Change readonly from `true` to `false` when validating namespace bundle ownership. (cherry picked from commit 4ffef1a)
Master Issue: #14668 Fixes: #14668 ### Motivation When we split a not loaded namespace bundle, we will meet the below error: ``` Failed to find ownership for ServiceUnit:tenant/namespace/0x00000000_0x10000000 ``` Because when validating namespace bundle ownership with `readonly=true` : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/NamespacesBase.java#L1145-L1151 and if the bundle is not owned by any broker, it will return empty(line-392): https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/namespace/NamespaceService.java#L388-L400 so throw the below exception : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/web/PulsarWebResource.java#L576-L582 ### Modification - Change readonly from `true` to `false` when validating namespace bundle ownership. (cherry picked from commit 4ffef1a)
Master Issue: apache#14668 Fixes: apache#14668 ### Motivation When we split a not loaded namespace bundle, we will meet the below error: ``` Failed to find ownership for ServiceUnit:tenant/namespace/0x00000000_0x10000000 ``` Because when validating namespace bundle ownership with `readonly=true` : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/NamespacesBase.java#L1145-L1151 and if the bundle is not owned by any broker, it will return empty(line-392): https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/namespace/NamespaceService.java#L388-L400 so throw the below exception : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/web/PulsarWebResource.java#L576-L582 ### Modification - Change readonly from `true` to `false` when validating namespace bundle ownership. (cherry picked from commit 4ffef1a) (cherry picked from commit 43f2562)
Master Issue: apache#14668 Fixes: apache#14668 ### Motivation When we split a not loaded namespace bundle, we will meet the below error: ``` Failed to find ownership for ServiceUnit:tenant/namespace/0x00000000_0x10000000 ``` Because when validating namespace bundle ownership with `readonly=true` : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/NamespacesBase.java#L1145-L1151 and if the bundle is not owned by any broker, it will return empty(line-392): https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/namespace/NamespaceService.java#L388-L400 so throw the below exception : https://github.com/apache/pulsar/blob/fe7e55d9f353925a559e88f8ceef2b47b59668e0/pulsar-broker/src/main/java/org/apache/pulsar/broker/web/PulsarWebResource.java#L576-L582 ### Modification - Change readonly from `true` to `false` when validating namespace bundle ownership.
Describe the bug
When I tried to split a bundle range in a single node cluster, the weird error logs
Unable to get web service url
occurred.To Reproduce
Deploy a single node cluster.
Changes to
conf/bookie.conf
:Changes to
conf/broker.conf
:(Here we use 3 terminals for step above)
Finally run following application:
We can see the topic creation, produce and get bundles operations all succeeded. However, the
splitNamespaceBundle
failed withThe broker's warning log is weird:
The standard output is also weird:
The
defaultNumberOfNamespaceBundles
is 4, but the initial number of bundles is 16.It works well in a Pulsar standalone.
Expected behavior
It should succeed as it runs in a Pulsar standalone. Or the broker should log the meaningful message.
The text was updated successfully, but these errors were encountered: