Skip to content

Commit 0f82335

Browse files
qiaofenlinCopilot
authored andcommitted
feat(trace): support external trace id propagation (langgenius#22623)
Co-authored-by: Copilot <[email protected]>
1 parent 276da33 commit 0f82335

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

api/core/ops/ops_trace_manager.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -539,6 +539,10 @@ def workflow_trace(
539539
"app_id": workflow_run.app_id,
540540
}
541541

542+
external_trace_id = self.kwargs.get("external_trace_id")
543+
if external_trace_id:
544+
metadata["external_trace_id"] = external_trace_id
545+
542546
workflow_trace_info = WorkflowTraceInfo(
543547
trace_id=self.trace_id,
544548
workflow_data=workflow_run.to_dict(),

0 commit comments

Comments
 (0)