Interview with Liang Fei, member of Alibaba distributed service framework Dubbo team

Dubbo is the core framework of Alibaba's internal SOA service-based governance solution, providing 3,000,000,000+ visits per day for 2,000+ services, and is widely used in Alibaba Group member sites. Since Dubbo was open sourced in 2011, it has been used by many non-Alibaba companies.

Project home page: http://alibaba.github.io/dubbo-doc-static/Home-zh.htm

In order to give everyone a deep understanding of the framework, in this issue we interviewed Liang .

ITeye looks forward to and is committed to providing a free promotion platform for excellent domestic open source projects. If you and your team want to introduce your open source projects to more developers, or which open source projects you would like us to interview, please Tell us, send a text message to the ITeye administrator or send an email to [email protected].

 

 

Let me introduce myself first!Top

 

My name is Liang Fei, and I have a well-deserved reputation. I was in charge of the Dubbo service framework before, and now I have been transferred to Tmall.

My blog: http://javatar.iteye.com

 

What is Dubbo? What can be done?Top

 

Dubbo is a distributed services framework and SOA governance solution. Its functions mainly include: high-performance NIO communication and multi-protocol integration, service dynamic addressing and routing, soft load balancing and fault tolerance, dependency analysis and degradation, etc.

Available at: http://alibaba.github.io/dubbo-doc-static/Home-zh.htm

 

What scenarios is Dubbo suitable for?Top

 

When the website becomes larger, it is inevitable to split the application for service, in order to improve development efficiency, optimize performance, and save key competitive resources.

When there are more and more services, the URL address information of the services will explode, configuration management will become very difficult, and the single point pressure of the F5 hardware load balancer will also increase.

With further development, the dependencies between services become complicated and misunderstood, and it is not even clear which application should be started before which application, and architects cannot fully describe the architectural relationship of the application.

Then, the call volume of the service is increasing, and the capacity problem of the service is exposed. How many machines does this service need? When should the machine be added? Wait...

When you encounter these problems, you can use Dubbo to solve them.

See also: Dubbo's background and needs

 

What is the design idea of ​​Dubbo?Top

 

The framework has extremely high scalability, adopts the micro-core + plug-in system, and has complete documents, which is very convenient for secondary development and has strong adaptability.

See also: Developer Guide - Framework Design

 

Dubbo's needs and dependencies?Top

 

Dubbo runs on JDK1.5 and relies on packages such as javassist, netty, spring, etc. by default, but it is not required. By configuring Dubbo, it can run without any third-party libraries.

See also: User Guide - Dependencies

 

How does Dubbo perform?Top

 

Dubbo reduces handshakes through long connections, processes messages concurrently on a single connection through NIO and thread pools, and compresses data through binary streams, which is faster than short-connection protocols such as conventional HTTP. Within Alibaba, it supports more than 2,000 services every day, with more than 3 billion visits, and the largest single machine supports nearly 100 million visits per day.

See also: Dubbo performance test report

 

Compared with Taobao HSF, what are the characteristics of Dubbo?Top

 

1.  The deployment method of Dubbo is lighter than HSF . HSF requires the use of specified containers such as JBoss, and also needs to add sar package extensions to containers such as JBoss, which is more intrusive to the user's operating environment. If you want to run in Weblogic or Websphere On other containers, you need to expand the container to be compatible with HSF's ClassLoader loading, while Dubbo has no requirements and can run in any Java environment.

2.  Dubbo is more scalable than HSF, and it is very convenient for secondary development . It is impossible for one framework to cover all requirements. Dubbo always maintains the concept of treating third parties equally, that is, all functions can be modified without modifying Dubbo's native code. Expansion in the periphery, including Dubbo's own built-in functions, is also implemented by extension, just like the third party. It is very difficult for HSF if you want to add functions or replace some parts of the implementation. For example, Alipay and Taobao use different The HSF branch of HSF, because the core code was changed when adding functions, had to copy a branch for independent development. Even if HSF is open source at this stage, it is difficult to reuse unless the architecture is rewritten.

