 Documentation
      ¶
      Documentation
      ¶
    
    
  
    
  
    Index ¶
- Constants
- func BuildJobListingResponse(jobContainers []*bean.JobListingContainer, ...) []*bean.JobContainer
- func GetCIPipelineIDs(jobContainers []*bean.JobListingContainer) []int
- func MergeChildMapToParentMap[T comparable, R any](parentMap map[T]R, toMergeMap map[T]R) map[T]R
- type AppBean
- type AppCrudOperationService
- type AppCrudOperationServiceImpl
- func (impl AppCrudOperationServiceImpl) Create(request *bean.AppLabelDto, tx *pg.Tx) (*bean.AppLabelDto, error)
- func (impl AppCrudOperationServiceImpl) FindAll() ([]*bean.AppLabelDto, error)
- func (impl AppCrudOperationServiceImpl) FindById(id int) (*bean.AppLabelDto, error)
- func (impl AppCrudOperationServiceImpl) GetAppLabelsForDeployment(ctx context.Context, appId int, appName, envName string) ([]byte, error)
- func (impl AppCrudOperationServiceImpl) GetAppListByTeamIds(teamIds []int, appType string) ([]*TeamAppBean, error)
- func (impl AppCrudOperationServiceImpl) GetAppMetaInfo(appId int, installedAppId int, envId int) (*bean.AppMetaInfoDto, error)
- func (impl AppCrudOperationServiceImpl) GetAppMetaInfoByAppName(appName string) (*bean.AppMetaInfoDto, error)
- func (impl AppCrudOperationServiceImpl) GetHelmAppMetaInfo(appId string) (*bean.AppMetaInfoDto, error)
- func (impl AppCrudOperationServiceImpl) GetLabelsByAppId(appId int) (map[string]string, error)
- func (impl AppCrudOperationServiceImpl) UpdateApp(request *bean.CreateAppDTO) (*bean.CreateAppDTO, error)
- func (impl AppCrudOperationServiceImpl) UpdateLabelsInApp(request *bean.CreateAppDTO, tx *pg.Tx) (*bean.CreateAppDTO, error)
- func (impl AppCrudOperationServiceImpl) UpdateProjectForApps(request *bean.UpdateProjectBulkAppsRequest) (*bean.UpdateProjectBulkAppsRequest, error)
 
- type AppListingService
- type AppListingServiceImpl
- func (impl AppListingServiceImpl) BuildAppListingResponseV2(fetchAppListingRequest FetchAppListingRequest, ...) ([]*bean.AppContainer, error)
- func (impl AppListingServiceImpl) FetchAllDevtronManagedApps() ([]AppNameTypeIdContainer, error)
- func (impl AppListingServiceImpl) FetchAppDetails(ctx context.Context, appId int, envId int) (bean.AppDetailContainer, error)
- func (impl AppListingServiceImpl) FetchAppStageStatus(appId int, appType int) ([]bean.AppStageStatus, error)
- func (impl AppListingServiceImpl) FetchAppTriggerView(appId int) ([]bean.TriggerView, error)
- func (impl AppListingServiceImpl) FetchAppsByEnvironmentV2(fetchAppListingRequest FetchAppListingRequest, w http.ResponseWriter, ...) ([]*bean.AppEnvironmentContainer, int, error)
- func (impl AppListingServiceImpl) FetchJobs(fetchJobListingRequest FetchAppListingRequest) ([]*bean.JobContainer, error)
- func (impl AppListingServiceImpl) FetchMinDetailOtherEnvironment(appId int) ([]*bean.Environment, error)
- func (impl AppListingServiceImpl) FetchOtherEnvironment(ctx context.Context, appId int) ([]*bean.Environment, error)
- func (impl AppListingServiceImpl) FetchOverviewAppsByEnvironment(envId, limit, offset int) (*OverviewAppsByEnvironmentBean, error)
- func (impl AppListingServiceImpl) FetchOverviewCiPipelines(jobId int) ([]*bean.JobListingContainer, error)
- func (impl AppListingServiceImpl) GetReleaseCount(appId, envId int) (int, error)
- func (impl AppListingServiceImpl) ISLastReleaseStopType(appId, envId int) (bool, error)
- func (impl AppListingServiceImpl) ISLastReleaseStopTypeV2(pipelineIds []int) (map[int]bool, error)
- func (impl AppListingServiceImpl) RedirectToLinkouts(Id int, appId int, envId int, podName string, containerName string) (string, error)
 
