com.beachape.zipkin.services

BraveZipkinService

class BraveZipkinService extends ZipkinServiceLike

ZipkinService based on Brave.

There should be at most 1 of these instances in a given running app, shared between multiple objects that need tracing.

Linear Supertypes
ZipkinServiceLike, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. BraveZipkinService
  2. ZipkinServiceLike
  3. AnyRef
  4. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new BraveZipkinService(hostIp: String, hostPort: Int, serviceName: String, collector: SpanCollector, clientTraceFilters: Seq[(Span) ⇒ Boolean] = collection.this.Seq.empty[Nothing], serverTraceFilters: Seq[(Span) ⇒ Boolean] = collection.this.Seq.empty[Nothing])(implicit eCtx: ExecutionContext)

    collector

    a SpanCollector

    clientTraceFilters

    a List of span filters for client spans. List can be empty if you don't want trace filtering (sampling). The trace filters will be executed in order. If one returns false there will not be tracing and the next trace filters will not be executed anymore.

    In a typical server-side app, it might be a good idea to have a { s => s.isSetParent_id } in here in case you want to make sure no orphaned client-spans get sent.

    *Note* this will only be used for clientReceived, not clientSent.

    serverTraceFilters

    List of span filters for client spans. List can be empty if you don't want trace filtering (sampling). The trace filters will be executed in order. If one returns false there will not be tracing and the next trace filters will not be executed anymore.

    *Note* this will only be used for serverReceived, not serverSent.

Type Members

  1. type ClientSpan = Span

    Customisable client span type

    Customisable client span type

    Definition Classes
    BraveZipkinServiceZipkinServiceLike
  2. type ServerSpan = github.kristofa.brave.ServerSpan

    Customisable server span type

    Customisable server span type

    Definition Classes
    BraveZipkinServiceZipkinServiceLike

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clientReceived(span: ClientSpan, annotations: (String, String)*): Future[ClientSpan]

    Creates a ClientSpan with a ClientReceived annotation that will be used to signal to the Zipkin collector that a Client Received event has occurred at the current time.

    Creates a ClientSpan with a ClientReceived annotation that will be used to signal to the Zipkin collector that a Client Received event has occurred at the current time.This method *should* be used to also actually send the underlying Span to the Zipkin server.

    If annotations are provided, they will also be added.

    Definition Classes
    BraveZipkinServiceZipkinServiceLike
  8. def clientSent(span: Span, annotations: (String, String)*): Future[Option[ClientSpan]]

    Creates a ClientSpan with a ClientSent annotation that will later be used to signal to the Zipkin collector that a Client Sent event has occurred at the current time.

    Creates a ClientSpan with a ClientSent annotation that will later be used to signal to the Zipkin collector that a Client Sent event has occurred at the current time.

    If annotations are provided, they will also be added.

    Definition Classes
    BraveZipkinServiceZipkinServiceLike
  9. def clientSpanToSpan(clientSpan: ClientSpan): ClientSpan

    Provides a way of turning a custom ClientSpan back into a normal Span

    Provides a way of turning a custom ClientSpan back into a normal Span

    Definition Classes
    BraveZipkinServiceZipkinServiceLike
  10. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  11. implicit val eCtx: ExecutionContext

    The execution context provided by and used within this service for tracing purposes

    The execution context provided by and used within this service for tracing purposes

    Definition Classes
    BraveZipkinServiceZipkinServiceLike
  12. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  13. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  14. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  15. def generateSpan(name: String, parent: Span): Span

    Returns a Span based on a name and a parent Span, which may or may not be used

    Returns a Span based on a name and a parent Span, which may or may not be used

    In essence, checks for a trace id on the parent Span, if it exists, uses the parent Span's trace id as the returned Span's trace id and the parent id as the returned Span's parentId.

    The returned Span is guaranteed to have a new id and the name passed.

    Definition Classes
    ZipkinServiceLike
  16. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  17. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  18. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  19. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  20. def nextId: Long

    Returns an id

    Returns an id

    Definition Classes
    ZipkinServiceLike
  21. final def notify(): Unit

    Definition Classes
    AnyRef
  22. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  23. def sendableSpan(span: Span): Boolean

    Determines if the Span is minimally sendable to Zipkin (has an id, has a trace id, and has a non-empty name)

    Determines if the Span is minimally sendable to Zipkin (has an id, has a trace id, and has a non-empty name)

    Attributes
    protected[com.beachape.zipkin.services]
    Definition Classes
    ZipkinServiceLike
  24. def serverReceived(span: Span, annotations: (String, String)*): Future[Option[ServerSpan]]

    Returns a ServerSpan with a ServerReceived annotation that will later be used to signal to the Zipkin collector that a server received event has occurred at the current time.

    Returns a ServerSpan with a ServerReceived annotation that will later be used to signal to the Zipkin collector that a server received event has occurred at the current time.

    If annotations are provided, they will also be added.

    Definition Classes
    BraveZipkinServiceZipkinServiceLike
  25. def serverSent(span: ServerSpan, annotations: (String, String)*): Future[ServerSpan]

    Returns a ServerSpan with a ServerSent annotation that will be used to signal to the Zipkin collector that a server Sent event has occurred at the current time.

    Returns a ServerSpan with a ServerSent annotation that will be used to signal to the Zipkin collector that a server Sent event has occurred at the current time. This method *should* be used to also actually send the underlying Span to the Zipkin server.

    If annotations are provided, they will also be added.

    Definition Classes
    BraveZipkinServiceZipkinServiceLike
  26. def serverSpanToSpan(serverSpan: ServerSpan): ClientSpan

    Provides a way of turning a custom ServerSpan back into a normal Span

    Provides a way of turning a custom ServerSpan back into a normal Span

    Definition Classes
    BraveZipkinServiceZipkinServiceLike
  27. def spanToIdsMap(span: Span): Map[String, String]

    Turns a Span into a Map[String, String].

    Turns a Span into a Map[String, String].

    The keys of the map are the official Zipkin id Header strings (e.g. X-B3-TraceId), and the values are the hexadecimal string versions of those ids.

    Useful turning a Span into a data structure that can be more easily serialised in order to be passed onto other systems via some kind of transport protocol.

    Definition Classes
    ZipkinServiceLike
  28. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  29. def toString(): String

    Definition Classes
    AnyRef → Any
  30. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  31. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  32. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from ZipkinServiceLike

Inherited from AnyRef

Inherited from Any

Ungrouped