Documentation ¶
Index ¶
- type ConstellationInfo
- type GroupInfo
- type Host
- type ISL
- type Link
- type MachineConfig
- type MachineID
- type MachineState
- type MachinesState
- type NetworkState
- type NodeIDInfo
- type NodeInfo
- type Orchestrator
- func (o *Orchestrator) GetResources() (availcpus uint32, availram uint64, err error)
- func (o *Orchestrator) InfoGetConstellation() (ConstellationInfo, error)
- func (o *Orchestrator) InfoGetGroup(group uint8) (GroupInfo, error)
- func (o *Orchestrator) InfoGetIPAddressByID(id MachineID) (net.IP, error)
- func (o *Orchestrator) InfoGetIPAddressByName(name string) (net.IP, error)
- func (o *Orchestrator) InfoGetNodeByID(id MachineID) (NodeInfo, error)
- func (o *Orchestrator) InfoGetNodeByIP(ip net.IP) (NodeInfo, error)
- func (o *Orchestrator) InfoGetNodeByName(name string) (NodeInfo, error)
- func (o *Orchestrator) InfoGetNodeNameByID(id MachineID) (string, error)
- func (o *Orchestrator) InfoGetPath(source, destination MachineID) (PathInfo, error)
- func (o *Orchestrator) Initialize(machineList map[MachineID]MachineConfig, machineHosts map[MachineID]Host, ...) error
- func (o *Orchestrator) Stop() error
- func (o *Orchestrator) Update(s *State) error
- type PathInfo
- type SegmentInfo
- type State
- type VirtualizationBackend
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConstellationInfo ¶ added in v0.2.0
type ConstellationInfo struct {
Groups []GroupInfo
}
type Link ¶ added in v0.2.0
type MachineConfig ¶ added in v0.2.0
type MachineState ¶ added in v0.2.0
type MachineState uint8
const ( STOPPED MachineState = iota ACTIVE )
type MachinesState ¶ added in v0.2.0
type MachinesState map[MachineID]MachineState
type NetworkState ¶ added in v0.2.0
func (NetworkState) String ¶ added in v0.2.0
func (n NetworkState) String() string
type NodeIDInfo ¶ added in v0.2.0
type NodeInfo ¶ added in v0.2.0
type NodeInfo struct { ID NodeIDInfo Active bool }
type Orchestrator ¶
type Orchestrator struct { // State is the description of the desired state of the emulation (as determined by simulation) State // contains filtered or unexported fields }
func New ¶
func New(vb VirtualizationBackend) *Orchestrator
func (*Orchestrator) GetResources ¶ added in v0.2.0
func (o *Orchestrator) GetResources() (availcpus uint32, availram uint64, err error)
func (*Orchestrator) InfoGetConstellation ¶ added in v0.2.0
func (o *Orchestrator) InfoGetConstellation() (ConstellationInfo, error)
func (*Orchestrator) InfoGetGroup ¶ added in v0.2.0
func (o *Orchestrator) InfoGetGroup(group uint8) (GroupInfo, error)
func (*Orchestrator) InfoGetIPAddressByID ¶ added in v0.2.0
func (o *Orchestrator) InfoGetIPAddressByID(id MachineID) (net.IP, error)
func (*Orchestrator) InfoGetIPAddressByName ¶ added in v0.2.0
func (o *Orchestrator) InfoGetIPAddressByName(name string) (net.IP, error)
func (*Orchestrator) InfoGetNodeByID ¶ added in v0.2.0
func (o *Orchestrator) InfoGetNodeByID(id MachineID) (NodeInfo, error)
func (*Orchestrator) InfoGetNodeByIP ¶ added in v0.2.0
func (o *Orchestrator) InfoGetNodeByIP(ip net.IP) (NodeInfo, error)
func (*Orchestrator) InfoGetNodeByName ¶ added in v0.2.0
func (o *Orchestrator) InfoGetNodeByName(name string) (NodeInfo, error)
func (*Orchestrator) InfoGetNodeNameByID ¶ added in v0.2.0
func (o *Orchestrator) InfoGetNodeNameByID(id MachineID) (string, error)
func (*Orchestrator) InfoGetPath ¶ added in v0.2.0
func (o *Orchestrator) InfoGetPath(source, destination MachineID) (PathInfo, error)
func (*Orchestrator) Initialize ¶ added in v0.2.0
func (o *Orchestrator) Initialize(machineList map[MachineID]MachineConfig, machineHosts map[MachineID]Host, machineNames map[MachineID]string) error
func (*Orchestrator) Stop ¶ added in v0.2.0
func (o *Orchestrator) Stop() error
func (*Orchestrator) Update ¶ added in v0.2.0
func (o *Orchestrator) Update(s *State) error
type SegmentInfo ¶ added in v0.2.0
type State ¶ added in v0.2.0
type State struct { NetworkState MachinesState }
type VirtualizationBackend ¶ added in v0.2.0
type VirtualizationBackend interface { RegisterMachine(machine MachineID, name string, host Host, config MachineConfig) error BlockLink(source MachineID, target MachineID) error UnblockLink(source MachineID, target MachineID) error SetLatency(source MachineID, target MachineID, latency uint32) error SetBandwidth(source MachineID, target MachineID, bandwidth uint64) error StopMachine(machine MachineID) error StartMachine(machine MachineID) error GetIPAddress(id MachineID) (net.IPNet, error) ResolveIPAddress(ip net.IP) (MachineID, error) Stop() error }
Click to show internal directories.
Click to hide internal directories.