Help us shape the future of Go! Take the 2026 Go Developer Survey

repository

package
v0.3.24 Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2022 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ChartGroup

type ChartGroup struct {
	TableName   struct{} `sql:"chart_group" pg:",discard_unknown_columns"`
	Id          int      `sql:"id,pk"`
	Name        string   `sql:"name"`
	Description string   `sql:"description,notnull"`
	Deleted     bool     `sql:"deleted,notnull"`
	sql.AuditLog
	ChartGroupEntries []*ChartGroupEntry
}

type ChartGroupDeployment

type ChartGroupDeployment struct {
	TableName           struct{} `sql:"chart_group_deployment" pg:",discard_unknown_columns"`
	Id                  int      `sql:"id,pk"`
	ChartGroupId        int      `sql:"chart_group_id"`
	ChartGroupEntryId   int      `sql:"chart_group_entry_id"`
	InstalledAppId      int      `sql:"installed_app_id"`
	GroupInstallationId string   `sql:"group_installation_id"`
	Deleted             bool     `sql:"deleted,notnull"`
	sql.AuditLog
}

type ChartGroupDeploymentRepository

type ChartGroupDeploymentRepository interface {
	Save(tx *pg.Tx, chartGroupDeployment *ChartGroupDeployment) error
	FindByChartGroupId(chartGroupId int) ([]*ChartGroupDeployment, error)
	Update(model *ChartGroupDeployment, tx *pg.Tx) (*ChartGroupDeployment, error)
	FindByInstalledAppId(installedAppId int) (*ChartGroupDeployment, error)
}

type ChartGroupDeploymentRepositoryImpl

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

func NewChartGroupDeploymentRepositoryImpl

func NewChartGroupDeploymentRepositoryImpl(
	dbConnection *pg.DB,
	Logger *zap.SugaredLogger) *ChartGroupDeploymentRepositoryImpl

func (*ChartGroupDeploymentRepositoryImpl) FindByChartGroupId

func (impl *ChartGroupDeploymentRepositoryImpl) FindByChartGroupId(chartGroupId int) ([]*ChartGroupDeployment, error)

func (*ChartGroupDeploymentRepositoryImpl) FindByInstalledAppId

func (impl *ChartGroupDeploymentRepositoryImpl) FindByInstalledAppId(installedAppId int) (*ChartGroupDeployment, error)

func (*ChartGroupDeploymentRepositoryImpl) Save

func (impl *ChartGroupDeploymentRepositoryImpl) Save(tx *pg.Tx, chartGroupDeployment *ChartGroupDeployment) error

func (*ChartGroupDeploymentRepositoryImpl) Update

type ChartGroupEntriesRepository

type ChartGroupEntriesRepository interface {
	Save(model *ChartGroupEntry) (*ChartGroupEntry, error)
	SaveAndUpdateInTransaction(saveEntry []*ChartGroupEntry, updateEntry []*ChartGroupEntry) ([]*ChartGroupEntry, error)
	FindEntriesWithChartMetaByChartGroupId(chartGroupId []int) ([]*ChartGroupEntry, error)
	MarkChartGroupEntriesDeleted(chartGroupId []int, tx *pg.Tx) ([]*ChartGroupEntry, error)
}

type ChartGroupEntriesRepositoryImpl

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

func NewChartGroupEntriesRepositoryImpl

func NewChartGroupEntriesRepositoryImpl(dbConnection *pg.DB, Logger *zap.SugaredLogger) *ChartGroupEntriesRepositoryImpl

func (*ChartGroupEntriesRepositoryImpl) FindEntriesWithChartMetaByChartGroupId

func (impl *ChartGroupEntriesRepositoryImpl) FindEntriesWithChartMetaByChartGroupId(chartGroupId []int) ([]*ChartGroupEntry, error)

func (*ChartGroupEntriesRepositoryImpl) MarkChartGroupEntriesDeleted