- type AppListingViewBuilder
- type AppListingViewBuilderImpl
- type AppNameTypeIdContainer
- type AppService
- type AppServiceConfig
- type AppServiceImpl
- func (impl *AppServiceImpl) BuildCDSuccessPayload(appName string, environmentName string) *client.Payload
- func (impl *AppServiceImpl) BuildPayload(overrideRequest *bean.ValuesOverrideRequest, pipeline *pipelineConfig.Pipeline, ...) *client.Payload
- func (impl *AppServiceImpl) CheckIfPipelineUpdateEventIsValid(argoAppName, gitHash string) (bool, pipelineConfig.Pipeline, pipelineConfig.CdWorkflowRunner, ...)
- func (impl *AppServiceImpl) CheckIfPipelineUpdateEventIsValidForAppStore(gitOpsAppName string, gitHash string) (bool, *repository4.InstalledAppVersionHistory, int, int, error)
- func (impl *AppServiceImpl) ComputeAppstatus(appId, envId int, status health2.HealthStatusCode) (string, error)
- func (impl *AppServiceImpl) CreateGitOpsRepo(app *app.App, userId int32) (gitopsRepoName string, chartGitAttr *commonBean.ChartGitAttribute, err error)
- func (impl *AppServiceImpl) GetActiveCiCdAppsCount() (int, error)
- func (impl *AppServiceImpl) GetCmSecretNew(appId int, envId int, isJob bool, scope resourceQualifiers.Scope) (*bean.ConfigMapJson, *bean.ConfigSecretJson, error)
- func (impl *AppServiceImpl) GetConfigMapAndSecretJson(appId int, envId int, pipelineId int) ([]byte, error)
- func (impl *AppServiceImpl) GetDeployedManifestByPipelineIdAndCDWorkflowId(appId int, envId int, cdWorkflowId int, ctx context.Context) ([]byte, error)
- func (impl *AppServiceImpl) UpdateCdWorkflowRunnerByACDObject(app *v1alpha1.Application, cdWfrId int, updateTimedOutStatus bool) error
- func (impl *AppServiceImpl) UpdateDeploymentStatusAndCheckIsSucceeded(app *v1alpha1.Application, statusTime time.Time, isAppStore bool) (bool, *chartConfig.PipelineOverride, error)
- func (impl *AppServiceImpl) UpdateDeploymentStatusForAppStore(app *v1alpha1.Application, installedVersionHistoryId int) (bool, error)
- func (impl *AppServiceImpl) UpdateDeploymentStatusForGitOpsPipelines(app *v1alpha1.Application, statusTime time.Time, isAppStore bool) (bool, bool, *chartConfig.PipelineOverride, error)
- func (impl *AppServiceImpl) UpdateDeploymentStatusForPipeline(app *v1alpha1.Application, pipelineOverride *chartConfig.PipelineOverride, ...) (bool, error)
- func (impl *AppServiceImpl) UpdateInstalledAppVersionHistoryByACDObject(app *v1alpha1.Application, installedAppVersionHistoryId int, ...) error
- func (impl *AppServiceImpl) UpdatePipelineStatusTimelineForApplicationChanges(app *v1alpha1.Application, runnerHistoryId int, statusTime time.Time, ...) (isTimelineUpdated bool, isTimelineTimedOut bool, ...)
- func (impl *AppServiceImpl) UpdateReleaseStatus(updateStatusRequest *bean.ReleaseStatusUpdateRequest) (bool, error)
- func (impl *AppServiceImpl) WriteCDSuccessEvent(appId int, envId int, override *chartConfig.PipelineOverride)
 
- type CrudOperationServiceConfig
- type DeploymentEvent
- type DeploymentEventHandler
- type DeploymentEventHandlerImpl
- type FetchAppListingRequest
- type OverviewAppsByEnvironmentBean
- type PipelineMaterialInfo
- type ReleaseAttributes
- type ReleaseDataService
- type ReleaseDataServiceImpl
- type TeamAppBean
- type ValuesOverrideResponse
Constants ¶
      View Source
      
  
    const ( ZERO_INSTALLED_APP_ID = 0 ZERO_ENVIRONMENT_ID = 0 )
      View Source
      
  
    const ( APIVersionV1 string = "v1" APIVersionV2 string = "v2" )
      View Source
      
  
    const ( Production = "Production" NonProduction = "Non-Production" )
      View Source
      
  
    const AcdInvalidAppErr = "invalid acd app name and env"
    
      View Source
      
  const LabelMatchingRegex = "^(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])?$"
    LabelMatchingRegex is the official k8s label matching regex, pls refer https://github.com/kubernetes/apimachinery/blob/bfd2aff97e594f6aad77acbe2cbbe190acc93cbc/pkg/util/validation/validation.go#L167
      View Source
      
  
const NotDeployed = "Not Deployed"
    Variables ¶
