Documentation ¶
Index ¶
- func AddCACert(path string, roots *x509.CertPool) *x509.CertPool
- func AgentServiceToCatalogService(as *api.AgentService, client *api.Client) (*api.CatalogService, error)
- func CatalogNodeGetService(cn *api.CatalogNode, serviceName string) *api.AgentService
- func Contains(s []*api.ServiceEntry, e *api.CatalogService) bool
- func GetCatalog(config *store.ConsulConfig) *api.Catalog
- func GetClient(config *store.ConsulConfig) *api.Client
- func GetConsulApiEntryPoint(registrar *Registrar) *api.CatalogService
- func GetConsulConnection(c *store.ConsulConfig) (client *api.Client, bkup *kvJSON, err error)
- func LoadSystemRootCAs() (systemRoots *x509.CertPool, err error)
- func MakeACLClient() *api.Client
- func MakeClient() *api.Client
- func MakeClientWithConfig(cb1 configCallback) *api.Client
- func NodeToAgent(registrar *Registrar, node string) *api.CatalogNode
- func QueryService(name string, catalog *api.Catalog) ([]*api.CatalogService, error)
- func QueryServiceByID(serviceID string, client *api.Client) (res *api.AgentService, err error)
- func WaitForResult(try testFn, fail errorFn)
- type Base
- type Registrar
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AgentServiceToCatalogService ¶
func AgentServiceToCatalogService(as *api.AgentService, client *api.Client) (*api.CatalogService, error)
func CatalogNodeGetService ¶
func CatalogNodeGetService(cn *api.CatalogNode, serviceName string) *api.AgentService
func Contains ¶
func Contains(s []*api.ServiceEntry, e *api.CatalogService) bool
Contains is a helper function to test if a `api.ServiceEntry` array contains a `api.CatalogService`
func GetCatalog ¶
func GetCatalog(config *store.ConsulConfig) *api.Catalog
func GetConsulApiEntryPoint ¶
func GetConsulApiEntryPoint(registrar *Registrar) *api.CatalogService
func GetConsulConnection ¶
func GetConsulConnection(c *store.ConsulConfig) (client *api.Client, bkup *kvJSON, err error)
func LoadSystemRootCAs ¶
func MakeACLClient ¶
func MakeClient ¶
func MakeClientWithConfig ¶
func NodeToAgent ¶
func NodeToAgent(registrar *Registrar, node string) *api.CatalogNode
func QueryService ¶
func QueryServiceByID ¶
func WaitForResult ¶
func WaitForResult(try testFn, fail errorFn)
Types ¶
type Registrar ¶
type Registrar struct { Base Clients []*api.CatalogService CurrentClient *api.CatalogService }
func GetRegistrar ¶
func GetRegistrar(config *store.ConsulConfig) *Registrar
Click to show internal directories.
Click to hide internal directories.