Documentation ¶
Overview ¶
Package etcd provides etcd backend implementation for storing PodRegistry, ControllerRegistry and ServiceRegistry api objects.
Index ¶
- Constants
- func MakeEtcdItemKey(ctx api.Context, prefix string, id string) (string, error)
- func MakeEtcdListKey(ctx api.Context, prefix string) string
- type Registry
- func (r *Registry) CreateService(ctx api.Context, svc *api.Service) (*api.Service, error)
- func (r *Registry) DeleteService(ctx api.Context, name string) error
- func (r *Registry) GetService(ctx api.Context, name string) (*api.Service, error)
- func (r *Registry) ListServices(ctx api.Context) (*api.ServiceList, error)
- func (r *Registry) UpdateService(ctx api.Context, svc *api.Service) (*api.Service, error)
- func (r *Registry) WatchServices(ctx api.Context, label labels.Selector, field fields.Selector, ...) (watch.Interface, error)
Constants ¶
const ( // ServicePath is the path to service resources in etcd ServicePath string = "/services/specs" )
Variables ¶
This section is empty.
Functions ¶
func MakeEtcdItemKey ¶ added in v0.5.1
MakeEtcdItemKey constructs etcd paths to a resource relative to prefix enforcing namespace rules. If no namespace is on context, it errors.
Types ¶
type Registry ¶
type Registry struct { tools.EtcdHelper // contains filtered or unexported fields }
Registry implements BindingRegistry, ControllerRegistry, EndpointRegistry, MinionRegistry, PodRegistry and ServiceRegistry, backed by etcd.
func NewRegistry ¶
NewRegistry creates an etcd registry.
func (*Registry) CreateService ¶
CreateService creates a new Service.
func (*Registry) DeleteService ¶
DeleteService deletes a Service specified by its name.
func (*Registry) GetService ¶
GetService obtains a Service specified by its name.
func (*Registry) ListServices ¶
ListServices obtains a list of Services.
func (*Registry) UpdateService ¶
UpdateService replaces an existing Service.