This section is empty.
Functions ¶
func BuildJobListingResponse ¶ added in v0.6.15
func BuildJobListingResponse(jobContainers []*bean.JobListingContainer, JobsLastSucceededOnTime []*bean.CiPipelineLastSucceededTime) []*bean.JobContainer
func GetCIPipelineIDs ¶ added in v0.6.15
func GetCIPipelineIDs(jobContainers []*bean.JobListingContainer) []int
func MergeChildMapToParentMap ¶ added in v0.7.0
func MergeChildMapToParentMap[T comparable, R any](parentMap map[T]R, toMergeMap map[T]R) map[T]R
MergeChildMapToParentMap merges child map of generic type map into parent map of generic type and returns merged mapping, if parentMap is nil then nil is returned.
Types ¶
type AppCrudOperationService ¶ added in v0.6.0
type AppCrudOperationService interface {
	Create(request *bean.AppLabelDto, tx *pg.Tx) (*bean.AppLabelDto, error)
	FindById(id int) (*bean.AppLabelDto, error)
	FindAll() ([]*bean.AppLabelDto, error)
	GetAppMetaInfo(appId int, installedAppId int, envId int) (*bean.AppMetaInfoDto, error)
	GetHelmAppMetaInfo(appId string) (*bean.AppMetaInfoDto, error)
	GetAppLabelsForDeployment(ctx context.Context, appId int, appName, envName string) ([]byte, error)
	GetLabelsByAppId(appId int) (map[string]string, error)
	UpdateApp(request *bean.CreateAppDTO) (*bean.CreateAppDTO, error)
	UpdateProjectForApps(request *bean.UpdateProjectBulkAppsRequest) (*bean.UpdateProjectBulkAppsRequest, error)
	GetAppMetaInfoByAppName(appName string) (*bean.AppMetaInfoDto, error)
	GetAppListByTeamIds(teamIds []int, appType string) ([]*TeamAppBean, error)
}
    type AppCrudOperationServiceImpl ¶ added in v0.6.0
type AppCrudOperationServiceImpl struct {
	// contains filtered or unexported fields
}
    func NewAppCrudOperationServiceImpl ¶ added in v0.6.0
func NewAppCrudOperationServiceImpl(appLabelRepository pipelineConfig.AppLabelRepository, logger *zap.SugaredLogger, appRepository appRepository.AppRepository, userRepository repository.UserRepository, installedAppRepository repository2.InstalledAppRepository, genericNoteService genericNotes.GenericNoteService, gitMaterialRepository pipelineConfig.MaterialRepository, installedAppDbService EAMode.InstalledAppDBService, crudOperationServiceConfig *CrudOperationServiceConfig, dbMigration dbMigration.DbMigration) *AppCrudOperationServiceImpl
func (AppCrudOperationServiceImpl) Create ¶ added in v0.6.0
func (impl AppCrudOperationServiceImpl) Create(request *bean.AppLabelDto, tx *pg.Tx) (*bean.AppLabelDto, error)
func (AppCrudOperationServiceImpl) FindAll ¶ added in v0.6.0
func (impl AppCrudOperationServiceImpl) FindAll() ([]*bean.AppLabelDto, error)
func (AppCrudOperationServiceImpl) FindById ¶ added in v0.6.0
func (impl AppCrudOperationServiceImpl) FindById(id int) (*bean.AppLabelDto, error)
func (AppCrudOperationServiceImpl) GetAppLabelsForDeployment ¶ added in v0.7.0
func (AppCrudOperationServiceImpl) GetAppListByTeamIds ¶ added in v0.6.11
func (impl AppCrudOperationServiceImpl) GetAppListByTeamIds(teamIds []int, appType string) ([]*TeamAppBean, error)
func (AppCrudOperationServiceImpl) GetAppMetaInfo ¶ added in v0.6.0
func (impl AppCrudOperationServiceImpl) GetAppMetaInfo(appId int, installedAppId int, envId int) (*bean.AppMetaInfoDto, error)
GetAppMetaInfo here envId is for installedApp
func (AppCrudOperationServiceImpl) GetAppMetaInfoByAppName ¶ added in v0.6.6
func (impl AppCrudOperationServiceImpl) GetAppMetaInfoByAppName(appName string) (*bean.AppMetaInfoDto, error)
func (AppCrudOperationServiceImpl) GetHelmAppMetaInfo ¶ added in v0.6.11
func (impl AppCrudOperationServiceImpl) GetHelmAppMetaInfo(appId string) (*bean.AppMetaInfoDto, error)
func (AppCrudOperationServiceImpl) GetLabelsByAppId ¶ added in v0.6.4
func (impl AppCrudOperationServiceImpl) GetLabelsByAppId(appId int) (map[string]string, error)
func (AppCrudOperationServiceImpl) UpdateApp ¶ added in v0.6.0
func (impl AppCrudOperationServiceImpl) UpdateApp(request *bean.CreateAppDTO) (*bean.CreateAppDTO, error)
func (AppCrudOperationServiceImpl) UpdateLabelsInApp ¶ added in v0.6.0
func (impl AppCrudOperationServiceImpl) UpdateLabelsInApp(request *bean.CreateAppDTO, tx *pg.Tx) (*bean.CreateAppDTO, error)
func (AppCrudOperationServiceImpl) UpdateProjectForApps ¶ added in v0.6.0
func (impl AppCrudOperationServiceImpl) UpdateProjectForApps(request *bean.UpdateProjectBulkAppsRequest) (*bean.UpdateProjectBulkAppsRequest, error)
type AppListingService ¶
type AppListingService interface {
	FetchJobs(fetchJobListingRequest FetchAppListingRequest) ([]*bean.JobContainer, error)
	FetchOverviewCiPipelines(jobId int) ([]*bean.JobListingContainer, error)
	BuildAppListingResponseV2(fetchAppListingRequest FetchAppListingRequest, envContainers []*bean.AppEnvironmentContainer) ([]*bean.AppContainer, error)
	FetchAllDevtronManagedApps() ([]AppNameTypeIdContainer, error)
	FetchAppDetails(ctx context.Context, appId int, envId int) (bean.AppDetailContainer, error)
	FetchAppTriggerView(appId int) ([]bean.TriggerView, error)
	FetchAppStageStatus(appId int, appType int) ([]bean.AppStageStatus, error)
	FetchOtherEnvironment(ctx context.Context, appId int) ([]*bean.Environment, error)
	FetchMinDetailOtherEnvironment(appId int) ([]*bean.Environment, error)
	RedirectToLinkouts(Id int, appId int, envId int, podName string, containerName string) (string, error)
	ISLastReleaseStopType(appId, envId int) (bool, error)
	ISLastReleaseStopTypeV2(pipelineIds []int) (map[int]bool, error)
	GetReleaseCount(appId, envId int) (int, error)
	FetchAppsByEnvironmentV2(fetchAppListingRequest FetchAppListingRequest, w http.ResponseWriter, r *http.Request, token string) ([]*bean.AppEnvironmentContainer, int, error)
	FetchOverviewAppsByEnvironment(envId, limit, offset int) (*OverviewAppsByEnvironmentBean, error)
}
    type AppListingServiceImpl ¶
