You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by "clintropolis (via GitHub)" <gi...@apache.org> on 2023/03/09 06:41:21 UTC

[GitHub] [druid] clintropolis commented on a diff in pull request #13906: Report engine as a dimension for sqlQuery metrics

clintropolis commented on code in PR #13906:
URL: https://github.com/apache/druid/pull/13906#discussion_r1130546762


##########
sql/src/main/java/org/apache/druid/sql/SqlExecutionReporter.java:
##########
@@ -94,6 +94,9 @@ public void emit()
         metricBuilder.setDimension("id", plannerContext.getSqlQueryId());
         metricBuilder.setDimension("nativeQueryIds", plannerContext.getNativeQueryIds().toString());
       }
+      if (stmt.sqlToolbox.engine != null) {
+        metricBuilder.setDimension("engine", stmt.sqlToolbox.engine.name());

Review Comment:
   heh, the statement also has a plannerContext, so could do `plannerContext.getEngine().name()` or `stmt.plannerContext.getEngine().name()` or what you did here... probably others too 😜 
   
   Most of the other stuff looks like it is coming from `plannerContext` so that seems probably best?
   



-- 
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-unsubscribe@druid.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org