Dubbo principle and calling process





Provider: The service provider that exposes the service.
Consumer: The service consumer that invokes the remote service.
Registry: A registry for service registration and discovery.
Monitor: The monitoring center that counts service calls and call times.

Call process
0. The service container is responsible for starting, loading, and running the service provider.
1. When the service provider starts, it registers the service it provides with the registration center.
2. When the service consumer starts, it subscribes to the registration center for the services it needs.
3. The registry returns the service provider address list to the consumer. If there is a change, the registry will push the change data to the consumer based on the persistent connection.
4. The service consumer, from the provider address list, selects a provider to call based on the soft load balancing algorithm, and if the call fails, selects another provider to call.
5. Service consumers and providers, accumulate the number of calls and call time in memory, and regularly send statistical data to the monitoring center
Dubbo every minute Advantages and disadvantages: 1. Transparent remote method call - call remote method like calling local method Method; just simple configuration, no API intrusion. 2. Soft load balancing and fault tolerance mechanism - can replace hardware load balancers such as nginx lvs in the intranet. 3. Service registration center automatic registration & configuration management - no need to write the service provider address, the registration center automatically queries the provider ip based on the interface name. Using distributed coordination services such as zookeeper as the service registry, most project configurations can be moved into the zookeeper cluster. 4. Service interface monitoring and governance














-Dubbo-admin and Dubbo-monitor provide complete service interface management and monitoring functions. For different interfaces of different applications, multi-version, multi-protocol, and multi-registration management can be performed.

Disadvantage:

only supports JAVA language

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326175134&siteId=291194637