etcdtest

package
v0.9.117 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2017 License: Apache-2.0, MIT Imports: 10 Imported by: 0

Documentation

Overview

Package etcdtest implements an easy startup script to start a local etcd instance for testing purpose.

Index

Constants

This section is empty.

Variables

View Source
var Urls []string

Functions

func DeleteAll

func DeleteAll() error

Deletes the 'routes' directory from etcd with the prefix '/skippertest'.

func DeleteAllFrom

func DeleteAllFrom(prefix string) error

Deletes the 'routes' directory with the specified prefix.

func DeleteData

func DeleteData(key string) error

Deletes a route from etcd with the prefix '/skippertest'.

func DeleteDataFrom

func DeleteDataFrom(prefix, key string) error

Deletes a route from etcd with the specified prefix.

func GetNode

func GetNode(key string) (string, error)

Loads an etcd route node from the prefix '/skippertest'.

func GetNodeFrom

func GetNodeFrom(prefix, key string) (string, error)

Loads an etcd route node from the specified prefix.

func PutData

func PutData(key, data string) error

Saves a route in etcd with the prefix '/skippertest'.

func PutDataTo

func PutDataTo(prefix, key, data string) error

Saves a route in etcd with the specified prefix.

func ResetData

func ResetData() error

Deletes all routes in etcd and creates a test route under the prefix '/skippertest'.

func ResetDataIn

func ResetDataIn(prefix string) error

Deletes all routes in etcd and creates a test route under the specified prefix.

func Start

func Start() error

Starts an etcd server.

func Stop

func Stop() error

Types

This section is empty.

Jump to

Keyboard shortcuts

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