ttlcontroller

package
v2.0.0 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package ttlcontroller provides a TTL (time to live) mechanism to clear old objects in the database.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(ctx context.Context, c *Controller)

Register periodically calls function runWorker to delete the data.

Types

type Controller

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

func Bootstrap

func Bootstrap(event core.EventStore, experiment core.ExperimentStore, schedule core.ScheduleStore, workflow core.WorkflowStore, ttlc *config.TTLConfig, logger logr.Logger) *Controller

func NewController

func NewController(
	event core.EventStore,
	experiment core.ExperimentStore,
	schedule core.ScheduleStore,
	workflow core.WorkflowStore,
	ttlconfig *config.TTLConfig,
	logger logr.Logger,
) *Controller

NewController returns a new database ttl controller

Jump to

Keyboard shortcuts

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