repository

package
v0.7.4 Latest Latest
Warning

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

Go to latest
Published: Nov 6, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type UserDeploymentRequest

type UserDeploymentRequest struct {
	Id                   int                                 `sql:"id,pk"`
	PipelineId           int                                 `sql:"pipeline_id"`
	CiArtifactId         int                                 `sql:"ci_artifact_id"`
	AdditionalOverride   []byte                              `sql:"additional_override"`
	ForceTrigger         bool                                `sql:"force_trigger"`
	ForceSyncDeployment  bool                                `sql:"force_sync_deployment"`
	Strategy             string                              `sql:"strategy"`
	DeploymentWithConfig apiBean.DeploymentConfigurationType `sql:"deployment_with_config"`
	SpecificTriggerWfrId int                                 `sql:"specific_trigger_wfr_id"` // target cd_workflow_runner_id for rollback. Used in rollback deployment cases
	CdWorkflowId         int                                 `sql:"cd_workflow_id"`
	DeploymentType       models.DeploymentType               `sql:"deployment_type"`
	TriggeredAt          time.Time                           `sql:"triggered_at"`
	TriggeredBy          int32                               `sql:"triggered_by"`
	// contains filtered or unexported fields
}

type UserDeploymentRequestRepository

type UserDeploymentRequestRepository interface {
	// transaction util funcs
	sql.TransactionWrapper
	Save(ctx context.Context, tx *pg.Tx, models ...*UserDeploymentRequest) error
	FindById(ctx context.Context, id int) (*UserDeploymentRequestWithAdditionalFields, error)
	GetLatestIdForPipeline(ctx context.Context, deploymentReqId int) (int, error)
	FindByCdWfId(cdWfId int) (*UserDeploymentRequest, error)
	GetAllInCompleteRequests(ctx context.Context) ([]UserDeploymentRequestWithAdditionalFields, error)
	IsLatestForPipelineId(id, pipelineId int) (bool, error)
}

type UserDeploymentRequestRepositoryImpl

type UserDeploymentRequestRepositoryImpl struct {
	*sql.TransactionUtilImpl
	// contains filtered or unexported fields
}

func NewUserDeploymentRequestRepositoryImpl

func NewUserDeploymentRequestRepositoryImpl(dbConnection *pg.DB, transactionUtilImpl *sql.TransactionUtilImpl) *UserDeploymentRequestRepositoryImpl

func (*UserDeploymentRequestRepositoryImpl) FindByCdWfId

func (impl *UserDeploymentRequestRepositoryImpl) FindByCdWfId(cdWfId int) (*UserDeploymentRequest, error)

func (*UserDeploymentRequestRepositoryImpl) FindById

func (*UserDeploymentRequestRepositoryImpl) GetAllInCompleteRequests

func (*UserDeploymentRequestRepositoryImpl) GetLatestIdForPipeline

func (impl *UserDeploymentRequestRepositoryImpl) GetLatestIdForPipeline(ctx context.Context, deploymentReqId int) (int, error)

func (*UserDeploymentRequestRepositoryImpl) IsLatestForPipelineId

func (impl *UserDeploymentRequestRepositoryImpl) IsLatestForPipelineId(id, pipelineId int) (bool, error)

func (*UserDeploymentRequestRepositoryImpl) Save

type UserDeploymentRequestWithAdditionalFields

type UserDeploymentRequestWithAdditionalFields struct {
	UserDeploymentRequest
	CdWorkflowRunnerId int `sql:"cd_workflow_runner_id"`
	PipelineOverrideId int `sql:"pipeline_override_id"`
}

Jump to

Keyboard shortcuts

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