vppagent

package module
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Sep 5, 2017 License: Apache-2.0 Imports: 0 Imported by: 0

README

VPP Agent

Build Status Coverage Status Go Report Card GoDoc GitHub license

Please note that the content of this repository is currently WORK IN PROGRESS.

The VPP Agent is a Golang implementation of a control/management plane for VPP based cloud-native Virtual Network Functions (VNFs). The VPP Agent is built on top of the CN-Infra platform for developing cloud-native Virtual Network Functions (VNFs).

The VPP Agent can be used as-is as a management/control agent for VNFs based on off-the-shelf VPP (for example, a VPP-based vswitch), or as a platform for developing customized VNFs with customized VPP-based data.

Architecture

The VPP Agent is basically a set of VPP-specific plugins that use the CN-Infra platform to interact with other services / microservices in the cloud (e.g. a KV data store, messaging, log warehouse, etc.). The VPP Agent exposes VPP functionality to client apps via a higher-level model-driven API. Clients that consume this API may be either external (connecting to the VPP Agent via REST, gRPC API, Etcd or message bus transport), or local Apps and/or Extension plugins running on the same CN-Infra platform in the same Linux process.

The VNF Agent architecture is shown in the following figure:

vpp agent

Each (northbound) VPP API - L2, L3, ACL, ... - is implemented by a specific VNF Agent plugin, which translates northbound API calls/operations into (southbound) low level VPP Binary API calls. Northbound APIs are defined using protobufs, which allow for the same functionality to be accessible over multiple transport protocols (HTTP, gRPC, Etcd, ...). Plugins use the GoVPP library to interact with the VPP.

The following figure shows the VPP Agent in context of a cloud-native VNF, where the VNF's data plane is implemented using VPP/DPDK and its management / control planes are implemented using the VNF agent:

context

Plugins

The set of plugins in the VPP Agent is as follows:

  • Default VPP Plugins - plugins providing northbound APIs to "default" VPP functionality (i.e. VPP functions available "out-of-the-box"):
    • NET Interfaces - network interface configuration (PCI Ethernet, MEMIF, AF_Packet, VXLAN, Loopback...) + BFD
    • L2 - Bridge Domains, L2 cross-connects
    • L3 - IP Routes, VRFs...
    • ACL - VPP access lists (VPP ACL plugin)
  • GOVPPmux - plugin wrapper around GoVPP. Multiplexes plugins' access to VPP on a single connection.
  • Linux (VETH) - allows optional configuration of Linux virtual ethernet interfaces
  • CN-Infra datasync - data synchronization after HA events
  • CN-Infra core - lifecycle management of plugins (loading, initialization, unloading)

Tools

The VPP agent repository also contains tools for building and troubleshooting of VNFs based on the VPP Agent:

  • agentctl - a CLI tool that shows the state of a set of VPP agents can configure the agents
  • vpp-agent-ctl - a utility for testing VNF Agent configuration. It contains a set of pre-defined configurations that can be sent to the VPP Agent either interactively or in a script.
  • docker - container-based development environment for the VPP agent and for app/extension plugins.

Quickstart

For a quick start with the VPP Agent, you can use pre-built Docker images with the Agent and VPP on Dockerhub.

  1. Start ETCD and Kafka on your host (e.g. in Docker as described here). Note: The Agent in the pre-built Docker image will not start if it can't connect to both Etcd and Kafka.

  2. Run VPP + VPP Agent in a Docker image:

docker pull ligato/vpp-agent
docker run -it --name vpp --rm ligato/vpp-agent
  1. Configure the VPP agent using agentctl:
docker exec -it vpp agentctl -h
  1. Check the configuration (using agentctl or directly using VPP console):
docker exec -it vpp agentctl -e 172.17.0.1:2379 show
docker exec -it vpp vppctl

Documentation

GoDoc can be browsed online.

Next Steps

Read the README for the Development Docker Image for more details.

Deployment:

K8s integration

Extensibility:

VPP Agent Extensibility

Design & architecture:

VPP agent 10.000 feet

Contribution:

If you are interested in contributing, please see the contribution guidelines.

Documentation

Overview

Package vppagent is a cloud-native management tool for VPP (FD.io Vector Packet Processing) built on cn-infra framework.

Directories