func (impl *ChartGroupEntriesRepositoryImpl) MarkChartGroupEntriesDeleted(chartGroupId []int, tx *pg.Tx) ([]*ChartGroupEntry, error)

func (*ChartGroupEntriesRepositoryImpl) Save

func (*ChartGroupEntriesRepositoryImpl) SaveAndUpdateInTransaction

func (impl *ChartGroupEntriesRepositoryImpl) SaveAndUpdateInTransaction(saveEntry []*ChartGroupEntry, updateEntry []*ChartGroupEntry) ([]*ChartGroupEntry, error)

type ChartGroupEntry

type ChartGroupEntry struct {
	TableName                    struct{} `sql:"chart_group_entry" pg:",discard_unknown_columns"`
	Id                           int      `sql:"id,pk"`
	AppStoreValuesVersionId      int      `sql:"app_store_values_version_id"`      //AppStoreVersionValuesId
	AppStoreApplicationVersionId int      `sql:"app_store_application_version_id"` //AppStoreApplicationVersionId
	ChartGroupId                 int      `sql:"chart_group_id"`
	Deleted                      bool     `sql:"deleted,notnull"`
	sql.AuditLog
	AppStoreApplicationVersion *appStoreDiscoverRepository.AppStoreApplicationVersion
	AppStoreValuesVersion      *appStoreValuesRepository.AppStoreVersionValues
}

type ChartGroupReposotory

type ChartGroupReposotory interface {
	Save(model *ChartGroup) (*ChartGroup, error)
	Update(model *ChartGroup) (*ChartGroup, error)
	FindByIdWithEntries(chertGroupId int) (*ChartGroup, error)
	FindById(chartGroupId int) (*ChartGroup, error)
	GetAll(max int) ([]*ChartGroup, error)
	MarkChartGroupDeleted(chartGroupId int, tx *pg.Tx) error
}

type ChartGroupReposotoryImpl

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

func NewChartGroupReposotoryImpl

func NewChartGroupReposotoryImpl(dbConnection *pg.DB, Logger *zap.SugaredLogger) *ChartGroupReposotoryImpl

func (*ChartGroupReposotoryImpl) FindById

func (impl *ChartGroupReposotoryImpl) FindById(chartGroupId int) (*ChartGroup, error)

func (*ChartGroupReposotoryImpl) FindByIdWithEntries

func (impl *ChartGroupReposotoryImpl) FindByIdWithEntries(chertGroupId int) (*ChartGroup, error)

func (*ChartGroupReposotoryImpl) GetAll

func (impl *ChartGroupReposotoryImpl) GetAll(max int) ([]*ChartGroup, error)

func (*ChartGroupReposotoryImpl) MarkChartGroupDeleted

func (impl *ChartGroupReposotoryImpl) MarkChartGroupDeleted(chartGroupId int, tx *pg.Tx) error

func (*ChartGroupReposotoryImpl) Save

func (impl *ChartGroupReposotoryImpl) Save(model *ChartGroup) (*ChartGroup, error)

func (*ChartGroupReposotoryImpl) Update

func (impl *ChartGroupReposotoryImpl) Update(model *ChartGroup) (*ChartGroup, error)

type ClusterInstalledApps

type ClusterInstalledApps struct {
	Id             int `sql:"id,pk"`
	ClusterId      int `sql:"cluster_id,notnull"`
	InstalledAppId int `sql:"installed_app_id,notnull"`
	InstalledApp   InstalledApps
	sql.AuditLog
	// contains filtered or unexported fields
}

type ClusterInstalledAppsRepository

type ClusterInstalledAppsRepository interface {
	Save(model *ClusterInstalledApps, tx *pg.Tx) error
	FindByClusterId(clusterId int) ([]*ClusterInstalledApps, error)
	FindByClusterIds(clusterIds []int) ([]*ClusterInstalledApps, error)
	FindAll() ([]ClusterInstalledApps, error)
	Update(model *ClusterInstalledApps) error
	Delete(model *ClusterInstalledApps) error
}

