Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func StartResourceCleanup ¶
func StartResourceCleanup(awm ports.ArgoWorkflowMediator, keySrc ports.KeySrc, data ResourceCleanupPrerequisite) (awmProvider awmclient.AWMProvider, wfName string, err error)
StartResourceCleanup creates a workflow that will clean up the resources provisioned by the deployment.
Types ¶
type PrerequisiteGatherer ¶
type PrerequisiteGatherer struct {
// contains filtered or unexported fields
}
PrerequisiteGatherer gathers prerequisite for launching deletion workflow that cleans up resources for deployment.
func NewPrerequisiteGatherer ¶
func NewPrerequisiteGatherer(runStorage ports.TFRunStorage, credMS ports.CredentialMicroservice, metadataSvc ports.DeploymentMetadataService) PrerequisiteGatherer
NewPrerequisiteGatherer ...
func (PrerequisiteGatherer) Gather ¶
func (gatherer PrerequisiteGatherer) Gather(actor types.Actor, deploymentID common.ID) (ResourceCleanupPrerequisite, error)
Gather gathers prerequisite
type ResourceCleanupPrerequisite ¶
type ResourceCleanupPrerequisite struct { //Deployment service.Deployment Actor types.Actor //Template service.Template LastRun types.DeploymentRun CloudCred *service.CredentialModel GitCred *service.CredentialModel }
ResourceCleanupPrerequisite is data that is required for starting the resource cleanup.
type WorkflowHandler ¶
type WorkflowHandler struct {
// contains filtered or unexported fields
}
WorkflowHandler handles result of deletion workflow (workflow that cleanup resource)
func NewWorkflowHandler ¶
func NewWorkflowHandler(dependencies ports.Ports) WorkflowHandler
NewWorkflowHandler ...
func (WorkflowHandler) HandleWorkflowFailure ¶
func (h WorkflowHandler) HandleWorkflowFailure(tid common.TransactionID, event awmclient.WorkflowFailed, workflow types.DeploymentWorkflow, sink ports.OutgoingEventSink)
HandleWorkflowFailure handles failed workflow.
func (WorkflowHandler) HandleWorkflowSuccess ¶
func (h WorkflowHandler) HandleWorkflowSuccess(tid common.TransactionID, event awmclient.WorkflowSucceeded, workflow types.DeploymentWorkflow, sink ports.OutgoingEventSink)
HandleWorkflowSuccess handles success workflow. Success workflow means that the resource has been cleaned up successfully.
Click to show internal directories.
Click to hide internal directories.