FrankChen021 edited a comment on pull request #9919:
URL: https://github.com/apache/druid/pull/9919#issuecomment-636329083
Now a metric `metadataStorageSql/time` with 2 demensions ( sql, uri ) is
provided. The value of this metric the execution time of the sql in
milliseconds.
The default log emitter prints this metric as below
````
2020-05-30T13:04:30,482 INFO [config-manager-0]
org.apache.druid.java.util.emitter.core.LoggingEmitter -
{"feed":"metrics","timestamp":"2020-05-30T13:04:30.481Z","service":"coordinator","host":"localhost:8081","version":"","metric":"metadataStorage/sql/time","value":446681,"sql":"SELECT
payload FROM druid_config WHERE name =
?","uri":"jdbc:mysql://localhost:3306/druid"}
2020-05-30T13:04:30,483 INFO [config-manager-0]
org.apache.druid.java.util.emitter.core.LoggingEmitter -
{"feed":"metrics","timestamp":"2020-05-30T13:04:30.483Z","service":"coordinator","host":"localhost:8081","version":"","metric":"metadataStorage/sql/time","value":375036,"sql":"SELECT
payload FROM druid_config WHERE name =
?","uri":"jdbc:mysql://localhost:3306/druid"}
2020-05-30T13:04:30,485 INFO [config-manager-0]
org.apache.druid.java.util.emitter.core.LoggingEmitter -
{"feed":"metrics","timestamp":"2020-05-30T13:04:30.484Z","service":"coordinator","host":"localhost:8081","version":"","metric":"metadataStorage/sql/time","value":419938,"sql":"SELECT
payload FROM druid_config WHERE name =
?","uri":"jdbc:mysql://localhost:3306/druid"}
2020-05-30T13:04:30,486 INFO [config-manager-0]
org.apache.druid.java.util.emitter.core.LoggingEmitter -
{"feed":"metrics","timestamp":"2020-05-30T13:04:30.486Z","service":"coordinator","host":"localhost:8081","version":"","metric":"metadataStorage/sql/time","value":380552,"sql":"SELECT
payload FROM druid_config WHERE name =
?","uri":"jdbc:mysql://localhost:3306/druid"}
````
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]