type AppListingServiceImpl struct {
	Logger *zap.SugaredLogger
	// contains filtered or unexported fields
}
    func NewAppListingServiceImpl ¶
func NewAppListingServiceImpl(Logger *zap.SugaredLogger, appListingRepository repository.AppListingRepository, application application2.ServiceClient, appRepository app.AppRepository, appListingViewBuilder AppListingViewBuilder, pipelineRepository pipelineConfig.PipelineRepository, linkoutsRepository repository.LinkoutsRepository, cdWorkflowRepository pipelineConfig.CdWorkflowRepository, pipelineOverrideRepository chartConfig.PipelineOverrideRepository, environmentRepository repository2.EnvironmentRepository, argoUserService argo.ArgoUserService, envOverrideRepository chartConfig.EnvConfigOverrideRepository, chartRepository chartRepoRepository.ChartRepository, ciPipelineRepository pipelineConfig.CiPipelineRepository, dockerRegistryIpsConfigService dockerRegistry.DockerRegistryIpsConfigService, userRepository userrepository.UserRepository, deployedAppMetricsService deployedAppMetrics.DeployedAppMetricsService, ciArtifactRepository repository.CiArtifactRepository) *AppListingServiceImpl
func (AppListingServiceImpl) BuildAppListingResponseV2 ¶ added in v0.6.17
func (impl AppListingServiceImpl) BuildAppListingResponseV2(fetchAppListingRequest FetchAppListingRequest, envContainers []*bean.AppEnvironmentContainer) ([]*bean.AppContainer, error)
func (AppListingServiceImpl) FetchAllDevtronManagedApps ¶ added in v0.6.9
func (impl AppListingServiceImpl) FetchAllDevtronManagedApps() ([]AppNameTypeIdContainer, error)
func (AppListingServiceImpl) FetchAppDetails ¶
func (impl AppListingServiceImpl) FetchAppDetails(ctx context.Context, appId int, envId int) (bean.AppDetailContainer, error)
func (AppListingServiceImpl) FetchAppStageStatus ¶
func (impl AppListingServiceImpl) FetchAppStageStatus(appId int, appType int) ([]bean.AppStageStatus, error)
func (AppListingServiceImpl) FetchAppTriggerView ¶
func (impl AppListingServiceImpl) FetchAppTriggerView(appId int) ([]bean.TriggerView, error)
func (AppListingServiceImpl) FetchAppsByEnvironmentV2 ¶ added in v0.6.17
func (impl AppListingServiceImpl) FetchAppsByEnvironmentV2(fetchAppListingRequest FetchAppListingRequest, w http.ResponseWriter, r *http.Request, token string) ([]*bean.AppEnvironmentContainer, int, error)
func (AppListingServiceImpl) FetchJobs ¶ added in v0.6.15
func (impl AppListingServiceImpl) FetchJobs(fetchJobListingRequest FetchAppListingRequest) ([]*bean.JobContainer, error)
func (AppListingServiceImpl) FetchMinDetailOtherEnvironment ¶ added in v0.6.17
func (impl AppListingServiceImpl) FetchMinDetailOtherEnvironment(appId int) ([]*bean.Environment, error)
func (AppListingServiceImpl) FetchOtherEnvironment ¶
func (impl AppListingServiceImpl) FetchOtherEnvironment(ctx context.Context, appId int) ([]*bean.Environment, error)
func (AppListingServiceImpl) FetchOverviewAppsByEnvironment ¶ added in v0.6.17
func (impl AppListingServiceImpl) FetchOverviewAppsByEnvironment(envId, limit, offset int) (*OverviewAppsByEnvironmentBean, error)
func (AppListingServiceImpl) FetchOverviewCiPipelines ¶ added in v0.6.15
func (impl AppListingServiceImpl) FetchOverviewCiPipelines(jobId int) ([]*bean.JobListingContainer, error)
func (AppListingServiceImpl) GetReleaseCount ¶
func (impl AppListingServiceImpl) GetReleaseCount(appId, envId int) (int, error)
func (AppListingServiceImpl) ISLastReleaseStopType ¶
func (impl AppListingServiceImpl) ISLastReleaseStopType(appId, envId int) (bool, error)
func (AppListingServiceImpl) ISLastReleaseStopTypeV2 ¶
func (impl AppListingServiceImpl) ISLastReleaseStopTypeV2(pipelineIds []int) (map[int]bool, error)
func (AppListingServiceImpl) RedirectToLinkouts ¶
type AppListingViewBuilder ¶
type AppListingViewBuilder interface {
	BuildView(fetchAppListingRequest FetchAppListingRequest, appEnvMap map[string][]*bean.AppEnvironmentContainer) ([]*bean.AppContainer, error)
}
    type AppListingViewBuilderImpl ¶
