merlimat commented on code in PR #22179:
URL: https://github.com/apache/pulsar/pull/22179#discussion_r1511842706


##########
pulsar-client/src/main/java/org/apache/pulsar/client/impl/BinaryProtoLookupService.java:
##########
@@ -84,6 +92,21 @@ public BinaryProtoLookupService(PulsarClientImpl client,
         this.serviceNameResolver = new PulsarServiceNameResolver();
         this.listenerName = listenerName;
         updateServiceUrl(serviceUrl);
+
+        Attributes attrs = 
Attributes.of(AttributeKey.stringKey("transport-type"), "binary");
+
+        histoGetBroker = 
client.instrumentProvider().newLatencyHistogram("pulsar.client.lookup",

Review Comment:
   Since the unit is `seconds`, the metric name gets change (at least in 
Prometheus exporter) to: 
   
   ```
   # HELP pulsar_client_lookup_seconds Duration of lookup operations
   # TYPE pulsar_client_lookup_seconds histogram
   
pulsar_client_lookup_seconds_bucket{otel_scope_name="org.apache.pulsar.client",otel_scope_version="3.3.0-SNAPSHOT",pulsar_lookup_transport_type="binary",pulsar_lookup_type="metadata",success="true",le="5.0E-4"}
 0
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to