Tabnine Logo
BraveSpanContext.unwrap
Code IndexAdd Tabnine to your IDE (free)

How to use
unwrap
method
in
brave.opentracing.BraveSpanContext

Best Java code snippets using brave.opentracing.BraveSpanContext.unwrap (Showing top 3 results out of 315)

origin: openzipkin-contrib/brave-opentracing

/**
 * Injects the underlying context using B3 encoding by default.
 */
@Override public <C> void inject(SpanContext spanContext, Format<C> format, C carrier) {
 Injector<TextMap> injector = formatToInjector.get(format);
 if (injector == null) {
  throw new UnsupportedOperationException(format + " not in " + formatToInjector.keySet());
 }
 TraceContext traceContext = ((BraveSpanContext) spanContext).unwrap();
 injector.inject(traceContext, (TextMap) carrier);
}
origin: openzipkin-contrib/brave-opentracing

} else if ((context = reference.unwrap()) != null) {
origin: xjdr/xio

if (receivedContext != null) {
 if (receivedContext instanceof BraveSpanContext) {
  if (((BraveSpanContext) receivedContext).unwrap() != null) {
   spanBuilder.asChildOf(receivedContext);
brave.opentracingBraveSpanContextunwrap

Javadoc

Returns the underlying trace context for use in Brave apis, or null if this object does not represent a span.

When a span context is returned from BraveSpan#context(), there's no ambiguity. It represents the current span. However, a span context can be in an intermediate state when extracted from headers. In other words, unwrap might not have a TraceContext to return.

Why? BraveTracer#extract(Format,Object) can return partial info. For example, in Amazon Web Services, you may be suggested just a trace ID. In other cases, you might just inherit baggage or a sampling hint.

Popular methods of BraveSpanContext

  • create

Popular in Java

  • Running tasks concurrently on multiple threads
  • scheduleAtFixedRate (ScheduledExecutorService)
  • setRequestProperty (URLConnection)
  • onRequestPermissionsResult (Fragment)
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • Hashtable (java.util)
    A plug-in replacement for JDK1.5 java.util.Hashtable. This version is based on org.cliffc.high_scale
  • Properties (java.util)
    A Properties object is a Hashtable where the keys and values must be Strings. Each property can have
  • Reference (javax.naming)
  • Filter (javax.servlet)
    A filter is an object that performs filtering tasks on either the request to a resource (a servlet o
  • DataSource (javax.sql)
    An interface for the creation of Connection objects which represent a connection to a database. This
  • CodeWhisperer alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now