package errorhandler
Import Path
go.opentelemetry.io/otel/internal/errorhandler (on go.dev)
Dependency Relation
imports 4 packages, and imported by 2 packages
Involved Source Files
Package errorhandler provides the global error handler for OpenTelemetry.
This package has no OTel dependencies, allowing it to be imported by any
package in the module without creating import cycles.
Package-Level Type Names (total 2)
(*ErrDelegator) Handle(err error)
*ErrDelegator : ErrorHandler
*ErrDelegator : go.opentelemetry.io/otel.ErrorHandler
ErrorHandler handles irremediable events.
Handle handles any error deemed irremediable by an OpenTelemetry
component.
*ErrDelegator
go.opentelemetry.io/otel.ErrorHandler (interface)
go.opentelemetry.io/otel.ErrorHandlerFunc
ErrorHandler : go.opentelemetry.io/otel.ErrorHandler
func GetErrorHandler() ErrorHandler
func SetErrorHandler(h ErrorHandler)
Package-Level Functions (total 2)
GetErrorHandler returns the global ErrorHandler instance.
The default ErrorHandler instance returned will log all errors to STDERR
until an override ErrorHandler is set with SetErrorHandler. All
ErrorHandler returned prior to this will automatically forward errors to
the set instance instead of logging.
Subsequent calls to SetErrorHandler after the first will not forward errors
to the new ErrorHandler for prior returned instances.
SetErrorHandler sets the global ErrorHandler to h.
The first time this is called all ErrorHandler previously returned from
GetErrorHandler will send errors to h instead of the default logging
ErrorHandler. Subsequent calls will set the global ErrorHandler, but not
delegate errors to h.
![]() |
The pages are generated with Golds v0.8.2. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @zigo_101 (reachable from the left QR code) to get the latest news of Golds. |