type AppListingViewBuilderImpl struct {
	Logger *zap.SugaredLogger
}
    func NewAppListingViewBuilderImpl ¶
func NewAppListingViewBuilderImpl(Logger *zap.SugaredLogger) *AppListingViewBuilderImpl
func (*AppListingViewBuilderImpl) BuildView ¶
func (impl *AppListingViewBuilderImpl) BuildView(fetchAppListingRequest FetchAppListingRequest, appEnvMap map[string][]*bean.AppEnvironmentContainer) ([]*bean.AppContainer, error)
type AppNameTypeIdContainer ¶ added in v0.6.9
type AppService ¶
type AppService interface {
	UpdateReleaseStatus(request *bean.ReleaseStatusUpdateRequest) (bool, error)
	UpdateDeploymentStatusAndCheckIsSucceeded(app *v1alpha1.Application, statusTime time.Time, isAppStore bool) (bool, *chartConfig.PipelineOverride, error)
	GetConfigMapAndSecretJson(appId int, envId int, pipelineId int) ([]byte, error)
	UpdateCdWorkflowRunnerByACDObject(app *v1alpha1.Application, cdWfrId int, updateTimedOutStatus bool) error
	GetCmSecretNew(appId int, envId int, isJob bool, scope resourceQualifiers.Scope) (*bean.ConfigMapJson, *bean.ConfigSecretJson, error)
	UpdateDeploymentStatusForGitOpsPipelines(app *v1alpha1.Application, statusTime time.Time, isAppStore bool) (bool, bool, *chartConfig.PipelineOverride, error)
	WriteCDSuccessEvent(appId int, envId int, override *chartConfig.PipelineOverride)
	CreateGitOpsRepo(app *app.App, userId int32) (gitopsRepoName string, chartGitAttr *commonBean.ChartGitAttribute, err error)
	GetDeployedManifestByPipelineIdAndCDWorkflowId(appId int, envId int, cdWorkflowId int, ctx context.Context) ([]byte, error)
	// TODO: move inside reader service
	GetActiveCiCdAppsCount() (int, error)
	ComputeAppstatus(appId, envId int, status health2.HealthStatusCode) (string, error)
}
    type AppServiceConfig ¶ added in v0.6.14
