Projects

Introducing: OVSDB Client Library Open Source Project

The OVSDB Client Library (short for Open vSwitch Database) open source project recently released on GitHub by VMware’s NSX team enables simple interaction with an OVSDB server. This is a schema-independent OVSDB Java client compatible with the  OVSDB Management Protocol (RFC 7047).

Where to Use It

Open vSwitch Daemon Configuration

Open vSwitch Deamon(ovs-vswitchd) is a daemon that manages and controls any number of Open vSwitch switches on a local machine[1]. The configurations for ovs-vswitchd are stored in a database with Open_vSwitch schema, as shown below:

The utilities for querying and updating the configuration of ovs-vswitchd provided by OvS project are all written in C, making it hard for a Java control and management cluster to configure the daemon. One solution is to run a C agent together with the daemon, which can receive the configuration from the Java controller and then configure it. Now, with the help of this OVSDB Client Library in Java, this agent is not needed anymore and the Java controller can configure ovs-vswitchd directly.

SDN with Hardware VTEP Support

Software-Defined networking (SDN) abstracts the network from physical devices and topology using overlay protocols such as VXLAN, GENEVE, etc. However, many networking appliances and physical servers, such as proprietary networking appliances and legacy physical servers, do not support these protocols. For these situations, you must provide a bridge between the physical and virtual network elements. One solution provided by VMware NSX is to use a hardware gateway as a VXLAN Tunnel EndPoint (VTEP). A hardware VTEP is basically a physical switch that runs an OVSDB server with hardware_vtep database schema. The SDN controller configures a hardware VTEP by populating the OVSDB tables. In this scenario, the SDN controller uses the OVSDB client library to interact with the OVSDB server running on the hardware VTEP.

OVSDB Client Library Implementation Testing

According to RFC 7047, “an OVSDB server MUST implement all of the following methods.  An OVSDB client MUST implement the ‘Echo’ method and is otherwise free to implement whichever methods suit the implementation’s needs.” Since all RPC methods are implemented by this library, OVSDB Client Library can validate an OVSDB server implementation.

Key Features

  • Schema-independent – The OVSDB Client library does not depend on any specific OVSDB schema. It can operate on all valid OVSDB databases. Currently, OVS project defines two OVSDB schemas: Open_vSwitch schema and hardware_vtep schema. The user can also define their own schema on an OVSDB server and use this library to interact with it.
  • Completely Asynchronous Interfaces – All the interfaces provided by this library are asynchronous. This enables asynchronous programming for the library user.
  • ORM and JPA-like Interfaces – This feature is still under development. Once the ORM layer is added, the user can define entities with JPA annotation and use JPA-like interfaces to do CRUD operations on an OVSDB server. That means the user does not need to know anything about the OVSDB management protocol to use this library.

Check It Out!

Check out the code at https://github.com/vmware/ovsdb-client-library. People who are interested in OVSDB and ORM are welcome to contribute to the library. Bugs and suggestions can be submitted through GitHub issues.

Check back on the Open Source Blog for updates on the latest open source projects, and follow us on Twitter (@vmwopensource).