client

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2019 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ResourceClient

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

ResourceClient interacts with the cluster and performs resource operations

func NewResourceClient

func NewResourceClient(config *rest.Config) (*ResourceClient, error)

NewResourceClient creates a new ResourceClient

func (*ResourceClient) AutoWatchByRef

func (rc *ResourceClient) AutoWatchByRef(refs []*common.ResourceRef, timeout time.Duration) ([]*WatchResult, error)

AutoWatchByRef automatically watches a list of resources identified by ResourceRef. Only supported types of resources are watched, others are ignored.

func (*ResourceClient) Create

func (rc *ResourceClient) Create(resources []*unstructured.Unstructured, numCopies int) ([]*common.ResourceRef, error)

Create creates a list of resources to k8s cluster

type WatchResult

type WatchResult struct {
	ResourceRef *common.ResourceRef               `json:"resourceRef"`
	Status      condition.ResourceConditionStatus `json:"status"`
	Error       error                             `json:"-"`
}

WatchResult is the result of auto-watch

Jump to

Keyboard shortcuts

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