TracingWorkflowInterceptor

A WorkflowInterceptor that generates a trace file that can be viewed in Chrome by visiting chrome://tracing.

Parameters

file

The File to write the trace to.

name

If non-empty, will be used to set the "process name" in the trace file. If empty, the workflow type is used for the process name.


fun TracingWorkflowInterceptor(name: String = "", memoryStats: MemoryStats = RuntimeMemoryStats, encoderProvider: (workflowScope: CoroutineScope) -> TraceEncoder): TracingWorkflowInterceptor(source)

A WorkflowInterceptor that generates a trace file that can be viewed in Chrome by visiting chrome://tracing.

Parameters

name

If non-empty, will be used to set the "process name" in the trace file. If empty, the workflow type is used for the process name.

encoderProvider

A function that returns a TraceEncoder that will be used to write trace events. The function gets the CoroutineScope that the workflow runtime is running in.