package internallog

import "github.com/googleapis/gax-go/v2/internallog"

Package internallog in intended for internal use by generated clients only.

Index

Functions

func HTTPRequest

func HTTPRequest(req *http.Request, body []byte) slog.LogValuer

HTTPRequest returns a lazily evaluated slog.LogValuer for a http.Request and the associated body.

func HTTPResponse

func HTTPResponse(resp *http.Response, body []byte) slog.LogValuer

HTTPResponse returns a lazily evaluated slog.LogValuer for a http.Response and the associated body.

func New

func New(l *slog.Logger) *slog.Logger

New returns a new slog.Logger default logger, or the provided logger if non-nil. The returned logger will be a no-op logger unless the environment variable GOOGLE_SDK_GO_LOGGING_LEVEL is set.

Source Files

internallog.go

Directories

PathSynopsis
internallog/grpclogPackage grpclog in intended for internal use by generated clients only.
internallog/internalPackage internal provides some common logic and types to other logging sub-packages.
Version
v2.14.1 (latest)
Published
Dec 20, 2024
Platform
linux/amd64
Imports
8 packages
Last checked
8 hours ago

Tools for package owners.