contextx

package
v1.19.2 Latest Latest
Warning

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

Go to latest
Published: May 5, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithSkipEnumInUseCheck

func WithSkipEnumInUseCheck(ctx context.Context) context.Context

WithSkipEnumInUseCheck returns a new context with the skip flag set for custom enums deletion. This should be used when deleting CustomTypeEnums as part of a cascade delete where the deletion order is handled by EdgeCleanup.

Types

type SkipCustomEnumDeleteKey

type SkipCustomEnumDeleteKey string

SkipCustomEnumDeleteKey is the context key used to skip the "in use" errors check during enum deletion. This is used during organization cascade deletion where the deletion order is handled by EdgeCleanup. else the custom deletion by default will check if the enum is being used by another other object. But with this, we can just skip the check because when the org itself is deleted, it cascades to delete the custom enums too

const (
	// SkipCustomEnumInUseCheck is the context value that triggers skipping the "in use" check/error during enum deletion.
	SkipCustomEnumInUseCheck SkipCustomEnumDeleteKey = "custom_enum_cascade_delete_operation"
)

Jump to

Keyboard shortcuts

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