Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SlogHandler ¶ added in v0.26.0
type SlogHandler struct {
MessagePrefix string
// contains filtered or unexported fields
}
SlogHandler forwards log/slog records to tflog, so that records the meshStack CLI's pkg/ packages write through the slog default logger land in the terraform log stream.
It carries more than debugging output, because pkg/ reports to a front end in exactly two ways — an error return, or an slog record. A warning it raises therefore reaches a practitioner as a TF_LOG=WARN log line and never as a warning diagnostic in plan output.
func (SlogHandler) Enabled ¶ added in v0.26.0
Enabled passes everything through, because tflog owns the level: TF_LOG decides what terraform keeps, and a filter here would hide records the practitioner asked for. The cost is that every record is handled, including the ones TF_LOG drops, so nothing here may render an attribute.