type ClusterInstalledAppsRepositoryImpl

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

func NewClusterInstalledAppsRepositoryImpl

func NewClusterInstalledAppsRepositoryImpl(dbConnection *pg.DB, logger *zap.SugaredLogger) *ClusterInstalledAppsRepositoryImpl

func (ClusterInstalledAppsRepositoryImpl) Delete

func (ClusterInstalledAppsRepositoryImpl) FindAll

func (ClusterInstalledAppsRepositoryImpl) FindByClusterId

func (impl ClusterInstalledAppsRepositoryImpl) FindByClusterId(clusterId int) ([]*ClusterInstalledApps, error)

func (ClusterInstalledAppsRepositoryImpl) FindByClusterIds

func (impl ClusterInstalledAppsRepositoryImpl) FindByClusterIds(clusterIds []int) ([]*ClusterInstalledApps, error)

func (ClusterInstalledAppsRepositoryImpl) Save

func (ClusterInstalledAppsRepositoryImpl) Update

type InstalledAppAndEnvDetails

type InstalledAppAndEnvDetails struct {
	EnvironmentName              string    `json:"environment_name"`
	EnvironmentId                int       `json:"environment_id"`
	AppName                      string    `json:"app_name"`
	AppOfferingMode              string    `json:"appOfferingMode"`
	UpdatedOn                    time.Time `json:"updated_on"`
	EmailId                      string    `json:"email_id"`
	InstalledAppVersionId        int       `json:"installed_app_version_id"`
	InstalledAppId               int       `json:"installed_app_id"`
	AppStoreApplicationVersionId int       `json:"app_store_application_version_id"`
}

type InstalledAppRepository

type InstalledAppRepository interface {
	CreateInstalledApp(model *InstalledApps, tx *pg.Tx) (*InstalledApps, error)
	CreateInstalledAppVersion(model *InstalledAppVersions, tx *pg.Tx) (*InstalledAppVersions, error)
	UpdateInstalledApp(model *InstalledApps, tx *pg.Tx) (*InstalledApps, error)
	UpdateInstalledAppVersion(model *InstalledAppVersions, tx *pg.Tx) (*InstalledAppVersions, error)
	GetInstalledApp(id int) (*InstalledApps, error)
	GetInstalledAppVersion(id int) (*InstalledAppVersions, error)
	GetInstalledAppVersionAny(id int) (*InstalledAppVersions, error)
	GetAllInstalledApps(filter *appStoreBean.AppStoreFilter) ([]InstalledAppsWithChartDetails, error)
	GetAllIntalledAppsByAppStoreId(appStoreId int) ([]InstalledAppAndEnvDetails, error)
	GetAllInstalledAppsByChartRepoId(chartRepoId int) ([]InstalledAppAndEnvDetails, error)
	GetInstalledAppVersionByInstalledAppIdAndEnvId(installedAppId int, envId int) (*InstalledAppVersions, error)
	GetInstalledAppVersionByAppStoreId(appStoreId int) ([]*InstalledAppVersions, error)

	DeleteInstalledApp(model *InstalledApps) (*InstalledApps, error)
	DeleteInstalledAppVersion(model *InstalledAppVersions) (*InstalledAppVersions, error)
	GetInstalledAppVersionByInstalledAppId(id int) ([]*InstalledAppVersions, error)
	GetConnection() (dbConnection *pg.DB)
	GetInstalledAppVersionByInstalledAppIdMeta(installedAppId int) ([]*InstalledAppVersions, error)
	GetActiveInstalledAppVersionByInstalledAppId(installedAppId int) (*InstalledAppVersions, error)
	GetLatestInstalledAppVersionByGitHash(gitHash string) (*InstalledAppVersions, error)
	GetClusterComponentByClusterId(clusterId int) ([]*InstalledApps, error)     //unused
	GetClusterComponentByClusterIds(clusterIds []int) ([]*InstalledApps, error) //unused
	GetInstalledAppVersionByAppIdAndEnvId(appId int, envId int) (*InstalledAppVersions, error)
	GetInstalledAppVersionByClusterIds(clusterIds []int) ([]*InstalledAppVersions, error) //unused
	GetInstalledAppVersionByClusterIdsV2(clusterIds []int) ([]*InstalledAppVersions, error)
	GetInstalledApplicationByClusterIdAndNamespaceAndAppName(clusterId int, namespace string, appName string) (*InstalledApps, error)
}

