observability

package
v1.11.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 25, 2023 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package observability provides abstractions for tracing, metrics, etc.

TODO https://github.com/FerretDB/FerretDB/issues/3244

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FuncCall

func FuncCall(ctx context.Context) func()

FuncCall adds observability to a function call.

It should be called at the very beginning of the function, and returned function should be called at exit. The returned function must not be passed or stored. The only valid way to use FuncCall is:

func foo(ctx context.Context) {
    defer FuncCall(ctx)()
    // ...

For the Go execution tracer, FuncCall creates a new region for the function call and attaches it to the task in the context (or background task).

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL