WithTaskID
Gets a new context with WorkflowName set.
def WithTaskID(
ctx: context.Context,
taskID: string
) - > context.Context
Gets a new context with WorkflowName set. This function is used to associate a specific task ID with a context, allowing subsequent operations within that context to be linked to the task.
Parameters
| Name | Type | Description |
|---|---|---|
| ctx | context.Context | The parent context to which the task ID will be added. |
| taskID | string | The unique identifier for the task to be associated with the context. |
Returns
| Type | Description |
|---|---|
context.Context | A new context derived from the input context, with the provided task ID associated. |