Skip to content

Add an environment variable for overriding gRPC default authority #4278

Open
@vishaalram02

Description

@vishaalram02

Is your feature request related to a problem?

When exporting to a unix domain socket, typically the default authority is set to localhost instead of the socket path since otherwise the authority is invalid and gets rejected by the gRPC server. See issues hyperium/h2#487 and hyperium/tonic#742.

Describe the solution you'd like

I'd like an environment variable such as OTEL_EXPORTER_OTLP_AUTHORITY or a more general variable to override channel options:

self.channel = grpc.insecure_channel(self.endpoint, options=[('grpc.default_authority', OTEL_EXPORTER_OTLP_AUTHORITY)])

Describe alternatives you've considered

None

Additional Context

No response

Would you like to implement a fix?

Yes

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions