consul

package
v0.0.0-...-d591cd7 Latest Latest
Warning

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

Go to latest
Published: Jan 9, 2017 License: MIT Imports: 6 Imported by: 2

Documentation

Index

Constants

View Source
const VERSION string = "0.2"

Version

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config api.Config

Consul Config representation

func DefaultConfig

func DefaultConfig() Config

Convert api.DefaultConfig to Config

type Consul

type Consul struct {
	*api.Client
}

func New

func New(src Config) (consul *Consul, err error)

Creates new consul api instance according to the configuration was received

func (*Consul) GetAll

func (c *Consul) GetAll() (services []*hubble.Service, err error)

Return Services list

type ConsulKV

type ConsulKV struct {
	*api.KV
}

func NewKV

func NewKV(consul *Consul) *ConsulKV

Returns new instance of the KV

func (*ConsulKV) GetParams

func (c *ConsulKV) GetParams(key string) (p *hubble.ServiceParams, err error)

Returns values from the KV

Jump to

Keyboard shortcuts

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