type AppServiceConfig struct {
	CdPipelineStatusCronTime                   string `env:"CD_PIPELINE_STATUS_CRON_TIME" envDefault:"*/2 * * * *"`
	CdHelmPipelineStatusCronTime               string `env:"CD_HELM_PIPELINE_STATUS_CRON_TIME" envDefault:"*/2 * * * *"`
	CdPipelineStatusTimeoutDuration            string `env:"CD_PIPELINE_STATUS_TIMEOUT_DURATION" envDefault:"20"`                   // in minutes
	PipelineDegradedTime                       string `env:"PIPELINE_DEGRADED_TIME" envDefault:"10"`                                // in minutes
	GetPipelineDeployedWithinHours             int    `env:"DEPLOY_STATUS_CRON_GET_PIPELINE_DEPLOYED_WITHIN_HOURS" envDefault:"12"` // in hours
	HelmPipelineStatusCheckEligibleTime        string `env:"HELM_PIPELINE_STATUS_CHECK_ELIGIBLE_TIME" envDefault:"120"`             // in seconds
	ExposeCDMetrics                            bool   `env:"EXPOSE_CD_METRICS" envDefault:"false"`
	DevtronChartHelmInstallRequestTimeout      int    `env:"DEVTRON_CHART_INSTALL_REQUEST_TIMEOUT" envDefault:"6"`         // in minutes
	DevtronChartArgoCdInstallRequestTimeout    int    `env:"DEVTRON_CHART_ARGO_CD_INSTALL_REQUEST_TIMEOUT" envDefault:"1"` // in minutes
	ArgoCdManualSyncCronPipelineDeployedBefore int    `env:"ARGO_APP_MANUAL_SYNC_TIME" envDefault:"3"`                     // in minutes
}
    func GetAppServiceConfig ¶ added in v0.6.14
func GetAppServiceConfig() (*AppServiceConfig, error)
type AppServiceImpl ¶
type AppServiceImpl struct {
	// contains filtered or unexported fields
}
    func NewAppService ¶
