shared

package
v1.14.0-alpha2 Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2026 License: MPL-2.0 Imports: 10 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var EphemeralResourceCloseTimeout = 10 * time.Second

This may be modified to expedite tests

Functions

func ContextWithTracer

func ContextWithTracer(parent context.Context, tracer *Tracer) context.Context

ContextWithTracer returns a new context derived from parent that carries a Tracer.

Use the resulting context when calling [ApplyPlannedChanges], to get event notification callbacks throughout the planning process.

Types

type EphemeralCloseFunc

type EphemeralCloseFunc func(context.Context) tfdiags.Diagnostics

type Tracer

type Tracer struct {

	// StartEphemeralResourceInstanceOpen and EndEphemeralResourceInstanceOpen
	// mark the beginning and end of the work to open the identified ephemeral
	// resource instance.
	StartEphemeralResourceInstanceOpen func(ctx context.Context, addr addrs.AbsResourceInstance) context.Context
	EndEphemeralResourceInstanceOpen   func(ctx context.Context, addr addrs.AbsResourceInstance, diags tfdiags.Diagnostics)

	// StartEphemeralResourceInstanceRenew and EndEphemeralResourceInstanceRenew
	// mark the beginning and end of the work to renew the identified ephemeral
	// resource instance.
	StartEphemeralResourceInstanceRenew func(ctx context.Context, addr addrs.AbsResourceInstance) context.Context
	EndEphemeralResourceInstanceRenew   func(ctx context.Context, addr addrs.AbsResourceInstance, diags tfdiags.Diagnostics)

	// StartEphemeralResourceInstanceClose and EndEphemeralResourceInstanceClose
	// mark the beginning and end of the work to close the identified ephemeral
	// resource instance.
	StartEphemeralResourceInstanceClose func(ctx context.Context, addr addrs.AbsResourceInstance) context.Context
	EndEphemeralResourceInstanceClose   func(ctx context.Context, addr addrs.AbsResourceInstance, diags tfdiags.Diagnostics)
}

Tracer represents a set of tracing event handlers for events that are common across the planning and applying phases.

Jump to

Keyboard shortcuts

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