OpenTelemetry PHP

SpanContextValidator
in package

Table of Contents

Constants

INVALID_SPAN  : mixed = '0000000000000000'
INVALID_TRACE  : mixed = '00000000000000000000000000000000'
SPAN_LENGTH  : mixed = 16
SPAN_LENGTH_BYTES  : mixed = 8
TRACE_LENGTH  : mixed = 32
VALID_SPAN  : mixed = '/^[0-9a-f]{16}$/'
VALID_TRACE  : mixed = '/^[0-9a-f]{32}$/'

Methods

isValidSpanId()  : bool
isValidTraceId()  : bool

Constants

Methods

isValidSpanId()

public static isValidSpanId(string $spanId) : bool
Parameters
$spanId : string
Return values
bool —

Returns a value that indicates whether a span id is valid

isValidTraceId()

public static isValidTraceId(string $traceId) : bool
Parameters
$traceId : string
Return values
bool —

Returns a value that indicates whether a trace id is valid

On this page

Search results