New Features of Dubbo-go 3.0

star

1. Triple protocol

1.1 Overview

img

  • communication level

    The Triple protocol, also known as the Dubbo3 protocol, is an extension protocol based on the HTTP2 + gRPC protocol, adding specific fields and logic, ensuring interoperability with the native gRPC protocol. On this basis, Triple’s new protocol will more natively support Dubbo service governance capabilities. And supports streaming RPC calls.

    In simple terms, it can be understood as Triple = gRPC + Dubbo

  • Serialization

    The Triple protocol uses an efficient PB serialization method, and adds scalable support of the serialization protocol on this basis.

  • User development habits:

    Triple service requires a predefined .proto file before development, which is convenient for Go language developers who are accustomed to defining IDL before coding. Different from the Dubbo-go 1.x version that conforms to java programming habits, JavaClassName is defined to describe the interface.

  • Cross-language interoperability:

    It can realize cross-language intercommunication with Dubbo-Java.

2. Application-level service discovery

2.1 Introduction

img

In the service registration phase, the server instance registers the application-level registration information, mainly including the mapping from the application name to the instance IP, to the registration center. In the service discovery phase, the client instance obtains the IP of the service instance to be requested through the registration center. Entering the service introspection stage, the service introspection process is the process of obtaining interface information through application information. As shown above, there are two modes:

  1. remote mode: Obtain the mapping applied to the interface metadata through the metadata center (such as zk)
  2. Local mode: Obtain the mapping from the application to the interface metadata directly through the server (initiate an RPC call for the Metadata Service through the Dubbo protocol)

After service introspection, the client formally initiates a call to the corresponding instance. The most obvious benefit of doing this is to reduce the amount of data in the registry, that is, the registry only saves application-level data.

When using the application-level service discovery capability of Dubbo-go 3.0, users can follow the examples and directly configure the service introspection mode and metadata center information in the configuration file, introduce dependencies, and enable application-level service discovery.

2.2 Application-level service discovery introduction article

Analysis of application-level service discovery

3. Mesh Routing Rules

User definable routing files:

virtual_service.yaml

img

and dist_rule.yml

img

The framework can forward traffic for specific requests according to routing files.

Alibaba Cloud official introduction article: “Dubbo 3.0 - Opening the Next Generation of Cloud Native Microservices”


Last modified February 23, 2023: Update for seo / img alt (35090e3f9b)