chartGroup

package
v0.6.28 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const AppNameAlreadyExistsError = "A chart with this name already exist"

Variables

This section is empty.

Functions

This section is empty.

Types

type ChartGroupBean

type ChartGroupBean struct {
	Name               string                 `json:"name,omitempty" validate:"name-component,max=200,min=5"`
	Description        string                 `json:"description,omitempty"`
	Id                 int                    `json:"id,omitempty"`
	ChartGroupEntries  []*ChartGroupEntryBean `json:"chartGroupEntries,omitempty"`
	InstalledChartData []*InstalledChartData  `json:"installedChartData,omitempty"`
	UserId             int32                  `json:"-"`
}

type ChartGroupEntryBean

type ChartGroupEntryBean struct {
	Id                           int            `json:"id,omitempty"`
	AppStoreValuesVersionId      int            `json:"appStoreValuesVersionId,omitempty"` //AppStoreVersionValuesId
	AppStoreValuesVersionName    string         `json:"appStoreValuesVersionName,omitempty"`
	AppStoreValuesChartVersion   string         `json:"appStoreValuesChartVersion,omitempty"`   //chart version corresponding to values
	AppStoreApplicationVersionId int            `json:"appStoreApplicationVersionId,omitempty"` //AppStoreApplicationVersionId
	ChartMetaData                *ChartMetaData `json:"chartMetaData,omitempty"`
	ReferenceType                string         `json:"referenceType, omitempty"`
}

type ChartGroupInstallAppRes

type ChartGroupInstallAppRes struct {
}

type ChartGroupInstallChartRequest

type ChartGroupInstallChartRequest struct {
	AppName                 string `json:"appName,omitempty"  validate:"name-component,max=100" `
	EnvironmentId           int    `json:"environmentId,omitempty" validate:"required,number" `
	AppStoreVersion         int    `json:"appStoreVersion,omitempty,notnull" validate:"required,number" `
	ValuesOverrideYaml      string `json:"valuesOverrideYaml,omitempty"` //optional
	ReferenceValueId        int    `json:"referenceValueId, omitempty" validate:"required,number"`
	ReferenceValueKind      string `json:"referenceValueKind, omitempty" validate:"oneof=DEFAULT TEMPLATE DEPLOYED"`
	ChartGroupEntryId       int    `json:"chartGroupEntryId"` //optional
	DefaultClusterComponent bool   `json:"-"`
}

type ChartGroupInstallRequest

type ChartGroupInstallRequest struct {
	ProjectId                     int                              `json:"projectId"  validate:"required,number"`
	ChartGroupInstallChartRequest []*ChartGroupInstallChartRequest `json:"charts" validate:"dive,required"`
	ChartGroupId                  int                              `json:"chartGroupId"` //optional
	UserId                        int32                            `json:"-"`
}

/ bean for v2

type ChartGroupList

type ChartGroupList struct {
	Groups []*ChartGroupBean `json:"groups,omitempty"`
}

type ChartGroupService

type ChartGroupService interface {
	CreateChartGroup(req *ChartGroupBean) (*ChartGroupBean, error)
	UpdateChartGroup(req *ChartGroupBean) (*ChartGroupBean, error)
	SaveChartGroupEntries(req *ChartGroupBean) (*ChartGroupBean, error)
	GetChartGroupWithChartMetaData(chartGroupId int) (*ChartGroupBean, error)
	ChartGroupList(max int) (*ChartGroupList, error)
	GetChartGroupWithInstallationDetail(chartGroupId int) (*ChartGroupBean, error)
	ChartGroupListMin(max int) ([]*ChartGroupBean, error)
	DeleteChartGroup(req *ChartGroupBean) error
}

type ChartGroupServiceImpl

type ChartGroupServiceImpl struct {
	Logger *zap.SugaredLogger
	// contains filtered or unexported fields
}

func NewChartGroupServiceImpl

func NewChartGroupServiceImpl(chartGroupEntriesRepository repository2.ChartGroupEntriesRepository,
	chartGroupRepository repository2.ChartGroupReposotory,
	Logger *zap.SugaredLogger, chartGroupDeploymentRepository repository2.ChartGroupDeploymentRepository,
	installedAppRepository repository.InstalledAppRepository, appStoreVersionValuesRepository appStoreValuesRepository.AppStoreVersionValuesRepository, userAuthService user.UserAuthService) *ChartGroupServiceImpl

func (*ChartGroupServiceImpl) ChartGroupList

func (impl *ChartGroupServiceImpl) ChartGroupList(max int) (*ChartGroupList, error)

func (*ChartGroupServiceImpl) ChartGroupListMin

func (impl *ChartGroupServiceImpl) ChartGroupListMin(max int) ([]*ChartGroupBean, error)

func (*ChartGroupServiceImpl) CreateChartGroup

func (impl *ChartGroupServiceImpl) CreateChartGroup(req *ChartGroupBean) (*ChartGroupBean, error)

func (*ChartGroupServiceImpl) DeleteChartGroup

func (impl *ChartGroupServiceImpl) DeleteChartGroup(req *ChartGroupBean) error

func (*ChartGroupServiceImpl) GetChartGroupWithChartMetaData

func (impl *ChartGroupServiceImpl) GetChartGroupWithChartMetaData(chartGroupId int) (*ChartGroupBean, error)

func (*ChartGroupServiceImpl) GetChartGroupWithInstallationDetail

func (impl *ChartGroupServiceImpl) GetChartGroupWithInstallationDetail(chartGroupId int) (*ChartGroupBean, error)

func (*ChartGroupServiceImpl) SaveChartGroupEntries

func (impl *ChartGroupServiceImpl) SaveChartGroupEntries(req *ChartGroupBean) (*ChartGroupBean, error)

func (*ChartGroupServiceImpl) UpdateChartGroup

func (impl *ChartGroupServiceImpl) UpdateChartGroup(req *ChartGroupBean) (*ChartGroupBean, error)

type ChartMetaData

type ChartMetaData struct {
	ChartName                  string `json:"chartName,omitempty"`
	ChartRepoName              string `json:"chartRepoName,omitempty"`
	Icon                       string `json:"icon,omitempty"`
	AppStoreId                 int    `json:"appStoreId"`
	AppStoreApplicationVersion string `json:"appStoreApplicationVersion"`
	EnvironmentName            string `json:"environmentName,omitempty"`
	EnvironmentId              int    `json:"environmentId,omitempty"` //FIXME REMOVE THIS ATTRIBUTE AFTER REMOVING ENVORONMENTID FROM GETINSTALLEDAPPCALL
	IsChartRepoActive          bool   `json:"isChartRepoActive"`
}

type InstalledChart

type InstalledChart struct {
	ChartMetaData
	InstalledAppId int `json:"installedAppId,omitempty"`
}

type InstalledChartData

type InstalledChartData struct {
	InstallationTime time.Time         `json:"installationTime,omitempty"`
	InstalledCharts  []*InstalledChart `json:"installedCharts,omitempty"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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