kuma

package
v0.3.6 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2020 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrOpInvalid = errors.New(errors.ErrOpInvalid, "Invalid operation")
)

Functions

func ErrClientConfig added in v0.2.0

func ErrClientConfig(err error) error

ErrClientConfig is the error for setting client config

func ErrClientSet added in v0.2.0

func ErrClientSet(err error) error

ErrPortForward is the error for setting clientset

func ErrInstallMesh

func ErrInstallMesh(err error) error

ErrInstallMesh is the error for install mesh

func ErrMeshConfig

func ErrMeshConfig(err error) error

ErrMeshConfig is the error for mesh config

func ErrPortForward

func ErrPortForward(err error) error

ErrPortForward is the error for mesh port forward

func ErrStreamEvent added in v0.2.0

func ErrStreamEvent(err error) error

ErrStreamEvent is the error for streaming event

Types

type Event added in v0.2.0

type Event struct {
	Operationid string `json:"operationid,omitempty"`
	EType       int32  `json:"type,string,omitempty"`
	Summary     string `json:"summary,omitempty"`
	Details     string `json:"details,omitempty"`
}

type Handler

type Handler interface {
	GetName() string
	CreateInstance([]byte, string, *chan interface{}) error
	ApplyOperation(context.Context, string, string, bool) error
	ListOperations() (Operations, error)

	StreamErr(*Event, error)
	StreamInfo(*Event)
}

Handler provides the methods supported by the adapter

func AddLogger added in v0.3.0

func AddLogger(logger logger.Handler, h Handler) Handler

func New

New initializes email handler.

type MeshInstance

type MeshInstance struct {
	InstallMode     string `json:"installmode,omitempty"`
	InstallPlatform string `json:"installplatform,omitempty"`
	InstallZone     string `json:"installzone,omitempty"`
	InstallVersion  string `json:"installversion,omitempty"`
	MgmtAddr        string `json:"mgmtaddr,omitempty"`
	Kumaaddr        string `json:"kumaaddr,omitempty"`
}

MeshInstance holds the information of the instance of the mesh

type Operation

type Operation struct {
	Type       int32             `json:"type,string,omitempty"`
	Properties map[string]string `json:"properties,omitempty"`
}

Operation holds the informormation for list of operations

type Operations

type Operations map[string]*Operation

Operations hold a map of Operation objects

type Spec

type Spec struct {
	Name    string `json:"name"`
	Status  string `json:"status"`
	Version string `json:"version"`
}

Spec holds the specifications for kuma adapter

Jump to

Keyboard shortcuts

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