tf

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2021 License: MPL-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AccRandTimeInt

func AccRandTimeInt() int

func ErrorDiagF added in v1.2.0

func ErrorDiagF(err error, format string, a ...interface{}) diag.Diagnostics

func ErrorDiagPathF added in v1.2.0

func ErrorDiagPathF(err error, attr string, summary string, a ...interface{}) diag.Diagnostics

func ExpandStringSlicePtr

func ExpandStringSlicePtr(input []interface{}) *[]string

func FlattenStringSlicePtr

func FlattenStringSlicePtr(input *[]string) []interface{}

func ImportAsDuplicateDiag added in v1.2.0

func ImportAsDuplicateDiag(resourceName, id string, name string) diag.Diagnostics

func ImportAsExistsDiag added in v1.2.0

func ImportAsExistsDiag(resourceName, id string) diag.Diagnostics

func LockByName

func LockByName(resourceType string, name string)

handles the case of using the same name for different kinds of resources

func Set added in v1.2.0

func Set(d *schema.ResourceData, attr string, value interface{}) diag.Diagnostics

func UnlockByName

func UnlockByName(resourceType string, name string)

func ValidateResourceIDPriorToImport

func ValidateResourceIDPriorToImport(idParser ResourceIDValidator) *schema.ResourceImporter

ValidateResourceIDPriorToImport parses the Resource ID to confirm it's valid for this Resource prior to performing an import - allowing for incorrect Resource ID's to be caught prior to Import and subsequent crashes

func ValidateResourceIDPriorToImportThen

func ValidateResourceIDPriorToImportThen(idParser ResourceIDValidator, importer schema.StateContextFunc) *schema.ResourceImporter

ValidateResourceIDPriorToImportThen parses the Resource ID to confirm it's valid for this Resource prior to calling the importer - allowing for incorrect Resource ID's to be caught prior to Import and subsequent crashes

Types

type MutexKV

type MutexKV struct {
	// contains filtered or unexported fields
}

MutexKV is a simple key/value store for arbitrary mutexes. It can be used to serialise changes across arbitrary collaborators that share knowledge of the keys they must serialise on.

func NewMutexKV

func NewMutexKV() *MutexKV

Returns a properly initialised MutexKV

func (*MutexKV) Lock

func (m *MutexKV) Lock(key string)

Locks the mutex for the given key. Caller is responsible for calling Unlock for the same key

func (*MutexKV) Unlock

func (m *MutexKV) Unlock(key string)

Unlock the mutex for the given key. Caller must have called Lock for the same key first

type ResourceIDValidator

type ResourceIDValidator func(resourceId string) error

ResourceIDValidator takes a Resource ID and confirms that it's Valid

Jump to

Keyboard shortcuts

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