open-telemetry / open-telemetry/opentelemetry-java

Please do not deprecate OtlpGrpcMetricExporterBuilder#setChannel

Open
#4,531 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Feature Request
Dominant language
Java
Stars
2.5k
Forks
1k
Avg merge
3d 17h
Merged PRs (30d)
58

Description

As we can see, OtlpGrpcMetricExporterBuilder#setChannel has been marked as deprecated.

  /**
   * Sets the managed chanel to use when communicating with the backend. Takes precedence over
   * {@link #setEndpoint(String)} if both are called.
   *
   * @param channel the channel to use
   * @return this builder's instance
   * @deprecated Use {@link #setEndpoint(String)}. If you have a use case not satisfied by the
   *     methods on this builder, please file an issue to let us know what it is.
   */
  @Deprecated
  public OtlpGrpcMetricExporterBuilder setChannel(ManagedChannel channel) {
    delegate.setChannel(channel);
    return this;
  }

In our case, we have the need that put multiple ipv4/ipv6 addresses into one ManagedChannel rather than using domain name directly. To achieve this goal, we also customized the corresponding load balancing strategy in gRPC.

So I don't think OtlpGrpcMetricExporterBuilder#setEndpoint is universal enough.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with OtlpGrpcMetricExporterBuilder#setChannel and compare it with setEndpoint(String), including the documented precedence and deprecation text. Determine whether the reported ManagedChannel and custom gRPC load-balancing use case can remain supported; done means the project has a decided, documented outcome for the deprecation request.

Written by the indexing model from the issue text.

Assessment

Tech stack
grpc, java
Domain
api, observability-sre
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.