persist

package
v0.0.0-...-bbd41d0 Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2015 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Controller

type Controller interface {
	Create(string, string, bool) (*Reply, error)
	Delete(string, bool) (*Reply, error)
	Read(string) (*Reply, error)
	CreatePath(string) (*Reply, error)
	Exists(string) (bool, error)
}

func NewController

func NewController(options *ControllerOptions) (Controller, error)

type ControllerOptions

type ControllerOptions struct {
	Type  string
	Nodes []string
}

type EtcdController

type EtcdController struct {
	Nodes []string
	// contains filtered or unexported fields
}

func NewEtcdController

func NewEtcdController(options *ControllerOptions) (*EtcdController, error)

func (*EtcdController) Create

func (e *EtcdController) Create(path string, value string, update bool) (*Reply, error)

func (*EtcdController) CreatePath

func (e *EtcdController) CreatePath(path string) (*Reply, error)

func (*EtcdController) Delete

func (e *EtcdController) Delete(path string, recursive bool) (*Reply, error)

func (*EtcdController) Exists

func (e *EtcdController) Exists(path string) (bool, error)

func (*EtcdController) Read

func (e *EtcdController) Read(path string) (*Reply, error)

type Reply

type Reply struct {
	Location    string
	Value       string
	TransID     uint64
	HasChildren bool
	Children    []string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL