Documentation ¶
Index ¶
Constants ¶
View Source
const FieldPrefix = "crd.spec."
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClusterDb ¶
type ClusterDb struct { TablePartitionKey string `json:"name"` IndexPartitionKey string `json:"kind"` Region string `json:"region"` Environment string `json:"environment"` Status string `json:"status"` LastUpdatedUnix int64 `json:"lastUpdatedUnix"` Cluster *registryv1.Cluster `json:"crd"` }
ClusterDb encapsulates the Cluster CRD
type Db ¶
type Db interface { GetCluster(name string) (*registryv1.Cluster, error) ListClusters(offset int, limit int, environment string, region string, status string, lastUpdated string) ([]registryv1.Cluster, int, bool, error) ListClustersWithFilter(offset int, limit int, filter *DynamoDBFilter) ([]registryv1.Cluster, int, bool, error) PutCluster(cluster *registryv1.Cluster) error DeleteCluster(name string) error Status() error Mock() *dynamock.DynaMock ListClustersWithService(serviceId string, offset int, limit int, environment string, region string, status string, lastUpdated string) ([]registryv1.Cluster, int, bool, error) ListClustersWithServiceAndFilter(serviceId string, offset int, limit int, filter *DynamoDBFilter) ([]registryv1.Cluster, int, bool, error) GetClusterWithService(serviceId string, clusterName string) (*registryv1.Cluster, error) }
Db provides an interface for interacting with dynamoDb
type DynamoDBFilter ¶ added in v1.3.0
type DynamoDBFilter struct {
// contains filtered or unexported fields
}
func NewDynamoDBFilter ¶ added in v1.3.0
func NewDynamoDBFilter() *DynamoDBFilter
func (*DynamoDBFilter) AddCondition ¶ added in v1.3.0
func (f *DynamoDBFilter) AddCondition(condition *models.FilterCondition) *DynamoDBFilter
func (*DynamoDBFilter) Build ¶ added in v1.3.0
func (f *DynamoDBFilter) Build() (expression.ConditionBuilder, error)
Click to show internal directories.
Click to hide internal directories.