Documentation ¶
Overview ¶
Copyright 2016 Juniper Networks, Inc. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
- type Connection
- func (conn *Connection) AddVm(podName, nameSpace, containerId, hostIfName, containerIfName string) (error, error)
- func (conn *Connection) Close() error
- func (conn *Connection) DelVm(podName string) error
- func (conn *Connection) GetVmiInfo(instanceId, ifName string, delay string, count int) (*Result, error)
- type Result
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Connection ¶
type Connection struct {
// contains filtered or unexported fields
}
***************************************************************************
- Connection handling *************************************************************************** struct to hold data for a connection to VRouter Agent
func (*Connection) AddVm ¶
func (conn *Connection) AddVm(podName, nameSpace, containerId, hostIfName, containerIfName string) (error, error)
Process add of a VM. Writes config file and send message to agent
func (*Connection) Close ¶
func (conn *Connection) Close() error
***************************************************************************
- Connection handlers ***************************************************************************
func (*Connection) DelVm ¶
func (conn *Connection) DelVm(podName string) error
Process delete VM. The method ignores intermediate errors and does best * effort cleanup
func (*Connection) GetVmiInfo ¶
type Result ¶
type Result struct { Vm string `json:"vm"` Ip string `json:"ip-address"` Plen int `json:"plen"` Gw string `json:"gateway"` Dns string `json:"dns-server"` Mac string `json:"mac-address"` }
***************************************************************************
- POLL message handling ***************************************************************************