type InstalledAppRepositoryImpl

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

func NewInstalledAppRepositoryImpl

func NewInstalledAppRepositoryImpl(Logger *zap.SugaredLogger, dbConnection *pg.DB) *InstalledAppRepositoryImpl

func (InstalledAppRepositoryImpl) CreateInstalledApp

func (impl InstalledAppRepositoryImpl) CreateInstalledApp(model *InstalledApps, tx *pg.Tx) (*InstalledApps, error)

func (InstalledAppRepositoryImpl) CreateInstalledAppVersion

func (impl InstalledAppRepositoryImpl) CreateInstalledAppVersion(model *InstalledAppVersions, tx *pg.Tx) (*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) DeleteInstalledApp

func (impl InstalledAppRepositoryImpl) DeleteInstalledApp(model *InstalledApps) (*InstalledApps, error)

func (InstalledAppRepositoryImpl) DeleteInstalledAppVersion

func (impl InstalledAppRepositoryImpl) DeleteInstalledAppVersion(model *InstalledAppVersions) (*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) GetActiveInstalledAppVersionByInstalledAppId

func (impl InstalledAppRepositoryImpl) GetActiveInstalledAppVersionByInstalledAppId(installedAppId int) (*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) GetAllInstalledApps

func (InstalledAppRepositoryImpl) GetAllInstalledAppsByChartRepoId

func (impl InstalledAppRepositoryImpl) GetAllInstalledAppsByChartRepoId(chartRepoId int) ([]InstalledAppAndEnvDetails, error)

func (InstalledAppRepositoryImpl) GetAllIntalledAppsByAppStoreId

func (impl InstalledAppRepositoryImpl) GetAllIntalledAppsByAppStoreId(appStoreId int) ([]InstalledAppAndEnvDetails, error)

func (InstalledAppRepositoryImpl) GetClusterComponentByClusterId

func (impl InstalledAppRepositoryImpl) GetClusterComponentByClusterId(clusterId int) ([]*InstalledApps, error)

func (InstalledAppRepositoryImpl) GetClusterComponentByClusterIds

func (impl InstalledAppRepositoryImpl) GetClusterComponentByClusterIds(clusterIds []int) ([]*InstalledApps, error)

func (*InstalledAppRepositoryImpl) GetConnection

func (impl *InstalledAppRepositoryImpl) GetConnection() (dbConnection *pg.DB)

func (InstalledAppRepositoryImpl) GetInstalledApp

func (impl InstalledAppRepositoryImpl) GetInstalledApp(id int) (*InstalledApps, error)

func (InstalledAppRepositoryImpl) GetInstalledAppVersion

func (impl InstalledAppRepositoryImpl) GetInstalledAppVersion(id int) (*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) GetInstalledAppVersionAny

func (impl InstalledAppRepositoryImpl) GetInstalledAppVersionAny(id int) (*InstalledAppVersions, error)

it returns enable and disabled both version

func (InstalledAppRepositoryImpl) GetInstalledAppVersionByAppIdAndEnvId

func (impl InstalledAppRepositoryImpl) GetInstalledAppVersionByAppIdAndEnvId(appId int, envId int) (*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) GetInstalledAppVersionByAppStoreId

func (impl InstalledAppRepositoryImpl) GetInstalledAppVersionByAppStoreId(appStoreId int) ([]*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) GetInstalledAppVersionByClusterIds

