Class LowAllocationMetricsRequestMarshaler

java.lang.Object
io.opentelemetry.exporter.internal.marshal.Marshaler
io.opentelemetry.exporter.internal.otlp.metrics.LowAllocationMetricsRequestMarshaler

public final class LowAllocationMetricsRequestMarshaler extends Marshaler
Marshaler to convert SDK MetricData to OTLP ExportMetricsServiceRequest. See MetricsRequestMarshaler.

Example usage:

void marshal(LowAllocationMetricsRequestMarshaler requestMarshaler, OutputStream output,
    Collection<MetricData> metricDataList) throws IOException {
  requestMarshaler.initialize(metricDataList);
  try {
    requestMarshaler.writeBinaryTo(output);
  } finally {
    requestMarshaler.reset();
  }
}

This class is internal and is hence not for public use. Its APIs are unstable and can change at any time.