Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Which is better, java's Dubbox or Dubbo framework?

2025-04-05 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/03 Report--

This article mainly introduces "java Dubbox and Dubbo framework which is good". In daily operation, I believe that many people have doubts about which good java Dubbox framework and Dubbo framework. The editor consulted all kinds of materials and sorted out simple and easy-to-use methods of operation. I hope it will be helpful to answer the doubts of "java Dubbox and Dubbo framework". Next, please follow the editor to study!

In fact, Dubbox and Dubbo are both good service frameworks. To put it simply, there is no difference between Dubbox and Dubbo in nature. Dubbox is an upgraded version of Dubbo. In this way, it seems that Dubbox is better. Why? After all, it is an upgraded version that extends what Dubbo does not have. Now, let's analyze the difference between them in detail.

1. Introduction

Dubbo originates from the open source distributed service architecture of Alibaba's Taobao, and is committed to providing a high-performance and transparent RPC remote service invocation solution, which is the core framework of SOA service-oriented governance solution. After Taobao opened it up, it got a lot of expansion and support (more famous: Dangdang's extended version dubbox, JD.com 's extended version jd-hydra, etc.)

Dubbox is an open source RPC (Remote ProcedureCall Protocol) remote call framework, which is upgraded by dangdang to Ali's Dubbo, and can be regarded as an enhanced version of Dubbo. The basic architecture remains unchanged, upgrade spring2.x to spring3.x, support restful-style call debugging, enrich the way of serialization and improve the performance of serialization. Dubbox (Dubbo eXtensions) is an upgraded version of Dangdang Fork based on dubbo2.x, which is compatible with the original dubbox. The zookeeper and spring versions are upgraded and restfull-style remote calls are supported.

2. Current situation

Dubbo stems from the open source and distributed service architecture of Alibaba's Taobao. It is said that dubbo, a Taobao site, had a dispute with HSF, a non-open source framework, which led to the disbanding of dubbo's team. Dubbo has currently stopped updating.

Dubbox (Dubbo eXtensions) is an upgraded version of Dangdang Fork based on dubbo2.x, which is compatible with the original dubbox. The zookeeper and spring versions are upgraded and restfull-style remote calls are supported. Dubbox has been continuously developed (upgraded and updated) and is still being updated.

3. Comparison of service framework

The meaning of the name Dubbox extends the meaning of Dubb. The following is the extended function, which is also a very important research point for choosing Dubbox.

Support REST style remote calls (HTTP + JSON/XML)

Support efficient serialization implementation of Java based on Kryo and FST

Support for Jackson-based JSON serialization

Support HTTP remoting architecture based on embedded Tomcat

Upgrade Spring to 3.x

Upgrade ZooKeeper client

Dubbo configuration based entirely on Java code is supported.

4 、 RPC vs REST

The interface dependence between the service provider and the caller is too strong: we define our own service abstract interface for each microservice and publish it to the private repository through continuous integration. The caller application has a strong dependency on the abstract interface provided by the microservice, so strict management version dependence is required for both development, testing and integration environments. In order to avoid a series of problems such as the inconsistency between the server and the caller, such as the application cannot be compiled successfully, and this will directly affect the environmental requirements of local development, often an upper-level application that depends on many services has to update a lot of code and install every day before further development can be carried out. Without a strict version management system or developing some automated tools, such dependencies can be a nightmare for the development team. The REST interface is lighter than RPC, and the dependencies of service providers and callers only rely on a contract, and there is no strong dependence at the code level. Of course, the REST interface also has pain points, because the definition of the interface is too light, which can easily lead to the problem of service integration due to the inconsistency between the definition document and the actual implementation. But this problem is easy to solve. You only need to integrate the swagger through each service and integrate the code and document of each service. It can be solved. Therefore, in the distributed environment, the service dependency of REST is more flexible than that of RPC.

Services are platform-sensitive and difficult to simply reuse: usually, when we provide external services, we will provide them in the way of REST, which can achieve cross-platform characteristics, and callers of any language can implement them according to the definition of interfaces. So when we want to provide REST interface in Dubbo, we have to implement a layer of proxy, which is used to convert RPC interface into REST interface for external publication. If each service itself exists in the form of REST interface, when we want to provide services, we can mainly configure mapping and permission control in the API gateway to realize the reuse of services.

Dubbo implements the foundation of service governance, but in order to complete a complete micro-service architecture, we still need to expand and improve in all aspects to ensure the health of the cluster, so as to reduce the increased pressure on development, testing, and operation and maintenance. Only in this way can the personnel of each link really focus on business logic. And Spring Cloud still carries forward the style of Spring Source to integrate everything, kneads some mature products and frameworks of micro-service architecture into one with a standardized attitude, and inherits the characteristics of simple configuration, rapid development and easy deployment of Spring Boot, making the original complex architecture work relatively easy to use. Therefore, if you choose Dubbo, be sure to prepare the whole solution in all aspects, otherwise it is likely that as the number of services grows, the whole team will struggle to cope with various architectural deficiencies. If you choose Spring Cloud, relatively speaking, each link already has corresponding component support, some may not be able to meet all your needs, but its active community and high-speed iterative progress will also be a strong backing you can rely on.

Dubbox: compared to Dubbo supporting REST, it is estimated to be one of the important reasons why many companies choose Dubbox. However, if you use Dubbo's RPC call method, there will still be strong API dependencies among services, each with its own advantages and disadvantages.

At this point, the study on "which is the best Dubbox and Dubbo framework of java" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report