func (impl InstalledAppRepositoryImpl) GetInstalledAppVersionByClusterIds(clusterIds []int) ([]*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) GetInstalledAppVersionByClusterIdsV2

func (impl InstalledAppRepositoryImpl) GetInstalledAppVersionByClusterIdsV2(clusterIds []int) ([]*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) GetInstalledAppVersionByInstalledAppId

func (impl InstalledAppRepositoryImpl) GetInstalledAppVersionByInstalledAppId(installedAppId int) ([]*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) GetInstalledAppVersionByInstalledAppIdAndEnvId

func (impl InstalledAppRepositoryImpl) GetInstalledAppVersionByInstalledAppIdAndEnvId(installedAppId int, envId int) (*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) GetInstalledAppVersionByInstalledAppIdMeta

func (impl InstalledAppRepositoryImpl) GetInstalledAppVersionByInstalledAppIdMeta(installedAppId int) ([]*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) GetInstalledApplicationByClusterIdAndNamespaceAndAppName

func (impl InstalledAppRepositoryImpl) GetInstalledApplicationByClusterIdAndNamespaceAndAppName(clusterId int, namespace string, appName string) (*InstalledApps, error)

func (InstalledAppRepositoryImpl) GetLatestInstalledAppVersionByGitHash

func (impl InstalledAppRepositoryImpl) GetLatestInstalledAppVersionByGitHash(gitHash string) (*InstalledAppVersions, error)

func (InstalledAppRepositoryImpl) UpdateInstalledApp

func (impl InstalledAppRepositoryImpl) UpdateInstalledApp(model *InstalledApps, tx *pg.Tx) (*InstalledApps, error)

func (InstalledAppRepositoryImpl) UpdateInstalledAppVersion

func (impl InstalledAppRepositoryImpl) UpdateInstalledAppVersion(model *InstalledAppVersions, tx *pg.Tx) (*InstalledAppVersions, error)

type InstalledAppVersionHistory

type InstalledAppVersionHistory struct {
	TableName             struct{} `sql:"installed_app_version_history" pg:",discard_unknown_columns"`
	Id                    int      `sql:"id,pk"`
	InstalledAppVersionId int      `sql:"installed_app_version_id,notnull"`
	ValuesYamlRaw         string   `sql:"values_yaml_raw"`
	Status                string   `sql:"status"`
	GitHash               string   `sql:"git_hash"`
	sql.AuditLog
}

type InstalledAppVersionHistoryRepository

type InstalledAppVersionHistoryRepository interface {
	CreateInstalledAppVersionHistory(model *InstalledAppVersionHistory, tx *pg.Tx) (*InstalledAppVersionHistory, error)
	UpdateInstalledAppVersionHistory(model *InstalledAppVersionHistory, tx *pg.Tx) (*InstalledAppVersionHistory, error)
	GetInstalledAppVersionHistory(id int) (*InstalledAppVersionHistory, error)
	GetInstalledAppVersionHistoryByVersionId(installAppVersionId int) ([]*InstalledAppVersionHistory, error)
	GetLatestInstalledAppVersionHistory(installAppVersionId int) (*InstalledAppVersionHistory, error)
	GetLatestInstalledAppVersionHistoryByGitHash(gitHash string) (*InstalledAppVersionHistory, error)
}

type InstalledAppVersionHistoryRepositoryImpl

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

func NewInstalledAppVersionHistoryRepositoryImpl

func NewInstalledAppVersionHistoryRepositoryImpl(Logger *zap.SugaredLogger, dbConnection *pg.DB) *InstalledAppVersionHistoryRepositoryImpl

func (InstalledAppVersionHistoryRepositoryImpl) CreateInstalledAppVersionHistory

func (impl InstalledAppVersionHistoryRepositoryImpl) CreateInstalledAppVersionHistory(model *InstalledAppVersionHistory, tx *pg.Tx) (*InstalledAppVersionHistory, error)

