Skip to content
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

[Bug] Proxy server's Topic route info maybe wrong when local mode. #8304

Open
3 tasks done
supervate opened this issue Jun 17, 2024 · 0 comments
Open
3 tasks done

[Bug] Proxy server's Topic route info maybe wrong when local mode. #8304

supervate opened this issue Jun 17, 2024 · 0 comments

Comments

@supervate
Copy link
Contributor

Before Creating the Bug Report

  • I found a bug, not just asking a question, which should be created in GitHub Discussions.

  • I have searched the GitHub Issues and GitHub Discussions of this repository and believe that this is not a duplicate.

  • I have confirmed that this bug belongs to the current repository, not other repositories of RocketMQ.

Runtime platform environment

No influence.

RocketMQ version

the newest version.

JDK Version

No influence.

Describe the Bug

Grpc Client will be get the error address of proxy-service, when deployed multi proxy with different port.

e.g.
proxy1: 127.0.0.1:8090 broker-a: 127.0.0.1:10911
proxy2: 127.0.0.1:8091 broker-b: 127.0.0.1:20911

If clients query the topic route info from proxy1, it will get the result as 'broker-a 127.0.0.1:8090 | broker-b 127.0.0.1:8090' or 'broker-a 127.0.0.1:8091 | broker-b 127.0.0.1:8091'.
Obviously, all broker's address's port be replaced with the same port depends on the proxy be called.

If I deployed proxy with different ip and port like '192.168.1.1:8090' and '192.168.1.2:8091', It must be throw error when I call the error address like '192.168.1.1:8091'.

Steps to Reproduce

Deploy multi proxy in different ip and port with local mode.
e.g.:
proxy1: 127.0.0.1:8090 and broker-a: 127.0.0.1:10911

proxyconfig:

{
  "rocketMQClusterName": "DefaultCluster",
  "grpcServerPort": 8090,
  "remotingListenPort": 9080
}

brokerconfig:

brokerClusterName = DefaultCluster
brokerName = broker-a
brokerId = 0
storePathRootDir = /Users/softcache/idea-rocketMq-5-1/store
listenPort = 10911

proxy2: 127.0.0.1:8091 and broker-b: 127.0.0.1:20911

proxyconfig:

{
  "rocketMQClusterName": "DefaultCluster",
  "grpcServerPort": 8091,
  "remotingListenPort": 9081
}

brokerconfig:

brokerClusterName = DefaultCluster
brokerName = broker-b
brokerId = 0
storePathRootDir = /Users/softcache/idea-rocketMq-5-2/store
listenPort = 20911

Use the grpc clients connect to proxy-service like send messages or consumer messages, and view the topic route info from proxy-service.

What Did You Expect to See?

Every topic route info's broker should has the right proxy address include ip and port.

What Did You See Instead?

Maybe we should return the route info like cluster mode, just return the addresses that in client request headers.
And I think we should set this default value to 'true'.
image

Additional Context

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant