dockerzhang commented on code in PR #11351:
URL: https://github.com/apache/inlong/pull/11351#discussion_r1808162138
##########
inlong-sort/sort-flink/sort-flink-v1.15/sort-connectors/kafka/src/main/java/org/apache/inlong/sort/kafka/source/reader/KafkaSourceReader.java:
##########
@@ -87,6 +90,22 @@ public KafkaSourceReader(
"Offset commit on checkpoint is disabled. "
+ "Consuming offset will not be reported back to
Kafka cluster.");
}
+ this.openTelemetryLogger = new OpenTelemetryLogger.Builder()
+ .setLogLevel(Level.ERROR)
+ .setServiceName(this.getClass().getSimpleName())
+ .setLocalHostIp(this.context.getLocalHostName()).build();
+ }
+
+ @Override
+ public void start() {
+ this.openTelemetryLogger.install();
+ super.start();
+ }
+
+ @Override
+ public void close() throws Exception {
+ super.close();
+ openTelemetryLogger.uninstall(); // 关闭日志上报功能
Review Comment:
please use the English comments.
--
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]