How to use the @azure/core-tracing.extractSpanContextFromTraceParentHeader function in @azure/core-tracing

To help you get started, we’ve selected a few @azure/core-tracing examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Azure / azure-sdk-for-js / sdk / eventhub / event-hubs / src / diagnostics / instrumentEventData.ts View on Github external
export function extractSpanContextFromEventData(eventData: EventData): SpanContext | undefined {
  if (!eventData.properties || !eventData.properties[TRACEPARENT_PROPERTY]) {
    return;
  }

  const diagnosticId = eventData.properties[TRACEPARENT_PROPERTY];
  return extractSpanContextFromTraceParentHeader(diagnosticId);
}

@azure/core-tracing

Provides low-level interfaces and helper methods for tracing in Azure SDK

MIT
Latest version published 2 months ago

Package Health Score

84 / 100
Full package analysis