3.  HSF relies on many internal systems , such as configuration center, notification center, monitoring center, single sign-on, etc. If you want to open source, you need to do a lot of stripping work, and Dubbo has set aside extension points for the integration of each system, and All dependencies have been sorted out, and an alternative solution is provided for the open source community, which users can use directly.

4.  Dubbo has more functions than HSF . In addition to ClassLoader isolation, Dubbo is basically a superset of HSF. Dubbo also supports more protocols and integration of more registries to adapt to more website architectures.

 

How does Dubbo solve the security mechanism?Top

 

Dubbo is mainly aimed at internal services and external services. Ali has an open platform to handle security and flow control, so Dubbo has fewer functions in terms of security. Basically, it only prevents gentlemen and not villains, and only prevents misuse.

Dubbo uses Token to prevent users from bypassing the registration center to connect directly, and then manages authorization on the registration center. Dubbo also provides a service black and white list to control the callers allowed by the service.

See also: Dubbo's token verification

 

The application of Dubbo inside and outside Alibaba?Top

 

Inside Alibaba, other Alibaba subsidiaries other than the Tao Department are using Dubbo, including: Chinese main site, international main site, AliExpress, Aliyun, Ali Finance, Ali Academy, Liang Unlimited, Limian, etc.

After open source, it has been widely used by: Qunar, JD.com, Geely Auto, Founder Securities, Haier, Focus Technology, Zhongrun Sifang, Huaxin Cement, Hikvision, etc. Discussions and contributions are active, and it has been highly rated by users.

See also: Known users of Dubbo

 

What is Dubbo's plan in terms of distributed transactions, multi-language support?Top

 

Distributed transactions may not be supported for the time being, because it is not practical to support simple XA/JTA two-phase commit transactions. Users can implement business compensation events by themselves, or more complex distributed transactions. Dubbo has many extension points that can be integrated.

In terms of multi-language, Dubbo has implemented the C++ version, but its internal use is extremely narrow, and it has not been strongly verified, and the C++ development resources are tight, and there is no energy to prepare C++ open source matters.

 

The open source protocol used by Dubbo? What should be paid attention to in commercial applications?Top

 

Dubbo adopts the Apache License 2.0 open source agreement, which is a business-friendly agreement, and you can use it in non-open source commercial software for free.

You can transform and redistribute it, but only require to retain Ali's copyright and retain the original license statement when redistributing.

See also: Dubbo's Open Source License

 

What is the situation of the Dubbo development team?Top

 

Dubbo has a total of six developers involved in development and testing. Each developer is very experienced, the team cooperates very well, the development process is also very rhythmic, and there is a complete quality assurance process. Team composition:

  • Liang Fei (Developer/Product Management)
  • Liu Haomin (Developer/Process Management)
  • Chao Liu (developer/user support)
  • Ding Li (Developer/User Support)
  • Chen Lei (Developer/Quality Assurance)
  • Gang Lu (developer/open source operation and maintenance)

From left to right: Liu Chao, Liang Fei, Lu Gang, Chen Lei, Liu Haomin, Li Ding

See also: Dubbo team members

 

How can other developers get involved? What kind of work can be done?Top

 

Developers can fork the branch on Github, and then push the changes. After we review and test, they will be merged into the trunk.

Github address: https://github.com/alibaba/dubbo

Developers can claim small bug fixes on JIRA, and can also claim large functional modules on the developer guide page.

JIRA: http://code.alibabatech.com/jira/browse/DUBBO (temporarily unavailable)

Developer Guide: http://alibaba.github.io/dubbo-doc-static/Developer+Guide-zh.htm

 

Dubbo's future development plans?Top

 

Dubbo's RPC framework is basically stable, and the future focus will be on service governance, including architecture analysis, monitoring statistics, degradation control, process collaboration, and more.

Available at: http://alibaba.github.io/dubbo-doc-static/Roadmap-en.htm

 



Reprinted from: http://www.iteye.com/magazines/103

Guess you like

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