queue

package
v0.19.857 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2026 License: AGPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PauseHandlerName  string = "pause"
	ResumeHandlerName string = "resume"
)
View Source
const (
	ReadyHandlerName string = "ready"
	ReadyHandlerType        = handlerTypeUpdate
)
View Source
const (
	StatusHandlerName string = "status"
	StatusHandlerType        = handlerTypeUpdate
)
View Source
const EnqueueUpdateName string = "enqueue"
View Source
const RestartUpdateName string = "restart"
View Source
const StopUpdateName string = "stop"

Variables

This section is empty.

Functions

This section is empty.

Types

type EnqueueHandlerInput added in v0.19.850

type EnqueueHandlerInput struct {
	Signal    signal.Signal `json:"signal"`
	OwnerID   string        `json:"owner_id,omitempty"`
	OwnerType string        `json:"owner_type,omitempty"`
}

EnqueueHandlerInput is the input to the enqueue update handler. OwnerID and OwnerType are optional — when set, the created QueueSignal will have its polymorphic owner association populated automatically (e.g. pointing at a ComponentBuild).

type EnqueueResponse

type EnqueueResponse struct {
	ID         string
	WorkflowID string
}

type Params

type Params struct {
	fx.In

	Cfg *internal.Config
	V   *validator.Validate
}

type PauseRequest added in v0.19.850

type PauseRequest struct{}

type PauseResponse added in v0.19.850

type PauseResponse struct{}

type QueueRef

type QueueRef struct {
	WorkflowID string
	ID         string
}

type QueueState

type QueueState struct {
	QueueRefs []QueueRef
	Paused    bool
}

QueueState is the data that is passed between continue-as-news

type QueueWorkflowRequest

type QueueWorkflowRequest struct {
	QueueID string
	Version string

	ReleaseWindow *ReleaseWindow

	State *QueueState
}

type ReadyRequest

type ReadyRequest struct{}

type ReadyResponse

type ReadyResponse struct{}

type ReleaseWindow added in v0.19.850

type ReleaseWindow struct {
	// Days of the week (Mon, Tue, Wed, Thu, Fri, Sat, Sun)
	Days []string
	// StartTime in HH:MM format
	StartTime string
	// EndTime in HH:MM format
	EndTime string
	// Timezone (e.g. "America/New_York")
	Timezone string
}

func (*ReleaseWindow) IsOpen added in v0.19.850

func (w *ReleaseWindow) IsOpen(t time.Time) bool

func (*ReleaseWindow) NextOpenTime added in v0.19.850

func (w *ReleaseWindow) NextOpenTime(t time.Time) time.Time

NextOpenTime returns the next time the window opens. If the window is currently open, it returns the current time.

type RestartRequest

type RestartRequest struct{}

type RestartResponse

type RestartResponse struct{}

type ResumeRequest added in v0.19.850

type ResumeRequest struct{}

type ResumeResponse added in v0.19.850

type ResumeResponse struct{}

type StatusRequest

type StatusRequest struct{}

type StatusResponse

type StatusResponse struct {
	Ready   bool
	Stopped bool
	Paused  bool

	QueueDepthCount int
	InFlightCount   int
	InFlight        []string
}

type StopRequest

type StopRequest struct{}

type StopResponse

type StopResponse struct{}

type Workflows

type Workflows struct {
	StartupHooks []func(workflow.Context, QueueWorkflowRequest) error
	// contains filtered or unexported fields
}

func NewWorkflows

func NewWorkflows(params Params) (*Workflows, error)

func (*Workflows) All

func (q *Workflows) All() []any

func (*Workflows) Queue

@temporal-gen-v2 workflow @task-queue "queue" @id-template queue-{{.QueueID}}

Jump to

Keyboard shortcuts

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