mocks

package
v0.0.0-...-1c5d739 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AssignmentHandler

type AssignmentHandler struct {
	mock.Mock
}

func (*AssignmentHandler) Assign

func (_m *AssignmentHandler) Assign(poolID, ipAddress, netmask, binding string) error

func (*AssignmentHandler) Unassign

func (_m *AssignmentHandler) Unassign(poolID, ipAddress string) error

type Connection

type Connection struct {
	mock.Mock
}

func (*Connection) Children

func (_m *Connection) Children(p string) (children []string, err error)

func (*Connection) ChildrenW

func (_m *Connection) ChildrenW(path string, done <-chan struct{}) (children []string, event <-chan client.Event, err error)

func (*Connection) Close

func (_m *Connection) Close()

func (*Connection) Create

func (_m *Connection) Create(path string, node client.Node) error

func (*Connection) CreateDir

func (_m *Connection) CreateDir(path string) error

func (*Connection) CreateEphemeral

func (_m *Connection) CreateEphemeral(path string, node client.Node) (string, error)

func (*Connection) CreateEphemeralIfExists

func (_m *Connection) CreateEphemeralIfExists(path string, node client.Node) (string, error)

func (*Connection) CreateIfExists

func (_m *Connection) CreateIfExists(path string, node client.Node) error

func (*Connection) Delete

func (_m *Connection) Delete(path string) error

func (*Connection) EnsurePath

func (_m *Connection) EnsurePath(path string) error

func (*Connection) Exists

func (_m *Connection) Exists(path string) (bool, error)

func (*Connection) ExistsW

func (_m *Connection) ExistsW(path string, done <-chan struct{}) (bool, <-chan client.Event, error)

func (*Connection) Get

func (_m *Connection) Get(path string, node client.Node) error

func (*Connection) GetW

func (_m *Connection) GetW(path string, node client.Node, done <-chan struct{}) (<-chan client.Event, error)

func (*Connection) ID

func (_m *Connection) ID() int

func (*Connection) NewLeader

func (_m *Connection) NewLeader(path string) (client.Leader, error)

func (*Connection) NewLock

func (_m *Connection) NewLock(path string) (client.Lock, error)

func (*Connection) NewTransaction

func (_m *Connection) NewTransaction() client.Transaction

func (*Connection) Set

func (_m *Connection) Set(path string, node client.Node) error

func (*Connection) SetID

func (_m *Connection) SetID(_a0 int)

func (*Connection) SetOnClose

func (_m *Connection) SetOnClose(_a0 func(int))

type HostIPHandler

type HostIPHandler struct {
	mock.Mock
}

func (*HostIPHandler) BindIP

func (_m *HostIPHandler) BindIP(ip string, netmask string, iface string) error

func (*HostIPHandler) ReleaseIP

func (_m *HostIPHandler) ReleaseIP(ip string) error

type HostSelectionStrategy

type HostSelectionStrategy struct {
	mock.Mock
}

func (*HostSelectionStrategy) Select

func (_m *HostSelectionStrategy) Select(hosts []host.Host) (host.Host, error)

type HostStateHandler

type HostStateHandler struct {
	mock.Mock
}

func (*HostStateHandler) AttachContainer

func (_m *HostStateHandler) AttachContainer(state *service.ServiceState, serviceID string, instanceID int) (<-chan time.Time, error)

func (*HostStateHandler) PauseContainer

func (_m *HostStateHandler) PauseContainer(serviceID string, instanceID int) error

func (*HostStateHandler) RestartContainer

func (_m *HostStateHandler) RestartContainer(cancel <-chan interface{}, serviceID string, instanceID int) error

func (*HostStateHandler) ResumeContainer

func (_m *HostStateHandler) ResumeContainer(serviceID string, instanceID int) error

func (*HostStateHandler) StartContainer

func (_m *HostStateHandler) StartContainer(cancel <-chan interface{}, serviceID string, instanceID int) (*service.ServiceState, <-chan time.Time, error)

func (*HostStateHandler) StopContainer

func (_m *HostStateHandler) StopContainer(serviceID string, instanceID int) error

type HostUnassignmentHandler

type HostUnassignmentHandler struct {
	mock.Mock
}

func (*HostUnassignmentHandler) UnAssignAll

func (_m *HostUnassignmentHandler) UnAssignAll(poolID, hostID string) error

type RegisteredHostHandler

type RegisteredHostHandler struct {
	mock.Mock
}

func (*RegisteredHostHandler) GetRegisteredHosts

func (_m *RegisteredHostHandler) GetRegisteredHosts(pool string) ([]host.Host, error)

type ServiceHandler

type ServiceHandler struct {
	mock.Mock
}

func (*ServiceHandler) SelectHost

func (_m *ServiceHandler) SelectHost(_a0 *service.ServiceNode) (string, error)

type VirtualIPSynchronizer

type VirtualIPSynchronizer struct {
	mock.Mock
}

func (*VirtualIPSynchronizer) Sync

func (_m *VirtualIPSynchronizer) Sync(resourcePool pool.ResourcePool, assignments map[string]string) error

type VirtualIPUnassignmentHandler

type VirtualIPUnassignmentHandler struct {
	mock.Mock
}

func (*VirtualIPUnassignmentHandler) UnassignAll

func (_m *VirtualIPUnassignmentHandler) UnassignAll(poolID, hostID string) error

Jump to

Keyboard shortcuts

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