eventhandler

package
v0.0.0-...-e28bd7b Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2024 License: BSD-3-Clause Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CreationHandler

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

CreationHandler handles creation of deployment. This handles only perform permission checks and basic validation, just enough to create a valid deployment object in storage.

func NewCreationHandler

func NewCreationHandler(portsDependency ports.Ports) CreationHandler

NewCreationHandler ...

func (CreationHandler) Handle

Handle ...

type DeletionCleanupFailedHandler

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

DeletionCleanupFailedHandler handles failed deletion cleanup

func NewDeletionCleanupFailedHandler

func NewDeletionCleanupFailedHandler(portsDependency ports.Ports) DeletionCleanupFailedHandler

NewDeletionCleanupFailedHandler ...

func (DeletionCleanupFailedHandler) Handle

Handle ...

type DeletionCleanupSucceededHandler

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

DeletionCleanupSucceededHandler handles success result of deletion cleanup.

func NewDeletionCleanupSucceededHandler

func NewDeletionCleanupSucceededHandler(portsDependency ports.Ports) DeletionCleanupSucceededHandler

NewDeletionCleanupSucceededHandler ...

func (DeletionCleanupSucceededHandler) Handle

Handle ...

type DeletionHandler

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

DeletionHandler handles deletion of deployment. Deployment with existing run(s) and has provisioned resource(s) (determined by the deployment state view) will have its resource cleaned up. The cleanup process is async, and not the responsibility of this microservice. Note that deployment entity is not permanently removed when deletion succeeds, but simply changed its current status to 'deleted'.

func NewDeletionHandler

func NewDeletionHandler(portsDependency ports.Ports) DeletionHandler

NewDeletionHandler ...

func (DeletionHandler) Handle

Handle ...

type EventHandlers

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

EventHandlers implements ports.EventHandlers, this aggregates all event handlers

func NewEventHandlers

func NewEventHandlers(portsDependency ports.Ports) EventHandlers

NewEventHandlers ...

func (EventHandlers) DeploymentCreateRunRequested

func (h EventHandlers) DeploymentCreateRunRequested(request service.DeploymentCreateRunRequest, sink ports.OutgoingEventSink)

DeploymentCreateRunRequested ...

func (EventHandlers) DeploymentCreationRequested

func (h EventHandlers) DeploymentCreationRequested(request service.DeploymentCreationRequest, sink ports.OutgoingEventSink)

DeploymentCreationRequested ...

func (EventHandlers) DeploymentDeletionRequested

func (h EventHandlers) DeploymentDeletionRequested(request service.DeploymentDeletionRequest, sink ports.OutgoingEventSink)

DeploymentDeletionRequested ...

func (EventHandlers) DeploymentUpdateRequested

func (h EventHandlers) DeploymentUpdateRequested(request service.DeploymentUpdateRequest, sink ports.OutgoingEventSink)

DeploymentUpdateRequested ...

func (EventHandlers) EventDeploymentDeletionCleanupFailed

func (h EventHandlers) EventDeploymentDeletionCleanupFailed(result deploymentevents.DeploymentDeletionCleanupResult, sink ports.OutgoingEventSink)

EventDeploymentDeletionCleanupFailed ...

func (EventHandlers) EventDeploymentDeletionCleanupSucceeded

func (h EventHandlers) EventDeploymentDeletionCleanupSucceeded(result deploymentevents.DeploymentDeletionCleanupResult, sink ports.OutgoingEventSink)

EventDeploymentDeletionCleanupSucceeded ...

func (EventHandlers) EventRunExecutionFailed

func (h EventHandlers) EventRunExecutionFailed(failed deploymentevents.RunExecutionFailed, sink ports.OutgoingEventSink)

EventRunExecutionFailed ...

func (EventHandlers) EventRunExecutionStarted

func (h EventHandlers) EventRunExecutionStarted(result deploymentevents.RunPreflightResult, sink ports.OutgoingEventSink)

EventRunExecutionStarted ...

func (EventHandlers) EventRunExecutionSucceeded

func (h EventHandlers) EventRunExecutionSucceeded(succeeded deploymentevents.RunExecutionSucceeded, sink ports.OutgoingEventSink)

EventRunExecutionSucceeded ...

func (EventHandlers) EventRunPreflightFailed

func (h EventHandlers) EventRunPreflightFailed(result deploymentevents.RunPreflightResult, sink ports.OutgoingEventSink)

EventRunPreflightFailed ...

func (EventHandlers) EventRunPreflightStartFailed

func (h EventHandlers) EventRunPreflightStartFailed(failed deploymentevents.RunPreflightStartFailed, sink ports.OutgoingEventSink)

EventRunPreflightStartFailed ...

func (EventHandlers) EventRunPreflightStarted

func (h EventHandlers) EventRunPreflightStarted(started deploymentevents.RunPreflightStarted, sink ports.OutgoingEventSink)

EventRunPreflightStarted ...

type ExecutionFailedHandler

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

ExecutionFailedHandler handles when execution stage of the run failed (either the execution stage finishes with error, or fail to start execution stage).

func NewExecutionFailedHandler

func NewExecutionFailedHandler(portsDependency ports.Ports) ExecutionFailedHandler

NewExecutionFailedHandler ...

func (ExecutionFailedHandler) Handle

Handle ...

type ExecutionStartedHandler

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

ExecutionStartedHandler handles when then execution stage has started

func NewExecutionStartedHandler

func NewExecutionStartedHandler(portsDependency ports.Ports) ExecutionStartedHandler

NewExecutionStartedHandler ...

func (ExecutionStartedHandler) Handle

Handle ...

type ExecutionSucceededHandler

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

ExecutionSucceededHandler handles when execution stage of the run succeeded. Thus, the run has finished successfully

func NewExecutionSucceededHandler

func NewExecutionSucceededHandler(portsDependency ports.Ports) ExecutionSucceededHandler

NewExecutionSucceededHandler ...

func (ExecutionSucceededHandler) Handle

Handle ...

type PreflightFailedHandler

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

PreflightFailedHandler handles when the preflight stage of the run failed.

func NewPreflightFailedHandler

func NewPreflightFailedHandler(portsDependency ports.Ports) PreflightFailedHandler

NewPreflightFailedHandler ...

func (PreflightFailedHandler) Handle

Handle ...

type RunCreationHandler

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

RunCreationHandler handles creation of deployment run This handler only performs barebone validation on the request, just enough to warrant the creation of an entity in the storage.

func NewRunCreationHandler

func NewRunCreationHandler(portsDependency ports.Ports) RunCreationHandler

NewRunCreationHandler ...

func (RunCreationHandler) Handle

Handle ...

type RunStartFailedHandler

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

RunStartFailedHandler handles when run failed to start, thus run creation failed.

func NewRunStartFailedHandler

func NewRunStartFailedHandler(portsDependency ports.Ports) RunStartFailedHandler

NewRunStartFailedHandler ...

func (RunStartFailedHandler) Handle

Handle ...

type RunStartedHandler

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

RunStartedHandler handles when run has started successfully, which means run creation has succeeded

func NewRunStartedHandler

func NewRunStartedHandler(portsDependency ports.Ports) RunStartedHandler

NewRunStartedHandler ...

func (RunStartedHandler) Handle

Handle ...

type UpdateHandler

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

UpdateHandler handles updating deployment

func NewUpdateHandler

func NewUpdateHandler(storage ports.DeploymentStorage) UpdateHandler

NewUpdateHandler ...

func (UpdateHandler) Handle

Handle ...

Jump to

Keyboard shortcuts

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