Configuration

com.ovoenergy.natchez.extras.http4s.Configuration$
See theConfiguration companion class

Attributes

Companion:
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type

Members list

Concise view

Type members

Classlikes

final case class TagReader[F[_], -A](value: Kleisli[F, A, Tags]) extends AnyVal

A tag reader is essentially a function from an HTTP message to F[Tags] We need the effect because some tags may involve streaming the entity body

A tag reader is essentially a function from an HTTP message to F[Tags] We need the effect because some tags may involve streaming the entity body

Attributes

Companion:
object
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class AnyVal
trait Matchable
class Any
object TagReader

Attributes

Companion:
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Types

type Tags = Map[String, TraceValue]

Inherited types

type MirroredElemLabels <: Tuple

The names of the product elements

The names of the product elements

Attributes

Inherited from:
Mirror
type MirroredLabel <: String

The name of the type

The name of the type

Attributes

Inherited from:
Mirror

Value members

Concrete methods

def const[F[_] : Applicative](name: String, value: TraceValue): MessageReader[F]

create a TagReader that ignores the message and always adds the given value Useful for static tags like environment or team name

create a TagReader that ignores the message and always adds the given value Useful for static tags like environment or team name

Attributes

def default[F[_] : Sync](defaults: (String, TraceValue)*): Configuration[F]

Create a default configuration for tracing HTTP4s calls. This uses Datadog tag names but the idea is you can make your own configs with ease.

Create a default configuration for tracing HTTP4s calls. This uses Datadog tag names but the idea is you can make your own configs with ease.

Attributes

def entity[F[_] : Sync](name: String): MessageReader[F]

Extract the entity from the HTTP message into a strict string and place that into the span. This may not be ideal if you're streaming things.

Extract the entity from the HTTP message into a strict string and place that into the span. This may not be ideal if you're streaming things.

Attributes

def headers[F[_] : Applicative](name: String)(redact: CIString => Boolean): MessageReader[F]

Extract headers from the HTTP message, redact sensitive ones and place them into the span with the given tag name separated by newlines

Extract headers from the HTTP message, redact sensitive ones and place them into the span with the given tag name separated by newlines

Attributes

def ifFailure[F[_] : Applicative](tr: MessageReader[F]): ResponseReader[F]

Only run the given tag extractor if the response was not successful This is useful for adding extra tags in the case of errors

Only run the given tag extractor if the response was not successful This is useful for adding extra tags in the case of errors

Attributes

def method[F[_] : Applicative](name: String): RequestReader[F]

Extract the URI from the request and place it into the Span

Extract the URI from the request and place it into the Span

Attributes

def noop[F[_] : Applicative]: MessageReader[F]

A Tag reader that just returns an empty map

A Tag reader that just returns an empty map

Attributes

def statusCode[F[_] : Applicative](name: String): ResponseReader[F]

Extract the status code from the response and place it into the Span

Extract the status code from the response and place it into the Span

Attributes

def uri[F[_] : Applicative](name: String): RequestReader[F]

Extract the URI from the request and place it into the Span

Extract the URI from the request and place it into the Span

Attributes