dragosvictor commented on code in PR #22010:
URL: https://github.com/apache/pulsar/pull/22010#discussion_r1483407313


##########
.github/workflows/pulsar-ci.yaml:
##########
@@ -589,6 +589,10 @@ jobs:
           - name: Transaction
             group: TRANSACTION
 
+          - name: Metrics
+            group: METRICS
+            no_coverage: true

Review Comment:
   Not really, I'll enable it 👍 



##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/PulsarService.java:
##########
@@ -897,6 +902,7 @@ public void start() throws PulsarServerException {
             }
 
             this.metricsGenerator = new MetricsGenerator(this);
+            this.openTelemetry = new PulsarBrokerOpenTelemetry(config);

Review Comment:
   The feature is opt-in by means of environment variables/system properties. 
Note that the library doesn't tell you if it's enabled or not, so we'd have to 
hack our way to learn that. 
   
   If disabled, as it is by default, all the meters and instruments created are 
no-op and backed by the same objects (except for any internal counters we use, 
such as `AtomicInteger` or `LongAdder`). The test bits 
[here](https://github.com/apache/pulsar/pull/22010/files#diff-a91fcdff408e56151d7b267fec0341240b76a34680d310698666747a1884e303R204-R215)
 validate this.
   
   With this in mind, I think this is a fair balance between ease of use and 
resource usage.



##########
pulsar-functions/worker/src/main/java/org/apache/pulsar/functions/worker/PulsarWorkerService.java:
##########
@@ -188,6 +190,7 @@ public void init(WorkerConfig workerConfig,
         this.statsUpdater = Executors
             .newSingleThreadScheduledExecutor(new 
DefaultThreadFactory("worker-stats-updater"));
         this.metricsGenerator = new MetricsGenerator(this.statsUpdater, 
workerConfig);
+        this.openTelemetry = new PulsarWorkerOpenTelemetry(workerConfig);

Review Comment:
   Should be similar to the situation in 
https://github.com/apache/pulsar/pull/22010/files#r1482913049.



-- 
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: commits-unsubscr...@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to