Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,5 @@ public class LoggerTag {
public static final String TASK_LIST = "TaskList";
public static final String WORKFLOW_ID = "WorkflowID";
public static final String WORKFLOW_TYPE = "WorkflowType";
public static final String ATTEMPT = "Attempt";
}
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ public void handle(PollForActivityTaskResponse task) throws Exception {
MDC.put(LoggerTag.ACTIVITY_TYPE, task.getActivityType().getName());
MDC.put(LoggerTag.WORKFLOW_ID, task.getWorkflowExecution().getWorkflowId());
MDC.put(LoggerTag.RUN_ID, task.getWorkflowExecution().getRunId());
MDC.put(LoggerTag.ATTEMPT, String.valueOf(task.getAttempt()));

propagateContext(task);
Span span = spanFactory.spanForExecuteActivity(task);
Expand Down Expand Up @@ -175,6 +176,7 @@ public void handle(PollForActivityTaskResponse task) throws Exception {
MDC.remove(LoggerTag.ACTIVITY_TYPE);
MDC.remove(LoggerTag.WORKFLOW_ID);
MDC.remove(LoggerTag.RUN_ID);
MDC.remove(LoggerTag.ATTEMPT);
unsetCurrentContext();
}
}
Expand Down