func NewAppService( environmentConfigRepository chartConfig.EnvConfigOverrideRepository, pipelineOverrideRepository chartConfig.PipelineOverrideRepository, mergeUtil *MergeUtil, logger *zap.SugaredLogger, pipelineRepository pipelineConfig.PipelineRepository, eventClient client.EventClient, eventFactory client.EventFactory, acdClient application.ServiceClient, appRepository app.AppRepository, configMapRepository chartConfig.ConfigMapRepository, chartRepository chartRepoRepository.ChartRepository, cdWorkflowRepository pipelineConfig.CdWorkflowRepository, commonService commonService.CommonService, chartTemplateService ChartTemplateService, argoUserService argo.ArgoUserService, cdPipelineStatusTimelineRepo pipelineConfig.PipelineStatusTimelineRepository, pipelineStatusTimelineResourcesService status2.PipelineStatusTimelineResourcesService, pipelineStatusSyncDetailService status2.PipelineStatusSyncDetailService, pipelineStatusTimelineService status2.PipelineStatusTimelineService, appStatusConfig *AppServiceConfig, appStatusService appStatus.AppStatusService, installedAppRepository repository4.InstalledAppRepository, installedAppVersionHistoryRepository repository4.InstalledAppVersionHistoryRepository, scopedVariableManager variables.ScopedVariableCMCSManager, acdConfig *argocdServer.ACDConfig, gitOpsConfigReadService config.GitOpsConfigReadService, gitOperationService git.GitOperationService, deploymentTemplateService deploymentTemplate.DeploymentTemplateService, appListingService AppListingService, deploymentConfigService common2.DeploymentConfigService) *AppServiceImpl
func (*AppServiceImpl) BuildCDSuccessPayload ¶
func (impl *AppServiceImpl) BuildCDSuccessPayload(appName string, environmentName string) *client.Payload
func (*AppServiceImpl) BuildPayload ¶
func (impl *AppServiceImpl) BuildPayload(overrideRequest *bean.ValuesOverrideRequest, pipeline *pipelineConfig.Pipeline, envOverride *chartConfig.EnvConfigOverride, materialInfo map[string]string, artifact *repository.CiArtifact) *client.Payload
func (*AppServiceImpl) CheckIfPipelineUpdateEventIsValid ¶ added in v0.6.11
func (impl *AppServiceImpl) CheckIfPipelineUpdateEventIsValid(argoAppName, gitHash string) (bool, pipelineConfig.Pipeline, pipelineConfig.CdWorkflowRunner, *chartConfig.PipelineOverride, error)
func (*AppServiceImpl) CheckIfPipelineUpdateEventIsValidForAppStore ¶ added in v0.6.17
func (impl *AppServiceImpl) CheckIfPipelineUpdateEventIsValidForAppStore(gitOpsAppName string, gitHash string) (bool, *repository4.InstalledAppVersionHistory, int, int, error)
func (*AppServiceImpl) ComputeAppstatus ¶ added in v0.7.1
func (impl *AppServiceImpl) ComputeAppstatus(appId, envId int, status health2.HealthStatusCode) (string, error)
func (*AppServiceImpl) CreateGitOpsRepo ¶ added in v0.7.1
func (impl *AppServiceImpl) CreateGitOpsRepo(app *app.App, userId int32) (gitopsRepoName string, chartGitAttr *commonBean.ChartGitAttribute, err error)
func (*AppServiceImpl) GetActiveCiCdAppsCount ¶ added in v0.6.29
func (impl *AppServiceImpl) GetActiveCiCdAppsCount() (int, error)
func (*AppServiceImpl) GetCmSecretNew ¶
func (impl *AppServiceImpl) GetCmSecretNew(appId int, envId int, isJob bool, scope resourceQualifiers.Scope) (*bean.ConfigMapJson, *bean.ConfigSecretJson, error)
FIXME tmp workaround
func (*AppServiceImpl) GetConfigMapAndSecretJson ¶
func (impl *AppServiceImpl) GetConfigMapAndSecretJson(appId int, envId int, pipelineId int) ([]byte, error)
depricated TODO remove this method
func (*AppServiceImpl) GetDeployedManifestByPipelineIdAndCDWorkflowId ¶ added in v0.6.17
func (*AppServiceImpl) UpdateCdWorkflowRunnerByACDObject ¶
func (impl *AppServiceImpl) UpdateCdWorkflowRunnerByACDObject(app *v1alpha1.Application, cdWfrId int, updateTimedOutStatus bool) error
func (*AppServiceImpl) UpdateDeploymentStatusAndCheckIsSucceeded ¶ added in v0.6.11
func (impl *AppServiceImpl) UpdateDeploymentStatusAndCheckIsSucceeded(app *v1alpha1.Application, statusTime time.Time, isAppStore bool) (bool, *chartConfig.PipelineOverride, error)
func (*AppServiceImpl) UpdateDeploymentStatusForAppStore ¶ added in v0.6.17
func (impl *AppServiceImpl) UpdateDeploymentStatusForAppStore(app *v1alpha1.Application, installedVersionHistoryId int) (bool, error)
func (*AppServiceImpl) UpdateDeploymentStatusForGitOpsPipelines ¶ added in v0.6.17
func (impl *AppServiceImpl) UpdateDeploymentStatusForGitOpsPipelines(app *v1alpha1.Application, statusTime time.Time, isAppStore bool) (bool, bool, *chartConfig.PipelineOverride, error)
func (*AppServiceImpl) UpdateDeploymentStatusForPipeline ¶ added in v0.6.11
func (impl *AppServiceImpl) UpdateDeploymentStatusForPipeline(app *v1alpha1.Application, pipelineOverride *chartConfig.PipelineOverride, cdWfrId int) (bool, error)
func (*AppServiceImpl) UpdateInstalledAppVersionHistoryByACDObject ¶ added in v0.6.17
func (impl *AppServiceImpl) UpdateInstalledAppVersionHistoryByACDObject(app *v1alpha1.Application, installedAppVersionHistoryId int, updateTimedOutStatus bool) error
func (*AppServiceImpl) UpdatePipelineStatusTimelineForApplicationChanges ¶ added in v0.4.28
func (impl *AppServiceImpl) UpdatePipelineStatusTimelineForApplicationChanges(app *v1alpha1.Application, runnerHistoryId int, statusTime time.Time, triggeredAt time.Time, statusTimeoutDuration int, lastStatusTime time.Time, reconciledAt *metav1.Time, isAppStore bool) (isTimelineUpdated bool, isTimelineTimedOut bool, kubectlApplySyncedTimeline *pipelineConfig.PipelineStatusTimeline, err error)
func (*AppServiceImpl) UpdateReleaseStatus ¶
func (impl *AppServiceImpl) UpdateReleaseStatus(updateStatusRequest *bean.ReleaseStatusUpdateRequest) (bool, error)
func (*AppServiceImpl) WriteCDSuccessEvent ¶
func (impl *AppServiceImpl) WriteCDSuccessEvent(appId int, envId int, override *chartConfig.PipelineOverride)
type CrudOperationServiceConfig ¶ added in v0.7.1
type CrudOperationServiceConfig struct {
	PropagateExtraLabels bool `env:"PROPAGATE_EXTRA_LABELS" envDefault:"false"`
}
    func GetCrudOperationServiceConfig ¶ added in v0.7.1
func GetCrudOperationServiceConfig() (*CrudOperationServiceConfig, error)
type DeploymentEvent ¶
type DeploymentEventHandler ¶ added in v0.6.4
type DeploymentEventHandler interface {
	WriteCDDeploymentEvent(pipelineId, appId, envId int, eventType util.EventType)
}
    DeploymentEventHandler is not being used, TODO: find reason for creation and then remove
type DeploymentEventHandlerImpl ¶ added in v0.6.4
type DeploymentEventHandlerImpl struct {
	// contains filtered or unexported fields
}
    func NewDeploymentEventHandlerImpl ¶ added in v0.6.4
