deployment

package
v2.5.0 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2024 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AtlasDeploymentsService

type AtlasDeploymentsService interface {
	ListClusterNames(ctx context.Context, projectID string) ([]string, error)
	ListDeploymentConnections(ctx context.Context, projectID string) ([]Connection, error)
	ClusterExists(ctx context.Context, projectID, clusterName string) (bool, error)
	DeploymentIsReady(ctx context.Context, projectID, deploymentName string) (bool, error)

	GetDeployment(ctx context.Context, projectID, name string) (Deployment, error)
	CreateDeployment(ctx context.Context, deployment Deployment) (Deployment, error)
	UpdateDeployment(ctx context.Context, deployment Deployment) (Deployment, error)
	DeleteDeployment(ctx context.Context, deployment Deployment) error
	ClusterWithProcessArgs(ctx context.Context, cluster *Cluster) error
	UpdateProcessArgs(ctx context.Context, cluster *Cluster) error
}

type Cluster added in v2.5.0

type Cluster struct {
	*akov2.AdvancedDeploymentSpec
	ProjectID      string
	State          string
	MongoDBVersion string
	Connection     *status.ConnectionStrings
	ProcessArgs    *akov2.ProcessArgs
	ReplicaSet     []status.ReplicaSet
	// contains filtered or unexported fields
}

func ComputeChanges added in v2.5.0

func ComputeChanges(desired, current *Cluster) (*Cluster, bool)

func (*Cluster) GetConnection added in v2.5.0

func (c *Cluster) GetConnection() *status.ConnectionStrings

func (*Cluster) GetCustomResource added in v2.5.0

func (c *Cluster) GetCustomResource() *akov2.AtlasDeployment

func (*Cluster) GetMongoDBVersion added in v2.5.0

func (c *Cluster) GetMongoDBVersion() string

func (*Cluster) GetName added in v2.5.0

func (c *Cluster) GetName() string

func (*Cluster) GetProjectID added in v2.5.0

func (c *Cluster) GetProjectID() string

func (*Cluster) GetReplicaSet added in v2.5.0

func (c *Cluster) GetReplicaSet() []status.ReplicaSet

func (*Cluster) GetState added in v2.5.0

func (c *Cluster) GetState() string

func (*Cluster) IsServerless added in v2.5.0

func (c *Cluster) IsServerless() bool

func (*Cluster) IsTenant added in v2.5.0

func (c *Cluster) IsTenant() bool

type Connection

type Connection struct {
	Name             string
	ConnURL          string
	SrvConnURL       string
	PrivateURL       string
	SrvPrivateURL    string
	Serverless       bool
	PrivateEndpoints []PrivateEndpoint
}

type Deployment added in v2.5.0

type Deployment interface {
	GetName() string
	GetProjectID() string
	GetCustomResource() *akov2.AtlasDeployment
	GetState() string
	GetMongoDBVersion() string
	GetConnection() *status.ConnectionStrings
	GetReplicaSet() []status.ReplicaSet
	IsServerless() bool
}

func NewDeployment added in v2.5.0

func NewDeployment(projectID string, atlasDeployment *akov2.AtlasDeployment) Deployment

type Endpoint added in v2.5.0

type Endpoint struct {
	ID       string
	Provider string
	Region   string
}

type PrivateEndpoint

type PrivateEndpoint struct {
	URL       string
	ServerURL string
	ShardURL  string
	Endpoint  []Endpoint
}

type ProductionAtlasDeployments

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

func NewAtlasDeployments added in v2.5.0

func NewAtlasDeployments(clusterService admin.ClustersApi, serverlessAPI admin.ServerlessInstancesApi, isGov bool) *ProductionAtlasDeployments

func NewAtlasDeploymentsService

func NewAtlasDeploymentsService(ctx context.Context, provider atlas.Provider, secretRef *types.NamespacedName, log *zap.SugaredLogger, isGov bool) (*ProductionAtlasDeployments, error)

func (*ProductionAtlasDeployments) ClusterExists

func (ds *ProductionAtlasDeployments) ClusterExists(ctx context.Context, projectID, clusterName string) (bool, error)

func (*ProductionAtlasDeployments) ClusterWithProcessArgs added in v2.5.0

func (ds *ProductionAtlasDeployments) ClusterWithProcessArgs(ctx context.Context, cluster *Cluster) error

func (*ProductionAtlasDeployments) CreateDeployment added in v2.5.0

func (ds *ProductionAtlasDeployments) CreateDeployment(ctx context.Context, deployment Deployment) (Deployment, error)

func (*ProductionAtlasDeployments) DeleteDeployment added in v2.5.0

func (ds *ProductionAtlasDeployments) DeleteDeployment(ctx context.Context, deployment Deployment) error

func (*ProductionAtlasDeployments) DeploymentIsReady

func (ds *ProductionAtlasDeployments) DeploymentIsReady(ctx context.Context, projectID, deploymentName string) (bool, error)

func (*ProductionAtlasDeployments) GetDeployment added in v2.5.0

func (ds *ProductionAtlasDeployments) GetDeployment(ctx context.Context, projectID, name string) (Deployment, error)

func (*ProductionAtlasDeployments) ListClusterNames

func (ds *ProductionAtlasDeployments) ListClusterNames(ctx context.Context, projectID string) ([]string, error)

func (*ProductionAtlasDeployments) ListDeploymentConnections

func (ds *ProductionAtlasDeployments) ListDeploymentConnections(ctx context.Context, projectID string) ([]Connection, error)

func (*ProductionAtlasDeployments) UpdateDeployment added in v2.5.0

func (ds *ProductionAtlasDeployments) UpdateDeployment(ctx context.Context, deployment Deployment) (Deployment, error)

func (*ProductionAtlasDeployments) UpdateProcessArgs added in v2.5.0

func (ds *ProductionAtlasDeployments) UpdateProcessArgs(ctx context.Context, cluster *Cluster) error

type Serverless added in v2.5.0

type Serverless struct {
	*akov2.ServerlessSpec
	ProjectID      string
	State          string
	MongoDBVersion string
	Connection     *status.ConnectionStrings
	// contains filtered or unexported fields
}

func (*Serverless) GetConnection added in v2.5.0

func (s *Serverless) GetConnection() *status.ConnectionStrings

func (*Serverless) GetCustomResource added in v2.5.0

func (s *Serverless) GetCustomResource() *akov2.AtlasDeployment

func (*Serverless) GetMongoDBVersion added in v2.5.0

func (s *Serverless) GetMongoDBVersion() string

func (*Serverless) GetName added in v2.5.0

func (s *Serverless) GetName() string

func (*Serverless) GetProjectID added in v2.5.0

func (s *Serverless) GetProjectID() string

func (*Serverless) GetReplicaSet added in v2.5.0

func (s *Serverless) GetReplicaSet() []status.ReplicaSet

func (*Serverless) GetState added in v2.5.0

func (s *Serverless) GetState() string

func (*Serverless) IsServerless added in v2.5.0

func (s *Serverless) IsServerless() bool

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