Documentation
¶
Index ¶
- type Coordinator
- func (c *Coordinator) Capability(ctx context.Context, scope coord.Scope) (*coord.Capability, error)
- func (c *Coordinator) Snapshot(ctx context.Context, scope coord.Scope) (*coord.Snapshot, error)
- func (c *Coordinator) TryAcquireWriteLease(ctx context.Context, scope coord.Scope) (coord.WriteLease, bool, error)
- func (c *Coordinator) WaitAcquireWriteLease(ctx context.Context, scope coord.Scope) (coord.WriteLease, error)
- func (c *Coordinator) Watch(ctx context.Context, scope coord.Scope, afterGeneration uint64) (coord.Watch, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Coordinator ¶
type Coordinator struct {
// contains filtered or unexported fields
}
Coordinator coordinates ObjectStore access within one process.
func ForVolume ¶
func ForVolume(volumeID string) *Coordinator
ForVolume returns the process-local coordinator for a Volume id.
func NewCoordinator ¶
func NewCoordinator() *Coordinator
NewCoordinator builds an in-memory coordinator.
func (*Coordinator) Capability ¶
func (c *Coordinator) Capability(ctx context.Context, scope coord.Scope) (*coord.Capability, error)
Capability reports in-memory coordination support.
func (*Coordinator) TryAcquireWriteLease ¶
func (c *Coordinator) TryAcquireWriteLease(ctx context.Context, scope coord.Scope) (coord.WriteLease, bool, error)
TryAcquireWriteLease attempts to acquire the logical write lease.
func (*Coordinator) WaitAcquireWriteLease ¶
func (c *Coordinator) WaitAcquireWriteLease(ctx context.Context, scope coord.Scope) (coord.WriteLease, error)
WaitAcquireWriteLease waits until the logical write lease is available.
Click to show internal directories.
Click to hide internal directories.