Class HttpConfigUtils

java.lang.Object
io.confluent.telemetry.exporter.http.HttpConfigUtils

public final class HttpConfigUtils extends Object
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static io.confluent.telemetry.config.v2.remote.RemoteConfiguration
    resolveOtlpClientBaseUrl(io.confluent.telemetry.config.v2.remote.RemoteConfiguration remoteConfig)
    Special handling for cloud deployments when "otlp" exporter is present in the remote config, but the CLIENT_BASE_URL property is missing.

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • resolveOtlpClientBaseUrl

      public static io.confluent.telemetry.config.v2.remote.RemoteConfiguration resolveOtlpClientBaseUrl(io.confluent.telemetry.config.v2.remote.RemoteConfiguration remoteConfig)
      Special handling for cloud deployments when "otlp" exporter is present in the remote config, but the CLIENT_BASE_URL property is missing. In this case, resolve it to http://{HOST_IP}:{port} where HOST_IP comes from environment. Handles both cases: 1. Non-static client: CLIENT_BASE_URL defined directly in exporter configs. 2. Static client: CLIENT_BASE_URL defined in named client configs referenced by exporter.
      Returns:
      the remote configuration with resolved CLIENT_BASE_URL for OTLP exporter, or the original configuration if no changes were made.
      Throws:
      IllegalStateException - if HOST_IP environment variable is not available during resolution