Documentation ¶
Index ¶
- Constants
- type Service
- func (service *Service) BucketName() string
- func (service *Service) Create(id portainer.EdgeStackID, edgeStack *portainer.EdgeStack) error
- func (service *Service) DeleteEdgeStack(ID portainer.EdgeStackID) error
- func (service *Service) EdgeStack(ID portainer.EdgeStackID) (*portainer.EdgeStack, error)
- func (service *Service) EdgeStackVersion(ID portainer.EdgeStackID) (int, bool)
- func (service *Service) EdgeStacks() ([]portainer.EdgeStack, error)
- func (service *Service) GetNextIdentifier() int
- func (service *Service) UpdateEdgeStack(ID portainer.EdgeStackID, edgeStack *portainer.EdgeStack) errordeprecated
- func (service *Service) UpdateEdgeStackFunc(ID portainer.EdgeStackID, updateFunc func(edgeStack *portainer.EdgeStack)) error
Constants ¶
View Source
const (
// BucketName represents the name of the bucket where this service stores data.
BucketName = "edge_stack"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service represents a service for managing Edge stack data.
func NewService ¶
func NewService(connection portainer.Connection, cacheInvalidationFn func(portainer.EdgeStackID)) (*Service, error)
NewService creates a new instance of a service.
func (*Service) BucketName ¶
func (*Service) DeleteEdgeStack ¶
func (service *Service) DeleteEdgeStack(ID portainer.EdgeStackID) error
DeleteEdgeStack deletes an Edge stack.
func (*Service) EdgeStackVersion ¶
func (service *Service) EdgeStackVersion(ID portainer.EdgeStackID) (int, bool)
EdgeStackVersion returns the version of the given edge stack ID directly from an in-memory index
func (*Service) EdgeStacks ¶
EdgeStacks returns an array containing all edge stacks
func (*Service) GetNextIdentifier ¶
GetNextIdentifier returns the next identifier for an environment(endpoint).
func (*Service) UpdateEdgeStack
deprecated
func (*Service) UpdateEdgeStackFunc ¶
func (service *Service) UpdateEdgeStackFunc(ID portainer.EdgeStackID, updateFunc func(edgeStack *portainer.EdgeStack)) error
UpdateEdgeStackFunc updates an Edge stack inside a transaction avoiding data races.
Click to show internal directories.
Click to hide internal directories.