client

package
v1.5.2-dev Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2019 License: Apache-2.0 Imports: 22 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package client enables handler code to easily and consistently validate and dispatch calls to lib/install.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Executor

type Executor interface {
	CreateVCH(conf *config.VirtualContainerHostConfigSpec, settings *data.InstallerData, receiver vchlog.Receiver) error
	DeleteVCH(conf *config.VirtualContainerHostConfigSpec, containers *management.DeleteContainers, volumeStores *management.DeleteVolumeStores) error
}

type Finder

type Finder interface {
	Element(context.Context, types.ManagedObjectReference) (*list.Element, error)
}

type HandlerClient

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

func NewHandlerClient

func NewHandlerClient(op trace.Operation, action management.Action, finder *find.Finder, session *session.Session, validator *validate.Validator) (*HandlerClient, error)

func (*HandlerClient) Executor

func (c *HandlerClient) Executor() Executor

func (*HandlerClient) Finder

func (c *HandlerClient) Finder() Finder

func (*HandlerClient) GetAddresses

func (c *HandlerClient) GetAddresses(vchConfig *config.VirtualContainerHostConfigSpec) (string, string, error)

func (*HandlerClient) GetConfigForVCH

func (*HandlerClient) GetDatastoreHelper

func (c *HandlerClient) GetDatastoreHelper(op trace.Operation, d *data.Data) (*datastore.Helper, error)

GetDatastoreHelper validates the VCH and returns the datastore helper for the VCH. It errors when validation fails or when datastore is not ready

func (*HandlerClient) GetVCH

func (c *HandlerClient) GetVCH(op trace.Operation, d *data.Data) (*vm.VirtualMachine, error)

func (*HandlerClient) GetVCHConfig

func (*HandlerClient) GetVCHs

func (c *HandlerClient) GetVCHs(op trace.Operation) ([]*vm.VirtualMachine, error)

func (*HandlerClient) Validator

func (c *HandlerClient) Validator() Validator

type Validator

type Validator interface {
	Validate(ctx context.Context, input *data.Data, allowEmptyDC bool) (*config.VirtualContainerHostConfigSpec, error)
	GetIssues() []error

	// TODO (#6032): This probably doesn't belong here.
	AddDeprecatedFields(ctx context.Context, conf *config.VirtualContainerHostConfigSpec, input *data.Data) *data.InstallerData
}

Jump to

Keyboard shortcuts

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