package tracing
Ordering
- Alphabetic
Visibility
- Public
- Protected
Package Members
- package propagation
Type Members
- sealed abstract class StatusMapper[-E, -A] extends AnyRef
Maps the result of a wrapped ZIO effect to the status of the io.opentelemetry.api.trace.Span.
Maps the result of a wrapped ZIO effect to the status of the io.opentelemetry.api.trace.Span.
For more details, see: Set status
Usage examples:
StatusMapper.failure[MyError](_ => StatusCode.ERROR)(e => Some(new RuntimeException(e.message))) StatusMapper.failureNoException(_ => StatusCode.ERROR) StatusMapper.failureThrowable(StatusCode.ERROR) StatusMapper.success[Response] { resp => if(resp.code == 500) StatusCode.ERROR else StatusCode.OK } { resp => if(resp.code == 500) Some(resp.errorMessage) else None } StatusMapper.successNoDescription[Response](_ => StatusCode.OK) StatusMapper.both( StatusMapper.failureThrowable(StatusCode.ERROR), StatusMapper.successNoDescription[Any](_ => StatusCode.OK) )
- trait Tracing extends AnyRef
Value Members
- object StatusMapper
- object Tracing