package v1

import "github.com/coreos/etcd/server/v1"

Index

Functions

func DeleteKeyHandler

func DeleteKeyHandler(w http.ResponseWriter, req *http.Request, s Server) error

Removes a key from the store.

func GetKeyHandler

func GetKeyHandler(w http.ResponseWriter, req *http.Request, s Server) error

Retrieves the value for a given key.

func SetKeyHandler

func SetKeyHandler(w http.ResponseWriter, req *http.Request, s Server) error

Sets the value for a given key.

func WatchKeyHandler

func WatchKeyHandler(w http.ResponseWriter, req *http.Request, s Server) error

Watches a given key prefix for changes.

Types

type Server

type Server interface {
	CommitIndex() uint64
	Term() uint64
	Store() store.Store
	Dispatch(raft.Command, http.ResponseWriter, *http.Request) error
}

The Server interface provides all the methods required for the v1 API.

Source Files

delete_key_handler.go get_key_handler.go set_key_handler.go v1.go watch_key_handler.go

Directories

PathSynopsis
server/v1/tests
Version
v0.4.0
Published
May 21, 2014
Platform
linux/amd64
Imports
7 packages
Last checked
9 minutes ago

Tools for package owners.