Versions in this module Expand all Collapse all v0 v0.7.0 Jul 19, 2023 Changes in this version + type AggregatedPoliciesStatusDB interface + DeleteAllComplianceRows func(ctx context.Context, schema string, tableName string, leafHubName string, ...) error + GetPolicyIDsByLeafHub func(ctx context.Context, schema string, tableName string, leafHubName string) (set.Set, error) + InsertOrUpdateAggregatedPolicyCompliance func(ctx context.Context, schema string, tableName string, leafHubName string, ...) error + type BatchBuilder interface + Build func() interface{} + type BatchSenderDB interface + SendBatch func(ctx context.Context, batch interface{}) error + type ControlInfoDB interface + UpdateHeartbeat func(ctx context.Context, schema string, tableName string, leafHubName string) error + type GenericBatchBuilder interface + Delete func(id string) + Insert func(id string, payload interface{}) + Update func(id string, payload interface{}) + type GenericLocalBatchBuilder interface + Delete func(id string) + Insert func(payload interface{}) + Update func(payload interface{}) + type GenericStatusResourceDB interface + GetResourceIDToVersionByLeafHub func(ctx context.Context, schema string, tableName string, leafHubName string) (map[string]string, error) + NewGenericBatchBuilder func(schema string, tableName string, leafHubName string) GenericBatchBuilder + type LocalPoliciesStatusDB interface + GetLocalResourceIDToVersionByLeafHub func(ctx context.Context, schema string, tableName string, leafHubName string) (map[string]string, error) + NewGenericLocalBatchBuilder func(schema string, tableName string, leafHubName string) GenericLocalBatchBuilder + type ManagedClustersBatchBuilder interface + Delete func(clusterName string) + Insert func(clusterID string, payload interface{}, errorString string) + Update func(clusterID string, clusterName string, payload interface{}) + type ManagedClustersStatusDB interface + GetManagedClustersByLeafHub func(ctx context.Context, schema string, tableName string, leafHubName string) (map[string]string, error) + NewManagedClustersBatchBuilder func(schema string, tableName string, leafHubName string) ManagedClustersBatchBuilder + type PoliciesBatchBuilder interface + DeleteClusterStatus func(policyID string, clusterName string) + DeletePolicy func(policyID string) + Insert func(policyID string, clusterName string, errorString string, ...) + UpdateClusterCompliance func(policyID string, clusterName string, compliance database.ComplianceStatus) + UpdatePolicyCompliance func(policyID string, compliance database.ComplianceStatus) + type PoliciesStatusDB interface + GetComplianceStatusByLeafHub func(ctx context.Context, schema string, tableName string, leafHubName string) (map[string]*PolicyClustersSets, error) + GetNonCompliantClustersByLeafHub func(ctx context.Context, schema string, tableName string, leafHubName string) (map[string]*PolicyClustersSets, error) + NewPoliciesBatchBuilder func(schema string, tableName string, leafHubName string) PoliciesBatchBuilder + type PolicyClustersSets struct + func NewPolicyClusterSets() *PolicyClustersSets + func (sets *PolicyClustersSets) AddCluster(clusterName string, complianceStatus database.ComplianceStatus) + func (sets *PolicyClustersSets) GetAllClusters() set.Set + func (sets *PolicyClustersSets) GetClusters(complianceStatus database.ComplianceStatus) set.Set + type PostgreSQL struct + func NewStatusPostgreSQL(ctx context.Context, dataConfig *database.DatabaseConfig) (*PostgreSQL, error) + func (p *PostgreSQL) DeleteAllComplianceRows(ctx context.Context, schema string, tableName string, leafHubName string, ...) error + func (p *PostgreSQL) GetComplianceStatusByLeafHub(ctx context.Context, schema string, tableName string, leafHubName string) (map[string]*PolicyClustersSets, error) + func (p *PostgreSQL) GetLocalResourceIDToVersionByLeafHub(ctx context.Context, schema string, tableName string, leafHubName string) (map[string]string, error) + func (p *PostgreSQL) GetManagedClustersByLeafHub(ctx context.Context, schema string, tableName string, leafHubName string) (map[string]string, error) + func (p *PostgreSQL) GetNonCompliantClustersByLeafHub(ctx context.Context, schema string, tableName string, leafHubName string) (map[string]*PolicyClustersSets, error) + func (p *PostgreSQL) GetPolicyIDsByLeafHub(ctx context.Context, schema string, tableName string, leafHubName string) (set.Set, error) + func (p *PostgreSQL) GetPoolSize() int32 + func (p *PostgreSQL) GetResourceIDToVersionByLeafHub(ctx context.Context, schema string, tableName string, leafHubName string) (map[string]string, error) + func (p *PostgreSQL) InsertOrUpdateAggregatedPolicyCompliance(ctx context.Context, schema string, tableName string, leafHubName string, ...) error + func (p *PostgreSQL) NewGenericBatchBuilder(schema string, tableName string, leafHubName string) GenericBatchBuilder + func (p *PostgreSQL) NewGenericLocalBatchBuilder(schema string, tableName string, leafHubName string) GenericLocalBatchBuilder + func (p *PostgreSQL) NewManagedClustersBatchBuilder(schema string, tableName string, leafHubName string) ManagedClustersBatchBuilder + func (p *PostgreSQL) NewPoliciesBatchBuilder(schema string, tableName string, leafHubName string) PoliciesBatchBuilder + func (p *PostgreSQL) SendBatch(ctx context.Context, batch interface{}) error + func (p *PostgreSQL) Stop() + func (p *PostgreSQL) UpdateHeartbeat(ctx context.Context, schema string, tableName string, leafHubName string) error + type StatusTransportBridgeDB interface + GetPoolSize func() int32 + Stop func()