Question:

In today’s distributed project development, ZooKeeper + Dubbo is the most common, the common use is to use ZooKeeper as the registry, Dubbo as RPC, and then service deployment can achieve remote communication between each other. So development projects, as long as the connection for zk development environment address, local all don’t need to start the service can call each other, there are three services like A, B and C, as long as B and C are connected zk and deployed to the development environment (or other environment), after A good configuration corresponding zk does not need to start locally B and C can realize communication. But during the development process, we sometimes don’t want to access the service on the registry, but directly to the local alignment dubbo interface, such as now I want to in the local modify the service A and B, and then want to alignment the effect of A service invocation B service, but service or call C on the registry, then need some processing to bypass the registry access B services.

Solution:

${user.home}/dubbo-resolve.properties; ${user.home}/dubbo-resolve.properties; There is no need to modify other configuration information of the local project.

# Direct local service
com.xjt.order.facade.OrderFacade=dubbo://localhost:20890
Copy the code