context

package
v0.0.0-...-0a38112 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DBFromContext

func DBFromContext(ctx context.Context) (*gorm.DB, error)

DBFromContext retrieve the gorm.DB data struct from the context.

func LogFromContext

func LogFromContext(ctx context.Context) *slog.Logger

LogFromContext retrieve the identity.XRHID data struct from the context.

func WithDB

func WithDB(ctx context.Context, value *gorm.DB) context.Context

WithDB create a new context with the provided database value.

func WithLog

func WithLog(ctx context.Context, value *slog.Logger) context.Context

WithLog create a new context with the provided log value.

Types

This section is empty.

Jump to

Keyboard shortcuts

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