Skip to content

grpc/health/v1/health.proto has a name conflict over grpc.health.v1.HealthCheckResponse #2394

@HubQin

Description

@HubQin

Environment

  • Server: Dubbo-go, v3.1.0
  • Client: Dubbo-go, v3.1.0
  • Protocol: Dubbo
  • Registry: Nacos

Issue description

health check in "dubbo.apache.org/dubbo-go/v3/protocol/dubbo3/health/triple_health_v1" conflicts with the one in "google.golang.org/grpc/health/grpc_health_v1".

Code to show the bug:

package main

import (
	_ "dubbo.apache.org/dubbo-go/v3/imports"
	_ "google.golang.org/grpc/health/grpc_health_v1"
)

func main() {

}

To execute the code above, it's necessary to create a go.mod file and update the dependencies.

Logs

Click me to check logs After running code above, panic occurs:
panic: proto: file "grpc/health/v1/health.proto" has a name conflict over grpc.health.v1.HealthCheckResponse
	previously from: "dubbo.apache.org/dubbo-go/v3/protocol/dubbo3/health/triple_health_v1"
	currently from:  "google.golang.org/grpc/health/grpc_health_v1"
See https://protobuf.dev/reference/go/faq#namespace-conflict

See doc in: https://protobuf.dev/reference/go/faq#namespace-conflict.
This issue arises due to the protocol/dubbo3/health/triple_health_v1/health.proto having an identical package name as https://github.com/grpc/grpc-proto/blob/master/grpc/health/v1/health.proto.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions