Attach
Applicability
Product |
Supported (Yes/No) |
|---|---|
x |
|
√ |
|
x |
|
√ |
|
x |
For
For
Function Description
Adds Trace information to the current context.
Prototype
1 | size_t Attach(const TraceId traceId, const SpanId spanId, const bool isSample = true) |
Parameter Description
Parameter |
Input/Output |
Description |
|---|---|---|
traceId |
Input |
Trace ID. |
spanId |
Input |
Span ID. |
isSample |
Input |
Sampling or not; defaults to true. |
Return Value Description
Returns the context index, which is used to call Unattach.
Parent topic: TraceContext Class