func (InstalledAppVersionHistoryRepositoryImpl) GetInstalledAppVersionHistory

func (impl InstalledAppVersionHistoryRepositoryImpl) GetInstalledAppVersionHistory(id int) (*InstalledAppVersionHistory, error)

func (InstalledAppVersionHistoryRepositoryImpl) GetInstalledAppVersionHistoryByVersionId

func (impl InstalledAppVersionHistoryRepositoryImpl) GetInstalledAppVersionHistoryByVersionId(installAppVersionId int) ([]*InstalledAppVersionHistory, error)

func (InstalledAppVersionHistoryRepositoryImpl) GetLatestInstalledAppVersionHistory

func (impl InstalledAppVersionHistoryRepositoryImpl) GetLatestInstalledAppVersionHistory(installAppVersionId int) (*InstalledAppVersionHistory, error)

func (InstalledAppVersionHistoryRepositoryImpl) GetLatestInstalledAppVersionHistoryByGitHash

func (impl InstalledAppVersionHistoryRepositoryImpl) GetLatestInstalledAppVersionHistoryByGitHash(gitHash string) (*InstalledAppVersionHistory, error)

func (InstalledAppVersionHistoryRepositoryImpl) UpdateInstalledAppVersionHistory

func (impl InstalledAppVersionHistoryRepositoryImpl) UpdateInstalledAppVersionHistory(model *InstalledAppVersionHistory, tx *pg.Tx) (*InstalledAppVersionHistory, error)

type InstalledAppVersions

type InstalledAppVersions struct {
	TableName                    struct{} `sql:"installed_app_versions" pg:",discard_unknown_columns"`
	Id                           int      `sql:"id,pk"`
	InstalledAppId               int      `sql:"installed_app_id,notnull"`
	AppStoreApplicationVersionId int      `sql:"app_store_application_version_id,notnull"`
	ValuesYaml                   string   `sql:"values_yaml_raw"`
	Active                       bool     `sql:"active, notnull"`
	ReferenceValueId             int      `sql:"reference_value_id"`
	ReferenceValueKind           string   `sql:"reference_value_kind"`
	sql.AuditLog
	InstalledApp               InstalledApps
	AppStoreApplicationVersion appStoreDiscoverRepository.AppStoreApplicationVersion
}

type InstalledApps

type InstalledApps struct {
	TableName      struct{}                              `sql:"installed_apps" pg:",discard_unknown_columns"`
	Id             int                                   `sql:"id,pk"`
	AppId          int                                   `sql:"app_id,notnull"`
	EnvironmentId  int                                   `sql:"environment_id,notnull"`
	Active         bool                                  `sql:"active, notnull"`
	GitOpsRepoName string                                `sql:"git_ops_repo_name"`
	Status         appStoreBean.AppstoreDeploymentStatus `sql:"status"`
	App            app.App
	Environment    repository.Environment
	sql.AuditLog
}

type InstalledAppsWithChartDetails

type InstalledAppsWithChartDetails struct {
	AppStoreApplicationName      string    `json:"app_store_application_name"`
	ChartRepoName                string    `json:"chart_repo_name"`
	AppName                      string    `json:"app_name"`
	EnvironmentName              string    `json:"environment_name"`
	InstalledAppVersionId        int       `json:"installed_app_version_id"`
	AppStoreApplicationVersionId int       `json:"app_store_application_version_id"`
	Icon                         string    `json:"icon"`
	Readme                       string    `json:"readme"`
	CreatedOn                    time.Time `json:"created_on"`
	UpdatedOn                    time.Time `json:"updated_on"`
	Id                           int       `json:"id"`
	EnvironmentId                int       `json:"environment_id"`
	Deprecated                   bool      `json:"deprecated"`
	ClusterName                  string    `json:"clusterName"`
	Namespace                    string    `json:"namespace"`
	TeamId                       int       `json:"teamId"`
	ClusterId                    int       `json:"clusterId"`
}

Jump to

Keyboard shortcuts

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