Using Control Adapters

The OB-BAA distribution provides a Standard Control Adapter and permits vendors to provide their own Vendor Control Adapters. These adapters are administered as Vendor Device Adapters as defined by the Device Adapter Framework section.

Using the Standard Control Adapter

The SCA is currently restricted to be used on the control plane relay feature. The SCA is pre-loaded in the BAA layer and provides a gRPC server that listens for gRPC connections from zero or more access nodes.

Access nodes (devices) are identified to use the SCA by the following attributes:

Info: Further information about this example's open source SOC reference implementation can be found here.

Identification of a Control Adapter

The SCA and VCA follows the same naming convention as BAA Core service Vendor Device Adapter's but since the Control Relay VDA is programmed in the Go programming language with the adapter's plugin file identified with the .so file extension as depicted below:


Functions exposed by Control Adapters

The functionality that is exposed by a Control Adapter includes the capability to start and stop the adapter and the interface to transmit a packet to the access node as depicted below:

//GPB structure of a packet generated by Google protobuf compiler for the Go programming language
type ControlRelayPacketInternal struct {
    DeviceName       string
    DeviceInterface  string
    OriginatingRule  string
    Packet            []byte
func PacketOutCallBack(packet ControlRelayPacketInternal )
func Start()
func Stop()

Functions used by a Control Adapter

The functionality that is used by the Control Adapter includes the ability to relay a received packet from the access node to/through the Control Relay Service to SDN Application endpoint(s).

func PacketInCallBack(packet ControlRelayPacketInternal)

Configuring an Access Node to Relay Packets (Mfc-conf)

Access nodes are configured with information the access node needs to relay packets to external endpoints, in this case the Control Relay Service in the BAA layer.

The model that used within the Access node is based on the TR-383 classification modules for vlan-sub-interfaces.

According to TR-383 Amendment 2, section 7.1:

Before traffic can be forwarded, it must first be classified to determine what to forward, where to forward and how to manipulate the packet if so desired. The concept of a vlan-sub-interface has been introduced for provide a VLAN interface which can be used as the source or destination interface of a forwarding decision. Each vlan-sub-interface classifies traffic from a particular lower layer interface into a forwarder. This classification consists of a set of rules specified using match criteria on to packet fields (e.g., VLAN-ID, p-bit). The lower layer interface can be either a non-aggregated physical or logical interface (e.g., Ethernet), an aggregation of physical or logical interfaces (e.g., LAG) or can be another vlan-sub-interface.

Sub-interface Example (from TR-383, figure 2)

In addition to classification of traffic, [the sub-interface also contains rules for any ingress or egress actions to take on each matched packet]{.underline}. These actions include pushing or popping tags, rewrite of p-bits or rewrite of Drop Eligible Indication (DEI) bits.”

As such the model (bbf-obbaa-mfc-conf) used configure the packets toward the BAA layer's Control Relay service is defined below:

  augment /if:interfaces/if:interface/bbf-subif:frame-processing/bbf-subif:inline-frame-processing/bbf-subif:inline-frame-processing/bbf-subif:ingress-rule/bbf-subif:rule:
    +--rw control-relay! {control-relay}?
       +--rw action?                  control-relay-action
       +--rw (resulting-endpoint)?
          |  +--rw client-endpoint    -> /remote-nf-settings/nf-client/client-parameters/nf-initiate/remote-endpoints/name {nf-client-supported}?
             +--rw server-endpoint    -> /remote-nf-settings/nf-server/server-parameters/listen/remote-endpoints/name {nf-server-supported}?

If the ‘control-relay’ container is present, then it means that the packets matching the sub-interface filter must be either copied or redirected to an external entity, depending on the value of the ‘action’ leaf.

The external entity is specified by an endpoint (which can act as server or client from the connection point of view) as described below:

module: bbf-obbaa-mfc-conf
  +--rw remote-nf-settings!
     +--rw nf-client {nf-client-supported}?
     |  +--rw enabled?             boolean
     |  +--rw client-parameters
     |     +--rw nf-initiate!
     |        +--rw remote-endpoints* [name]
     |           +--rw name                             string
     |           +--rw type?                            string
     |           +--rw remote-endpoint
     |           |  +--rw access-points* [name]
     |           |     +--rw name          string
     |           |     +--rw (transport)
     |           |        +--:(grpc)
     |           |           +--rw grpc
     |           |              +--rw grpc-client-parameters
     |           |                 +--rw remote-address    inet:host
     |           |                 +--rw remote-port?      inet:port-number
     |           |                 +--rw local-address?    inet:ip-address {local-binding-supported}?
     |           |                 +--rw local-port?       inet:port-number {local-binding-supported}?
     |           |                 +--rw keepalives! {keepalives-supported}?
     |           |                    +--rw idle-time         uint16
     |           |                    +--rw max-probes        uint16
     |           |                    +--rw probe-interval    uint16
     |           +---n remote-endpoint-status-change
     |              +-- access-point                         -> ../../remote-endpoint/access-points/name
     |              +-- connected                            boolean
     |              +-- remote-endpoint-state-last-change    yang:date-and-time
     +--rw nf-server {nf-server-supported}?
        +--rw enabled?             boolean
        +--rw server-parameters
           +--rw listen!
              +--rw idle-timeout?       uint16
              +--rw listen-endpoint* [name]
              |  +--rw name                             string
              |  +--rw (transport)
              |  |  +--:(grpc)
              |  |     +--rw grpc
              |  |        +--rw grpc-server-parameters
              |  |           +--rw local-address    inet:ip-address
              |  |           +--rw local-port?      inet:port-number
              |  |           +--rw keepalives! {keepalives-supported}?
              |  |              +--rw idle-time         uint16
              |  |              +--rw max-probes        uint16
              |  |              +--rw probe-interval    uint16
              |  +---n remote-endpoint-status-change
              |     +-- remote-endpoint                      -> ../../../remote-endpoints/name
              |     +-- connected                            boolean
              |     +-- remote-endpoint-state-last-change    yang:date-and-time
              +--ro remote-endpoints* [name]
                 +--ro name    string

The OB-BAA distribution provides the YANG module (bbf-obbaa-mfc-conf.yang) to be included in access nodes that use the Control relay feature. The YANG module is located in the /resource/examples/control-relay-yang directory.

The following provides an example of how an access node can be configured to redirect IGMP, DHCP packets from the access node to the BAA layer's control micro-service:

<remote-nf-settings xmlns="urn:bbf:yang:obbaa:mfc-conf">

<interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
    <type xmlns:ianaift="urn:ietf:params:xml:ns:yang:iana-if-type">ianaift:ethernetCsmacd</type>
 <!-- Relay DHCP and IGMP packets (rule with highest priority) -->
	<type xmlns:bbfift="urn:bbf:yang:bbf-if-type">bbfift:vlan-sub-interface</type>
	<subif-lower-layer xmlns="urn:bbf:yang:bbf-sub-interfaces">
	<inline-frame-processing xmlns="urn:bbf:yang:bbf-sub-interfaces">
			   This field indicates the priority for applying the
			   match criteria of this rule against the priority of
			   match criteria of other rules of this and other
			   sub-interfaces on the same parent-interface. -->
			<match-criteria xmlns="urn:bbf:yang:bbf-sub-interface-tagging">
		  <control-relay xmlns="urn:bbf:yang:obbaa:mfc-conf">
    <type xmlns:bbfift="urn:bbf:yang:bbf-if-type">bbfift:vlan-sub-interface</type>
    <subif-lower-layer xmlns="urn:bbf:yang:bbf-sub-interfaces">
    <!-- Relay packets destined to a specific IP on a specific VLAN -->
    <inline-frame-processing xmlns="urn:bbf:yang:bbf-sub-interfaces">
            <match-criteria xmlns="urn:bbf:yang:bbf-sub-interface-tagging">
                  <tag-type xmlns:bbf-dot1qt="urn:bbf:yang:bbf-dot1q-types">bbf-dot1qt:c-vlan</tag-type>
          <control-relay xmlns="urn:bbf:yang:obbaa:mfc-conf">

<–Using OB-BAA