consul

package
v0.33.0 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package consul exposes a Consul service and client.

Index

Constants

View Source
const (
	// ServiceName is the advertised name of this service.
	ServiceName = "consul"
)

Variables

This section is empty.

Functions

func NewComponent

NewComponent creates a new Consul component.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client is a Consul client.

func NewClient

func NewClient(address string) (Client, error)

NewClient creates a new Client.

func (Client) Delete

func (c Client) Delete(key string) error

Delete removes a value.

func (Client) DeleteTree

func (c Client) DeleteTree(prefix string) error

DeleteTree removes values under a prefix.

func (Client) Live

func (c Client) Live() error

Live is a liveness check.

func (Client) Put

func (c Client) Put(key, value string) error

Put stores a value.

Jump to

Keyboard shortcuts

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