func NewDeploymentEventHandlerImpl(logger *zap.SugaredLogger, appListingService AppListingService, eventClient client.EventClient, eventFactory client.EventFactory) *DeploymentEventHandlerImpl
func (*DeploymentEventHandlerImpl) BuildPayload ¶ added in v0.6.4
func (*DeploymentEventHandlerImpl) WriteCDDeploymentEvent ¶ added in v0.6.4
func (impl *DeploymentEventHandlerImpl) WriteCDDeploymentEvent(pipelineId, appId, envId int, eventType util.EventType)
type FetchAppListingRequest ¶
type FetchAppListingRequest struct {
	Environments      []int            `json:"environments"`
	Statuses          []string         `json:"statuses"`
	Teams             []int            `json:"teams"`
	AppNameSearch     string           `json:"appNameSearch"`
	SortOrder         helper.SortOrder `json:"sortOrder"`
	SortBy            helper.SortBy    `json:"sortBy"`
	Offset            int              `json:"offset"`
	Size              int              `json:"size"`
	DeploymentGroupId int              `json:"deploymentGroupId"`
	Namespaces        []string         `json:"namespaces"` // {clusterId}_{namespace}
	AppStatuses       []string         `json:"appStatuses"`
	AppIds            []int            `json:"-"` // internal use only
}
    func (FetchAppListingRequest) GetNamespaceClusterMapping ¶ added in v0.3.14
func (req FetchAppListingRequest) GetNamespaceClusterMapping() (namespaceClusterPair []*repository2.ClusterNamespacePair, clusterIds []int, err error)
type OverviewAppsByEnvironmentBean ¶ added in v0.6.17
type OverviewAppsByEnvironmentBean struct {
	EnvironmentId   int                             `json:"environmentId"`
	EnvironmentName string                          `json:"environmentName"`
	Namespace       string                          `json:"namespace"`
	ClusterName     string                          `json:"clusterName"`
	ClusterId       int                             `json:"clusterId"`
	Type            string                          `json:"environmentType"`
	Description     string                          `json:"description"`
	AppCount        int                             `json:"appCount"`
	Apps            []*bean.AppEnvironmentContainer `json:"apps"`
	CreatedOn       string                          `json:"createdOn"`
	CreatedBy       string                          `json:"createdBy"`
}
    type PipelineMaterialInfo ¶
type ReleaseAttributes ¶
type ReleaseAttributes struct {
	Name           string
	Tag            string
	PipelineName   string
	ReleaseVersion string
	DeploymentType string
	App            string // App here corresponds to appId
	Env            string // Env here corresponds to envId
	AppMetrics     *bool
}
    func NewReleaseAttributes ¶ added in v0.7.1
func NewReleaseAttributes(image, imageTag, pipelineName, deploymentStrategy string, appId, envId, pipelineReleaseCounter int, appMetricsEnabled *bool) *ReleaseAttributes
func (*ReleaseAttributes) RenderJson ¶ added in v0.7.1
func (releaseAttributes *ReleaseAttributes) RenderJson(jsonTemplate string) (string, error)
type ReleaseDataService ¶
type ReleaseDataService interface {
	TriggerEventForAllRelease(appId, environmentId int) error
	GetDeploymentMetrics(request *lens.MetricRequest) (resBody []byte, resCode *lens.StatusCode, err error)
}
    type ReleaseDataServiceImpl ¶
type ReleaseDataServiceImpl struct {
	// contains filtered or unexported fields
}
    func NewReleaseDataServiceImpl ¶
func NewReleaseDataServiceImpl( pipelineOverrideRepository chartConfig.PipelineOverrideRepository, logger *zap.SugaredLogger, ciPipelineMaterialRepository pipelineConfig.CiPipelineMaterialRepository, eventClient client.EventClient, lensClient lens.LensClient) *ReleaseDataServiceImpl
func (*ReleaseDataServiceImpl) GetDeploymentMetrics ¶
func (impl *ReleaseDataServiceImpl) GetDeploymentMetrics(request *lens.MetricRequest) (resBody []byte, resCode *lens.StatusCode, err error)
func (*ReleaseDataServiceImpl) TriggerEventForAllRelease ¶
func (impl *ReleaseDataServiceImpl) TriggerEventForAllRelease(appId, environmentId int) error
type TeamAppBean ¶ added in v0.6.11
type ValuesOverrideResponse ¶ added in v0.6.17
type ValuesOverrideResponse struct {
	MergedValues        string
	ReleaseOverrideJSON string
	EnvOverride         *chartConfig.EnvConfigOverride
	PipelineStrategy    *chartConfig.PipelineStrategy
	PipelineOverride    *chartConfig.PipelineOverride
	Artifact            *repository.CiArtifact
	Pipeline            *pipelineConfig.Pipeline
	DeploymentConfig    *bean2.DeploymentConfig
}
    
       Source Files
      ¶
      Source Files
      ¶
    
   Click to show internal directories. 
   Click to hide internal directories.