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 2020/07/07 13:55:52 UTC

[GitHub] [pulsar] meleagle opened a new issue #7470: Broker url getting set to canonical host name rather than internal advertised listener

meleagle opened a new issue #7470:
URL: https://github.com/apache/pulsar/issues/7470


   **Describe the bug**
   The broker url for a broker will be set to whatever the advertisedAddress and brokerServicePort are set to in the config when I only use a single advertised listener. With pulsar 2.6.0 and trying to use the advertisedListeners list, the broker url is being set to the canonical host name instead of the internalListenerName or at least one of the advertisedListeners in the provided list like I would expect it to.
   
   **To Reproduce**
   Steps to reproduce the behavior:
   1. Set the advertisedAddress and brokerServicePort to whatever is needed
   2. Start pulsar and see that the broker url matches these two properties combined
   3. Use the advertisedListeners and internalListenerName properties to set the advertised addresses
   4. Start pulsar and see that the broker url is not any of the values in the provided list but instead is set to the canonical host name
   
   **Expected behavior**
   I would think that the broker url with multiple advertised listeners would be set to whatever the internalListenerName or at least one of the entries in the listeners list instead of the canonical host name.
   
   **Desktop (please complete the following information):**
    - Windows 10 with WSL 1
   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] meleagle closed issue #7470: Broker url getting set to canonical host name rather than internal advertised listener

Posted by GitBox <gi...@apache.org>.
meleagle closed issue #7470:
URL: https://github.com/apache/pulsar/issues/7470


   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] meleagle edited a comment on issue #7470: Broker url getting set to canonical host name rather than internal advertised listener

Posted by GitBox <gi...@apache.org>.
meleagle edited a comment on issue #7470:
URL: https://github.com/apache/pulsar/issues/7470#issuecomment-677751653


   Hello @zymap, The logs weren't helpful for me to look at as there was no errors but I can give an example of the properties I set to get to the issue.
   
   In broker.conf I would clear out the brokerServicePort and AdvertisedAddress fields.
   
   Then I would set the advertisedListeners and internalListenerName to something like below (with valid ip addressess in the real case).
   
   advertisedListeners=internal:pulsar://0.0.0.0:6650,external:pulsar://1.1.1.1:6660
   internalListenerName=internal
   
   So when I would start pulsar up normally with just using the advertisedAddress and the brokerServicePort I would see a line like below in the logs where the broker url was the combination of the two which is what I expected.
   
   ```
   15:46:33.806 [main] INFO  org.apache.pulsar.broker.PulsarService - messaging service is ready, bootstrap service port = 8080, broker url= pulsar://0.0.0.0:6650
   ```
   
   But when I used the advertisedListeners and internalListenerName fields, instead of the broker url being the ip:port combination that is expected from the advertisedListeners list it was getting resolved to the instances hostname instead.
   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] meleagle commented on issue #7470: Broker url getting set to canonical host name rather than internal advertised listener

Posted by GitBox <gi...@apache.org>.
meleagle commented on issue #7470:
URL: https://github.com/apache/pulsar/issues/7470#issuecomment-678872454


   @zymap No problem, thanks for looking into 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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] zymap commented on issue #7470: Broker url getting set to canonical host name rather than internal advertised listener

Posted by GitBox <gi...@apache.org>.
zymap commented on issue #7470:
URL: https://github.com/apache/pulsar/issues/7470#issuecomment-678870856


   Hi @meleagle, I configure the advertisedListeners and internalListerName:
   ```
   advertisedListeners=internal:pulsar://192.168.3.2:6650
   internalListenerName=internal
   ```
   After starting the broker service, I can see the following log:
   
   ```
   10:19:57.600 [main] INFO  org.apache.pulsar.broker.PulsarService - messaging service is ready, bootstrap service port = 8080, broker url= pulsar://192.168.3.2:6650,
   ```
   
   Sorry, I can't see the 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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] meleagle commented on issue #7470: Broker url getting set to canonical host name rather than internal advertised listener

Posted by GitBox <gi...@apache.org>.
meleagle commented on issue #7470:
URL: https://github.com/apache/pulsar/issues/7470#issuecomment-677751653


   Hello @zymap, The logs weren't helpful for me to look at as there was no errors but I can give an example of the properties I set to get to the issue.
   
   In broker.conf I would clear out the brokerServicePort and AdvertisedAddress fields.
   
   Then I would set the advertisedListeners and internalListenerName to something like below (with valid ip addressess in the real case).
   
   advertisedListeners=internal:pulsar://0.0.0.0:6650,external:pulsar://1.1.1.1:6660
   internalListenerName=internal
   
   So when I would start pulsar up normally with just just using the advertisedAddress and the brokerServicePort I would see a line like below in the logs where the broker url was the combination of the two which is what I expected.
   
   ```
   15:46:33.806 [main] INFO  org.apache.pulsar.broker.PulsarService - messaging service is ready, bootstrap service port = 8080, broker url= pulsar://0.0.0.0:6650
   ```
   
   But when I used the advertisedListeners and internalListenerName fields, instead of the broker url being the ip:port combination that is expected from the advertisedListeners list it was getting resolved to the instances hostname instead.
   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] zymap commented on issue #7470: Broker url getting set to canonical host name rather than internal advertised listener

Posted by GitBox <gi...@apache.org>.
zymap commented on issue #7470:
URL: https://github.com/apache/pulsar/issues/7470#issuecomment-677511710


   Hi, @meleagle. I can not reproduce this issue on my laptop. Could you please give me more information? Such as log or something else?


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org