[Bug] Dubbo 3.3.5 fails to start with Nacos 3.x due to removed /v1/ns/operator/switches API
Pre-check
- [x] I am sure that all the content I provide is in English.
Search before asking
- [x] I had searched in the issues and found no similar issues.
Apache Dubbo Component
Java SDK (apache/dubbo)
Dubbo Version
| Item | Version |
|---|---|
| Dubbo | 3.3.0 |
| Nacos Server | 3.0.2 |
| JDK | openjdk-17 |
| OS | Windows |
Steps to reproduce this issue
1.Start Nacos 3.0.2 in standalone mode:
docker run -d -p 8082:8848 -p 8083:9848
-e MODE=standalone nacos/nacos-server:3.0.2
Configure Dubbo application.yml:
dubbo:
config-center:
address: nacos://localhost:8082
registry:
address: nacos://localhost:8082
metadata-report:
address: nacos://localhost:8082
Start the Dubbo application.
What you expected to happen
Application starts successfully with logs: Successfully connected to nacos config server ...
Anything else
Actual Behavior Logs repeatedly print: Failed to connect to nacos config server. Server status: DOWN. Config Service Available: true. Root Cause Dubbo uses GET /nacos/v1/ns/operator/switches to determine the server status. Nacos 3.x has removed this endpoint and returns 410 Gone, causing Dubbo to treat the server as DOWN.
Are you willing to submit a pull request to fix on your own?
- [x] Yes I am willing to submit a pull request on my own!
Code of Conduct
- [x] I agree to follow this project's Code of Conduct
could you provide a pr?
I have encountered the exact same situation here using dubbo3.3.5 and nacos-server 3.0.3. Help me find out what exactly has happened (the removal of this endpoint).
Hi all,
I’ve tracked down the root cause of the issue: in our Maven setup, Dubbo is still referencing Nacos 2.x. As a result, Dubbo relies on the old serverStatus endpoint to check the health of Nacos servers. In Nacos 3.x, this endpoint has been removed and now returns 410 Gone, which causes Dubbo to incorrectly mark the server as DOWN.
Given this, I’d like to ask: for the next version of Dubbo, should we consider adding official support or adaptation for Nacos 3.x? This would ensure compatibility with the new Nacos API while preserving the health check and dynamic configuration features.
Finally, I create an issue in the nacos repository : https://github.com/alibaba/nacos/issues/13984 Thanks!