Documentation
¶
Index ¶
- func ClusterGroupsToLabelMap(cgs []*fleet.ClusterGroup) map[string]map[string]string
- func DeploymentLabelsForNewBundle(app *fleet.Bundle) map[string]string
- func DeploymentLabelsForSelector(app *fleet.Bundle) map[string]string
- func IsPartitionUnavailable(status *fleet.PartitionStatus, targets []*Target) bool
- func IsUnavailable(target *fleet.BundleDeployment) bool
- func Limit(count int, val ...*intstr.IntOrString) (int, error)
- func MaxUnavailable(targets []*Target) (int, error)
- func MaxUnavailablePartitions(partitions []Partition, targets []*Target) (int, error)
- func Summary(targets []*Target) fleet.BundleSummary
- func Unavailable(targets []*Target) (count int)
- func UpToDate(target *Target) bool
- type BundleMapping
- type Manager
- func (m *Manager) BundleFromDeployment(bd *fleet.BundleDeployment) (string, string)
- func (m *Manager) BundlesForCluster(cluster *fleet.Cluster) (bundlesToRefresh, bundlesToCleanup []*fleet.Bundle, err error)
- func (m *Manager) GetBundleDeploymentsForBundleInCluster(app *fleet.Bundle, cluster *fleet.Cluster) (result []*fleet.BundleDeployment, err error)
- func (m *Manager) Targets(fleetBundle *fleet.Bundle) (result []*Target, _ error)
- type Partition
- type Target
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ClusterGroupsToLabelMap ¶ added in v0.3.0
func ClusterGroupsToLabelMap(cgs []*fleet.ClusterGroup) map[string]map[string]string
func DeploymentLabelsForNewBundle ¶ added in v0.3.0
func DeploymentLabelsForNewBundle(app *fleet.Bundle) map[string]string
func DeploymentLabelsForSelector ¶ added in v0.3.0
func DeploymentLabelsForSelector(app *fleet.Bundle) map[string]string
func IsPartitionUnavailable ¶ added in v0.2.0
func IsPartitionUnavailable(status *fleet.PartitionStatus, targets []*Target) bool
func IsUnavailable ¶
func IsUnavailable(target *fleet.BundleDeployment) bool
func MaxUnavailable ¶
func MaxUnavailable(targets []*Target) (int, error)
func MaxUnavailablePartitions ¶ added in v0.2.0
func MaxUnavailablePartitions(partitions []Partition, targets []*Target) (int, error)
func Unavailable ¶
func Unavailable(targets []*Target) (count int)
Types ¶
type BundleMapping ¶ added in v0.3.0
type BundleMapping struct {
// contains filtered or unexported fields
}
func NewBundleMapping ¶ added in v0.3.0
func NewBundleMapping(mapping *fleet.BundleNamespaceMapping,
namespaces corecontrollers.NamespaceCache,
bundles fleetcontrollers.BundleCache) (*BundleMapping, error)
func (*BundleMapping) Bundles ¶ added in v0.3.0
func (b *BundleMapping) Bundles() ([]*fleet.Bundle, error)
func (*BundleMapping) Matches ¶ added in v0.3.0
func (b *BundleMapping) Matches(fleetBundle *fleet.Bundle) bool
func (*BundleMapping) MatchesNamespace ¶ added in v0.3.0
func (b *BundleMapping) MatchesNamespace(namespace string) bool
func (*BundleMapping) Namespaces ¶ added in v0.3.0
func (b *BundleMapping) Namespaces() ([]*corev1.Namespace, error)
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
func New ¶
func New(
clusters fleetcontrollers.ClusterCache,
clusterGroups fleetcontrollers.ClusterGroupCache,
bundles fleetcontrollers.BundleCache,
bundleNamespaceMappingCache fleetcontrollers.BundleNamespaceMappingCache,
namespaceCache corecontrollers.NamespaceCache,
contentStore manifest.Store,
bundleDeployments fleetcontrollers.BundleDeploymentCache) *Manager
func (*Manager) BundleFromDeployment ¶ added in v0.3.0
func (m *Manager) BundleFromDeployment(bd *fleet.BundleDeployment) (string, string)
func (*Manager) BundlesForCluster ¶
func (m *Manager) BundlesForCluster(cluster *fleet.Cluster) (bundlesToRefresh, bundlesToCleanup []*fleet.Bundle, err error)
func (*Manager) GetBundleDeploymentsForBundleInCluster ¶ added in v0.3.9
func (m *Manager) GetBundleDeploymentsForBundleInCluster(app *fleet.Bundle, cluster *fleet.Cluster) (result []*fleet.BundleDeployment, err error)
type Partition ¶ added in v0.2.0
type Partition struct {
Status fleet.PartitionStatus
Targets []*Target
}
func Partitions ¶ added in v0.2.0
func Partitions(targets []*Target) ([]Partition, error)
type Target ¶
type Target struct {
Deployment *fleet.BundleDeployment
ClusterGroups []*fleet.ClusterGroup
Cluster *fleet.Cluster
Bundle *fleet.Bundle
Target *fleet.BundleTarget
Options fleet.BundleDeploymentOptions
DeploymentID string
}
func (*Target) AssignNewDeployment ¶
func (t *Target) AssignNewDeployment()
Click to show internal directories.
Click to hide internal directories.