cluster

package
v0.26.0 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2021 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrFailedToConnectOperator       = "cli.failed_to_connect_operator"
	ErrOperatorSocketRead            = "cli.operator_socket_read"
	ErrResponseUnknown               = "cli.response_unknown"
	ErrOperatorResponseUnknown       = "cli.operator_response_unknown"
	ErrOperatorStreamResponseUnknown = "cli.operator_stream_response_unknown"
)

Variables

This section is empty.

Functions

func Delete

func Delete(operatorConfig OperatorConfig, apiName string, keepCache bool, force bool) (schema.DeleteResponse, error)

func Deploy

func Deploy(operatorConfig OperatorConfig, configPath string, deploymentBytesMap map[string][]byte, force bool) ([]schema.DeployResult, error)

func ErrorFailedToConnectOperator

func ErrorFailedToConnectOperator(originalError error, envName string, operatorURL string) error

func ErrorOperatorResponseUnknown

func ErrorOperatorResponseUnknown(body string, statusCode int) error

func ErrorOperatorSocketRead

func ErrorOperatorSocketRead(err error) error

func ErrorOperatorStreamResponseUnknown

func ErrorOperatorStreamResponseUnknown(body string, statusCode int) error

func ErrorResponseUnknown

func ErrorResponseUnknown(body string, statusCode int) error

func GetAPI

func GetAPI(operatorConfig OperatorConfig, apiName string) ([]schema.APIResponse, error)

func GetAPIByID added in v0.23.0

func GetAPIByID(operatorConfig OperatorConfig, apiName string, apiID string) ([]schema.APIResponse, error)

func GetAPIs

func GetAPIs(operatorConfig OperatorConfig) ([]schema.APIResponse, error)

func GetGCPLogsURL added in v0.24.0

func GetGCPLogsURL(operatorConfig OperatorConfig, apiName string) (schema.GCPLogsResponse, error)

func GetJob added in v0.19.0

func GetJob(operatorConfig OperatorConfig, apiName string, jobID string) (schema.JobResponse, error)

func HTTPDelete

func HTTPDelete(operatorConfig OperatorConfig, endpoint string, qParams ...map[string]string) ([]byte, error)

func HTTPGet

func HTTPGet(operatorConfig OperatorConfig, endpoint string, qParams ...map[string]string) ([]byte, error)

func HTTPPostJSON

func HTTPPostJSON(operatorConfig OperatorConfig, endpoint string, jsonRequestData []byte, qParams ...map[string]string) ([]byte, error)

func HTTPPostNoBody

func HTTPPostNoBody(operatorConfig OperatorConfig, endpoint string, qParams ...map[string]string) ([]byte, error)

func HTTPPostObjAsJSON

func HTTPPostObjAsJSON(operatorConfig OperatorConfig, endpoint string, requestData interface{}, qParams ...map[string]string) ([]byte, error)

func HTTPUpload

func HTTPUpload(operatorConfig OperatorConfig, endpoint string, input *HTTPUploadInput, qParams ...map[string]string) ([]byte, error)

func HTTPUploadZip

func HTTPUploadZip(operatorConfig OperatorConfig, endpoint string, zipInput *archive.Input, fileName string, qParams ...map[string]string) ([]byte, error)

func Info

func Info(operatorConfig OperatorConfig) (*schema.InfoResponse, error)

func InfoGCP added in v0.24.0

func InfoGCP(operatorConfig OperatorConfig) (*schema.InfoGCPResponse, error)

func Patch added in v0.24.0

func Patch(operatorConfig OperatorConfig, configPath string, force bool) ([]schema.DeployResult, error)

func Refresh

func Refresh(operatorConfig OperatorConfig, apiName string, force bool) (schema.RefreshResponse, error)

func StopJob added in v0.19.0

func StopJob(operatorConfig OperatorConfig, apiName string, jobID string) (schema.DeleteResponse, error)

func StreamJobLogs added in v0.21.0

func StreamJobLogs(operatorConfig OperatorConfig, apiName string, jobID string) error

func StreamLogs

func StreamLogs(operatorConfig OperatorConfig, apiName string) error

Types

type HTTPUploadInput

type HTTPUploadInput struct {
	FilePaths map[string]string
	Bytes     map[string][]byte
}

type OperatorClient

type OperatorClient struct {
	*http.Client
}

type OperatorConfig

type OperatorConfig struct {
	Telemetry          bool
	ClientID           string
	EnvName            string
	OperatorEndpoint   string
	AWSAccessKeyID     string
	AWSSecretAccessKey string
}

func (OperatorConfig) AuthHeader

func (oc OperatorConfig) AuthHeader() string

Jump to

Keyboard shortcuts

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