cryptoe commented on code in PR #18444:
URL: https://github.com/apache/druid/pull/18444#discussion_r2317800707
##########
extensions-core/kubernetes-overlord-extensions/src/main/java/org/apache/druid/k8s/overlord/KubernetesPeonLifecycle.java:
##########
@@ -349,6 +356,24 @@ protected void startWatchingLogs()
}
protected void saveLogs()
+ {
+ ExecutorService executor = Executors.newSingleThreadExecutor();
+ try {
+ Future<?> future = executor.submit(this::doSaveLogs);
+ future.get(logSaveTimeoutMs, TimeUnit.MILLISECONDS);
+ }
+ catch (TimeoutException e) {
+ log.warn("saveLogs() timed out after %d ms for task [%s]",
logSaveTimeoutMs, taskId.getOriginalTaskId());
+ }
+ catch (Exception e) {
+ log.error(e, "saveLogs() failed for task [%s]",
taskId.getOriginalTaskId());
Review Comment:
Since tasks logs would not visible this has to be phrased in a manner that
the cluster admin can understand.
`Unable to save logs from the for the task[s] on location[details]. This
does not have any impact on the work done by of the task. If this continues to
happen, check Kubernetes server logs for potential errors `.
##########
extensions-core/kubernetes-overlord-extensions/src/main/java/org/apache/druid/k8s/overlord/KubernetesPeonLifecycle.java:
##########
@@ -349,6 +356,24 @@ protected void startWatchingLogs()
}
protected void saveLogs()
+ {
+ ExecutorService executor = Executors.newSingleThreadExecutor();
Review Comment:
Lets name the thread.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]