Path Synopsis
clientv1
cmd
Package cmd is the parent for packages that are used to build various executables from vpp-agent sources.
Package cmd is the parent for packages that are used to build various executables from vpp-agent sources.
agentctl
package agentctl contains the agentctl tool for monitoring and configuring of VPP Agents.
package agentctl contains the agentctl tool for monitoring and configuring of VPP Agents.
agentctl/cmd
Package cmd implements the command line interface (CLI) for the agentctl tool.
Package cmd implements the command line interface (CLI) for the agentctl tool.
agentctl/utils
Package utils provides utility functions used in agentctl commands.
Package utils provides utility functions used in agentctl commands.
vpp-agent
Package vpp-agent implements the main entry point into the VPP Agent, and it is used to build the VPP Agent executable.
Package vpp-agent implements the main entry point into the VPP Agent, and it is used to build the VPP Agent executable.
vpp-agent-ctl
package vpp-agent-ctl implements the vpp-agent-ctl test tool for testing of VPP Agent plugins.
package vpp-agent-ctl implements the vpp-agent-ctl test tool for testing of VPP Agent plugins.
examples
flavors
vpp
persist
Package persist asynchronously writes changes in the map (name->idx) to file.
Package persist asynchronously writes changes in the map (name->idx) to file.
plugins
defaultplugins/aclplugin
Package aclplugin implements the ACL Plugin.
Package aclplugin implements the ACL Plugin.
defaultplugins/aclplugin/bin_api
Package binapi defines the aclplugin's southbound API.
Package binapi defines the aclplugin's southbound API.
defaultplugins/aclplugin/bin_api/acl
Package acl represents the VPP binary API of the 'acl' VPP module.
Package acl represents the VPP binary API of the 'acl' VPP module.
defaultplugins/aclplugin/model
Package model defines the acplugin's northbound API.
Package model defines the acplugin's northbound API.
defaultplugins/aclplugin/model/acl
Package acl is a generated protocol buffer package.
Package acl is a generated protocol buffer package.
defaultplugins/ifplugin
Package ifplugin is the implementation of the Interface plugin.deps.
Package ifplugin is the implementation of the Interface plugin.deps.
defaultplugins/ifplugin/bin_api
Package binapi is the parent for packages that define various ifplugin southbound APIs.
Package binapi is the parent for packages that define various ifplugin southbound APIs.
defaultplugins/ifplugin/bin_api/af_packet
Package af_packet represents the VPP binary API of the 'af_packet' VPP module.
Package af_packet represents the VPP binary API of the 'af_packet' VPP module.
defaultplugins/ifplugin/bin_api/bfd
Package bfd represents the VPP binary API of the 'bfd' VPP module.
Package bfd represents the VPP binary API of the 'bfd' VPP module.
defaultplugins/ifplugin/bin_api/interfaces
Package interfaces represents the VPP binary API of the 'interfaces' VPP module.
Package interfaces represents the VPP binary API of the 'interfaces' VPP module.
defaultplugins/ifplugin/bin_api/ip
Package ip represents the VPP binary API of the 'ip' VPP module.
Package ip represents the VPP binary API of the 'ip' VPP module.
defaultplugins/ifplugin/bin_api/memif
Package memif represents the VPP binary API of the 'memif' VPP module.
Package memif represents the VPP binary API of the 'memif' VPP module.
defaultplugins/ifplugin/bin_api/tap
Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
defaultplugins/ifplugin/bin_api/vpe
Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
defaultplugins/ifplugin/bin_api/vxlan
Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
defaultplugins/ifplugin/model
Package model is the parent for packages that define various if_plugin northbound APIs generated from protobuf data models.
Package model is the parent for packages that define various if_plugin northbound APIs generated from protobuf data models.
defaultplugins/ifplugin/model/bfd
Package bfd is a generated protocol buffer package.
Package bfd is a generated protocol buffer package.
defaultplugins/ifplugin/model/interfaces
Package interfaces is a generated protocol buffer package.
Package interfaces is a generated protocol buffer package.
defaultplugins/ifplugin/testing
Package testing provides tools and input data for unit testing of ifplugin.
Package testing provides tools and input data for unit testing of ifplugin.
defaultplugins/l2plugin
Package l2plugin implements the L2 plugin that handles Bridge Domains and the L2 FIB.
Package l2plugin implements the L2 plugin that handles Bridge Domains and the L2 FIB.
defaultplugins/l2plugin/bin_api
Package binapi is the parent for packages that define various l2plugin southbound APIs.
Package binapi is the parent for packages that define various l2plugin southbound APIs.
defaultplugins/l2plugin/bin_api/l2
Package l2 represents the VPP binary API of the 'l2' VPP module.
Package l2 represents the VPP binary API of the 'l2' VPP module.
defaultplugins/l2plugin/bin_api/vpe
Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
defaultplugins/l2plugin/model
Package model defines the l2lugin's northbound API.
Package model defines the l2lugin's northbound API.
defaultplugins/l2plugin/model/l2
Package l2 is a generated protocol buffer package.
Package l2 is a generated protocol buffer package.
defaultplugins/l2plugin/testing
Package testing provides tools and input data for unit testing of the l2plugin.
Package testing provides tools and input data for unit testing of the l2plugin.
defaultplugins/l3plugin
Package l3plugin implements the L3 plugin that handles the L3 FIB.
Package l3plugin implements the L3 plugin that handles the L3 FIB.
defaultplugins/l3plugin/bin_api
Package binapi defines the l3plugin's southbound API.
Package binapi defines the l3plugin's southbound API.
defaultplugins/l3plugin/bin_api/ip
Package ip represents the VPP binary API of the 'ip' VPP module.
Package ip represents the VPP binary API of the 'ip' VPP module.
defaultplugins/l3plugin/model
Package model defines the l3plugin's northbound API.
Package model defines the l3plugin's northbound API.
defaultplugins/l3plugin/model/l3
Package l3 is a generated protocol buffer package.
Package l3 is a generated protocol buffer package.
linuxplugin
Package linuxplugin implements the Linux plugin.
Package linuxplugin implements the Linux plugin.
linuxplugin/model
Package model defines the linuxplugin's northbound API.
Package model defines the linuxplugin's northbound API.
linuxplugin/model/interfaces
Package interfaces is a generated protocol buffer package.
Package interfaces is a generated protocol buffer package.

Jump to

Keyboard shortcuts

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