build_ids

package
v1.22.1-patch.0 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2023 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

View Source
const (
	BuildIdScavangerWorkflowName = "build-id-scavenger"
	BuildIdScavangerActivityName = "scavenge-build-ids"

	BuildIdScavengerWFID          = "temporal-sys-build-id-scavenger"
	BuildIdScavengerTaskQueueName = "temporal-sys-build-id-scavenger-taskqueue-0"
)

Variables

View Source
var (
	BuildIdScavengerWFStartOptions = client.StartWorkflowOptions{
		ID:                    BuildIdScavengerWFID,
		TaskQueue:             BuildIdScavengerTaskQueueName,
		WorkflowIDReusePolicy: enumspb.WORKFLOW_ID_REUSE_POLICY_ALLOW_DUPLICATE,
		CronSchedule:          "0 */12 * * *",
	}
)

Functions

func BuildIdScavangerWorkflow

func BuildIdScavangerWorkflow(ctx workflow.Context, input BuildIdScavangerInput) error

BuildIdScavangerWorkflow scans all task queue user data entries in all namespaces and cleans up unused build ids. This workflow is a wrapper around the long running ScavengeBuildIds activity.

Types

type Activities

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

func NewActivities

func NewActivities(
	logger log.Logger,
	taskManager persistence.TaskManager,
	metadataManager persistence.MetadataManager,
	visibilityManager manager.VisibilityManager,
	namespaceRegistry namespace.Registry,
	matchingClient matchingservice.MatchingServiceClient,
	currentClusterName string,
	removableBuildIdDurationSinceDefault dynamicconfig.DurationPropertyFn,
	buildIdScavengerVisibilityRPS dynamicconfig.FloatPropertyFn,
) *Activities

func (*Activities) ScavengeBuildIds

func (a *Activities) ScavengeBuildIds(ctx context.Context, input BuildIdScavangerInput) error

ScavengeBuildIds scans all task queue user data entries in all namespaces and cleans up unused build ids.

type BuildIdScavangerInput

type BuildIdScavangerInput struct {
	NamespaceListPageSize int
	TaskQueueListPageSize int
	IgnoreRetentionTime   bool // If true, consider build ids added since retention time also
}

Jump to

Keyboard shortcuts

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