debugutils

package
v0.16.6 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsDebugOrHigher added in v0.16.0

func IsDebugOrHigher() bool

IsDebugOrHigher reports whether TF_LOG is set to DEBUG or TRACE (case-insensitive). Unrecognized non-empty TF_LOG values are treated as TRACE, matching terraform-plugin-sdk/v2/helper/logging.IsDebugOrHigher SDK compatibility behavior.

func IsSensitiveInSchema added in v0.16.0

func IsSensitiveInSchema() bool

IsSensitiveInSchema reports whether integration-policy variable attributes should be marked sensitive in the resource schema (masked unless debug logging or acceptance tests).

func LogHTTPRequest

func LogHTTPRequest(ctx context.Context, name string, req *http.Request)

LogHTTPRequest dumps an outgoing HTTP request and emits it via tflog.Debug, pretty-printing any JSON body. name identifies the API/client the request belongs to and is used to label the log entry.

func LogHTTPResponse

func LogHTTPResponse(ctx context.Context, name string, resp *http.Response)

LogHTTPResponse dumps an HTTP response and emits it via tflog.Debug, pretty-printing any JSON body. name identifies the API/client the response belongs to and is used to label the log entry.

func NewDebugTransport

func NewDebugTransport(name string, transport http.RoundTripper) http.RoundTripper

func PrettyPrintJSONLines

func PrettyPrintJSONLines(b []byte) string

PrettyPrintJSONLines iterates through a []byte line-by-line, transforming any lines that are complete json into pretty-printed json.

Types

This section is empty.

Jump to

Keyboard shortcuts

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