Skip to content

Commit

Permalink
feat: add a log in the execution when the worker cannot send a messag…
Browse files Browse the repository at this point in the history
…e to the queue
  • Loading branch information
loicmathieu committed Sep 4, 2023
1 parent f7c2cda commit 8da3eb8
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions core/src/main/java/io/kestra/core/runners/Worker.java
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,11 @@ private WorkerTaskResult run(WorkerTask workerTask, Boolean cleanUp) throws Queu
.withState(State.Type.FAILED)
);
WorkerTaskResult workerTaskResult = new WorkerTaskResult(finalWorkerTask, dynamicWorkerResults);
RunContext runContext = workerTask
.getRunContext()
.forWorker(this.applicationContext, workerTask);

runContext.logger().error("Exception while trying to emit the worker task result to the queue", e);
this.workerTaskResultQueue.emit(workerTaskResult);
return workerTaskResult;
} finally {
Expand Down

0 comments on commit 8da3eb8

Please sign in to comment.