helpers

package
v0.0.0-...-300ac43 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package helpers contains helper functions to be reused by multiple routers

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Helper

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

Helper abstracts commonly used functions to be shared by any router

func New

func New(db metadata.DB, provider p2plab.NodeProvider, client *httputil.Client) *Helper

New instantiates our helper type

func (*Helper) CreateCluster

func (h *Helper) CreateCluster(ctx context.Context, cdef metadata.ClusterDefinition, name string) (metadata.Cluster, error)

CreateCluster enables creating the nodes in a cluster, waiting for them to be healthy before returning

func (*Helper) DeleteCluster

func (h *Helper) DeleteCluster(ctx context.Context, name string) error

Jump to

Keyboard shortcuts

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