From fdad4b644964d358bb63336f0e64cd06a2cf2a5e Mon Sep 17 00:00:00 2001 From: changqing Date: Wed, 28 May 2025 09:37:28 +0800 Subject: [PATCH 1/2] Fix error example of multiple-advertised-listeners --- docs/concepts-multiple-advertised-listeners.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/concepts-multiple-advertised-listeners.md b/docs/concepts-multiple-advertised-listeners.md index 35499479c88c..e287790e1ea7 100644 --- a/docs/concepts-multiple-advertised-listeners.md +++ b/docs/concepts-multiple-advertised-listeners.md @@ -102,7 +102,7 @@ PulsarClient internalSecureClient = PulsarClient.builder() // External client with SSL PulsarClient externalClient = PulsarClient.builder() - .serviceUrl("pulsar+ssl://external-brokers.example.com:6651") + .serviceUrl("pulsar+ssl://external-brokers.example.com:16651") .build(); ``` From 19375a15effe695e0e9690da75a81499d5c30eaa Mon Sep 17 00:00:00 2001 From: changqing Date: Tue, 3 Jun 2025 14:29:23 +0800 Subject: [PATCH 2/2] Update concepts-multiple-advertised-listeners.md --- docs/concepts-multiple-advertised-listeners.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/docs/concepts-multiple-advertised-listeners.md b/docs/concepts-multiple-advertised-listeners.md index e287790e1ea7..c9897e299895 100644 --- a/docs/concepts-multiple-advertised-listeners.md +++ b/docs/concepts-multiple-advertised-listeners.md @@ -80,7 +80,7 @@ internalListenerName=internal To make this work: 1. If you are using DNS names, register a unique name for each broker instance (for example, `external-broker-1.example.com`, `external-broker-2.example.com`, etc.). -2. Configure your network gateway or firewall to handle proxying or NAT for each broker instance so that the external IP and port are proxied to the internal IP and external listener port. +2. Configure your network gateway or firewall to handle proxying or NAT for each broker instance so that the external IP and port are proxied to the internal IP and external listener port. The port client connected must equal to external listener port. 3. Add a load balancer that proxies to any healthy available broker on the external listener port. ## Client configuration @@ -100,9 +100,10 @@ PulsarClient internalSecureClient = PulsarClient.builder() .serviceUrl("pulsar+ssl://private-brokers.internal:6651") .build(); -// External client with SSL +// External client with SSL. +// Client -> external-brokers.example.com:6651 -> private-brokers.internal:16651 PulsarClient externalClient = PulsarClient.builder() - .serviceUrl("pulsar+ssl://external-brokers.example.com:16651") + .serviceUrl("pulsar+ssl://external-brokers.example.com:6651") .build(); ```