integrationpipeline

package
v0.0.0-...-51e066b Latest Latest
Warning

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

Go to latest
Published: May 13, 2024 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetupController

func SetupController(manager ctrl.Manager, log *logr.Logger) error

SetupController creates a new Integration controller and adds it to the Manager.

Types

type Adapter

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

Adapter holds the objects needed to reconcile an integration PipelineRun.

func NewAdapter

func NewAdapter(context context.Context, pipelineRun *tektonv1.PipelineRun, application *applicationapiv1alpha1.Application,
	snapshot *applicationapiv1alpha1.Snapshot, logger h.IntegrationLogger, loader loader.ObjectLoader, client client.Client,
) *Adapter

NewAdapter creates and returns an Adapter instance.

func (*Adapter) EnsureEphemeralEnvironmentsCleanedUp

func (a *Adapter) EnsureEphemeralEnvironmentsCleanedUp() (controller.OperationResult, error)

EnsureEphemeralEnvironmentsCleanedUp will ensure that ephemeral environment(s) associated with the integration PipelineRun are cleaned up.

func (*Adapter) EnsureStatusReportedInSnapshot

func (a *Adapter) EnsureStatusReportedInSnapshot() (controller.OperationResult, error)

EnsureStatusReportedInSnapshot will ensure that status of the integration test pipelines is reported to snapshot to be consumed by user

func (*Adapter) GetIntegrationPipelineRunStatus

func (a *Adapter) GetIntegrationPipelineRunStatus(ctx context.Context, adapterClient client.Client, pipelineRun *tektonv1.PipelineRun) (intgteststat.IntegrationTestStatus, string, error)

GetIntegrationPipelineRunStatus checks the Tekton results for a given PipelineRun and returns status of test.

type AdapterInterface

type AdapterInterface interface {
	EnsureStatusReportedInSnapshot() (controller.OperationResult, error)
	EnsureEphemeralEnvironmentsCleanedUp() (controller.OperationResult, error)
}

AdapterInterface is an interface defining all the operations that should be defined in an Integration adapter.

type Reconciler

type Reconciler struct {
	client.Client
	Log    logr.Logger
	Scheme *runtime.Scheme
}

Reconciler reconciles an integration PipelineRun object

func NewIntegrationReconciler

func NewIntegrationReconciler(client client.Client, logger *logr.Logger, scheme *runtime.Scheme) *Reconciler

NewIntegrationReconciler creates and returns a Reconciler.

func (*Reconciler) Reconcile

func (r *Reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state.

Jump to

Keyboard shortcuts

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