Achieving Address Interoperability Based on Application-Level Service Discovery

dubbo-java and dubbo-go use the same service discovery model. This document demonstrates how to achieve address interoperability based on application-level service discovery.

In the previous two examples, we demonstrated the interoperability capabilities of dubbo java and dubbo go at the protocol level, covering both the triple and dubbo protocols.

In this document, we will demonstrate the service discovery interoperability between dubbo java and dubbo go. With the combination of protocol compatibility, we can achieve full interoperability between the dubbo java and dubbo go microservice systems.

This document uses the Nacos registry as a demonstration. You can view the complete example source code here.

Before running the code, you should follow this instruction to install and start the Nacos server.

Application-Level Service Discovery

  1. cd service

Start Java Server

  1. cd java-server
  2. sh run.sh

Start Go Client

  1. cd go-client
  2. go run client.go

Go Server <-> Java Client

Start Go Server

  1. cd go-server
  2. go run server.go

Start Java Client

  1. cd java-client
  2. sh run.sh

Interface-Level Service Discovery (for dubbo2 users only)

How to Run

Java Server <-> Go Client

  1. cd interface

Start Java Server

  1. cd java-server
  2. sh run.sh

Start Go Client

  1. cd go-client
  2. go run client.go

Go Server <-> Java Client

Start Go Server

  1. cd go-server
  2. go run server.go

Start Java Client

  1. cd java-client
  2. sh run.sh

Feedback

Was this page helpful?

Yes No

Last modified September 30, 2024: Update & Translate Overview Docs (#3040) (d37ebceaea7)