Versions in this module Expand all Collapse all v1 v1.2.0 Jan 27, 2025 v1.1.0 Dec 20, 2024 Changes in this version + type ClusterNamespacePair struct + ClusterId int + NamespaceName string + type EnvCluserInfo struct + ClusterName string + Id int + Name string + Namespace string + type Environment struct + Active bool + Cluster *repository.Cluster + ClusterId int + Default bool + Description string + EnvironmentIdentifier string + GrafanaDatasourceId int + Id int + IsVirtualEnvironment bool + Name string + Namespace string + func (environment *Environment) IsEmpty() bool + type EnvironmentRepository interface + Create func(mappings *Environment) error + FindAll func() ([]Environment, error) + FindAllActive func() ([]*Environment, error) + FindAllActiveEnvOnlyDetails func() ([]*Environment, error) + FindAllActiveEnvironmentCount func() (int, error) + FindAllActiveWithFilter func() ([]*Environment, error) + FindByClusterId func(clusterId int) ([]*Environment, error) + FindByClusterIdAndNamespace func(namespaceClusterPair []*ClusterNamespacePair) ([]*Environment, error) + FindByClusterIds func(clusterIds []int) ([]*Environment, error) + FindByClusterIdsWithFilter func(clusterIds []int) ([]*Environment, error) + FindByEnvName func(envName string) ([]*Environment, error) + FindByEnvNameAndClusterIds func(envName string, clusterIds []int) ([]*Environment, error) + FindByEnvNameOrIdentifierOrNamespace func(clusterId int, envName string, identifier string, namespace string) (*Environment, error) + FindById func(id int) (*Environment, error) + FindByIdentifier func(identifier string) (*Environment, error) + FindByIds func(ids []*int) ([]*Environment, error) + FindByName func(name string) (*Environment, error) + FindByNameOrIdentifier func(name string, identifier string) (*Environment, error) + FindByNames func(envNames []string) ([]*Environment, error) + FindByNamespaceAndClusterName func(namespaces string, clusterName string) (*Environment, error) + FindEnvByNameWithClusterDetails func(envName string) (*Environment, error) + FindEnvClusterInfosByIds func([]int) ([]*EnvCluserInfo, error) + FindEnvLinkedWithCiPipelines func(externalCi bool, ciPipelineIds []int) ([]*Environment, error) + FindIdByName func(name string) (int, error) + FindIdsByNames func(envNames []string) ([]int, error) + FindOne func(environment string) (*Environment, error) + FindOneByNamespaceAndClusterId func(namespace string, clusterId int) (*Environment, error) + GetConnection func() (dbConnection *pg.DB) + MarkEnvironmentDeleted func(mappings *Environment, tx *pg.Tx) error + Update func(mappings *Environment) error + type EnvironmentRepositoryImpl struct + func NewEnvironmentRepositoryImpl(dbConnection *pg.DB, logger *zap.SugaredLogger, ...) *EnvironmentRepositoryImpl + func (repo EnvironmentRepositoryImpl) FindByNames(envNames []string) ([]*Environment, error) + func (repo EnvironmentRepositoryImpl) FindIdsByNames(envNames []string) ([]int, error) + func (repo EnvironmentRepositoryImpl) GetConnection() (dbConnection *pg.DB) + func (repo EnvironmentRepositoryImpl) MarkEnvironmentDeleted(deleteReq *Environment, tx *pg.Tx) error + func (repositoryImpl EnvironmentRepositoryImpl) Create(mappings *Environment) error + func (repositoryImpl EnvironmentRepositoryImpl) FindAll() ([]Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindAllActive() ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindAllActiveEnvOnlyDetails() ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindAllActiveEnvironmentCount() (int, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindAllActiveWithFilter() ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByClusterId(clusterId int) ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByClusterIdAndNamespace(namespaceClusterPair []*ClusterNamespacePair) ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByClusterIds(clusterIds []int) ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByClusterIdsWithFilter(clusterIds []int) ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByEnvName(envName string) ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByEnvNameAndClusterIds(envName string, clusterIds []int) ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByEnvNameOrIdentifierOrNamespace(clusterId int, envName string, identifier string, namespace string) (*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindById(id int) (*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByIdentifier(identifier string) (*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByIds(ids []*int) ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByName(name string) (*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByNameOrIdentifier(name string, identifier string) (*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindByNamespaceAndClusterName(namespaces string, clusterName string) (*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindEnvByNameWithClusterDetails(envName string) (*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindEnvClusterInfosByIds(envIds []int) ([]*EnvCluserInfo, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindEnvLinkedWithCiPipelines(externalCi bool, ciPipelineIds []int) ([]*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindIdByName(name string) (int, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindOne(environment string) (*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) FindOneByNamespaceAndClusterId(namespace string, clusterId int) (*Environment, error) + func (repositoryImpl EnvironmentRepositoryImpl) Update(mappings *Environment) error