Updated git submodules
[docs.git] / docs / user-guide / bgp-user-guide.rst
index 929e38ab886a7c24ecc407ef8fed29ea53a9f287..a85531538ae1383a1ab785a24c5992ef009c5697 100644 (file)
@@ -248,15 +248,41 @@ The new instance presence can be verified via REST:
 
 @line 4: The BGP-4 supports carrying IPv4 prefixes, such routes are stored in *ipv4-address-family*/*unicast-subsequent-address-family* table.
 
+BGP Server
+^^^^^^^^^^
+
+BGP uses TCP as its transport protocol, by default listens on port 179. OpenDaylight BGP plugin is configured to listen on port *1790*, due to
+privileged ports restriction for non-root users.
+One of the workarounds is to use port redirection. In case other port is desired to be used instead, we can reconfigure it.
+
+Here is a sample of bgp port listening re-configuration:
+
+**URL:** ``/restconf/config/odl-bgp-peer-acceptor-config:bgp-peer-acceptor-config/default``
+
+**Method:** ``PUT``
+
+**Content-Type:** ``application/xml``
+
+**Request Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 3,4
+
+   <bgp-peer-acceptor-config xmlns="urn:opendaylight:params:xml:ns:yang:odl-bgp-peer-acceptor-config">
+       <config-name>default</config-name>
+       <binding-address>0.0.0.0</binding-address>
+       <binding-port>1791</binding-port>
+   </bgp-peer-acceptor-config>
+
+@line 3: Binding address: By default is 0.0.0.0, so it is not a mandatory field.
+
+@line 4: Binding Port: Port were BGP Server will listen.
+
 BGP Peering
 ^^^^^^^^^^^
 To exchange routing information between two BGP systems (peers), it is required to configure a peering on both BGP speakers first.
 This mean that each BGP speaker has a white list of neighbors, representing remote peers, with which the peering is allowed.
-BGP uses TCP as its transport protocol, by default listens on port 179.
-
-.. important:: OpenDaylight BGP plugin is configured to listen on port *1790*, due to privileged ports restriction for non-root users.
-   One of the workarounds is to use port redirection.
-
 The TCP connection is established between two peers and they exchange messages to open and confirm the connection parameters followed by routes exchange.
 
 Here is a sample basic neighbor configuration:
@@ -1048,6 +1074,153 @@ Consequently, route disappears from programmable RIB, *Application Peer's* RIBs,
 
 .. note:: Routes stored in programmable RIB are persisted on OpendDaylight shutdown and restored after the re-start.
 
+BGP Protocol Configuration Loader
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+BGP Protocol Configuration Loader allows user to define static initial configuration for a BGP protocol instance.
+This service will detect the creation of new configuration files following the pattern "protocols-*.xml" under the path "etc/opendaylight/bgp".
+Once the file is processed, the defined configuration will be available from the configuration Data Store.
+
+.. note:: If the BGP instance is already present, no update or configuration will be applied.
+
+When installing BGP an example will be provided and a default configuration loaded.
+
+**PATH:** ``etc/opendaylight/bgp/protocols-config.xml``
+
+.. code-block:: xml
+
+    <protocols xmlns="http://openconfig.net/yang/network-instance">
+        <protocol>
+            <name>example-bgp-rib</name>
+            <identifier xmlns:x="http://openconfig.net/yang/policy-types">x:BGP</identifier>
+            <bgp xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+                <global>
+                    <config>
+                        <router-id>192.0.2.2</router-id>
+                        <as>64496</as>
+                        <!-- if cluster-id is not present, it's value is the same as bgp-id -->
+                        <!-- <route-reflector-cluster-id>192.0.2.3</route-reflector-cluster-id> -->
+                        <!-- <read-only-limit>120</read-only-limit>-->
+                    </config>
+                    <afi-safis>
+                        <afi-safi>
+                            <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-UNICAST</afi-safi-name>
+                            <!--Advertise N Paths
+                            <receive>true</receive>
+                            <send-max>2</send-max>-->
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV6-UNICAST</afi-safi-name>
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-LABELLED-UNICAST</afi-safi-name>
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV6-LABELLED-UNICAST</afi-safi-name>
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:L3VPN-IPV4-UNICAST</afi-safi-name>
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:L3VPN-IPV6-UNICAST</afi-safi-name>
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:L2VPN-EVPN</afi-safi-name>
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name>LINKSTATE</afi-safi-name>
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name>IPV4-FLOW</afi-safi-name>
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name>IPV6-FLOW</afi-safi-name>
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name>IPV4-L3VPN-FLOW</afi-safi-name>
+                        </afi-safi>
+                        <afi-safi>
+                            <afi-safi-name>IPV6-L3VPN-FLOW</afi-safi-name>
+                        </afi-safi>
+                    </afi-safis>
+                </global>
+                <neighbors xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+                    <neighbor xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+                        <neighbor-address>192.0.2.1</neighbor-address>
+                        <config>
+                            <peer-type>INTERNAL</peer-type>
+                            <peer-as>64496</peer-as>
+                        </config>
+                        <transport>
+                            <config>
+                                <remote-port>179</remote-port>
+                                <passive-mode>true</passive-mode>
+                            </config>
+                        </transport>
+                        <timers>
+                            <config>
+                                <hold-time>180</hold-time>
+                                <connect-retry>10</connect-retry>
+                            </config>
+                        </timers>
+                        <route-reflector>
+                            <config>
+                                <route-reflector-client>false</route-reflector-client>
+                            </config>
+                        </route-reflector>
+                        <afi-safis>
+                            <afi-safi>
+                                <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-UNICAST</afi-safi-name>
+                                <!--Advertise N Paths
+                                <receive>true</receive>
+                                <send-max>0</send-max>-->
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV6-UNICAST</afi-safi-name>
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-LABELLED-UNICAST</afi-safi-name>
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV6-LABELLED-UNICAST</afi-safi-name>
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:L3VPN-IPV4-UNICAST</afi-safi-name>
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:L3VPN-IPV6-UNICAST</afi-safi-name>
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:L2VPN-EVPN</afi-safi-name>
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name>LINKSTATE</afi-safi-name>
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name>IPV4-FLOW</afi-safi-name>
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name>IPV6-FLOW</afi-safi-name>
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name>IPV4-L3VPN-FLOW</afi-safi-name>
+                            </afi-safi>
+                            <afi-safi>
+                                <afi-safi-name>IPV6-L3VPN-FLOW</afi-safi-name>
+                            </afi-safi>
+                        </afi-safis>
+                    </neighbor>
+                    <neighbor xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+                        <neighbor-address>192.0.2.6</neighbor-address>
+                        <config>
+                            <peer-group>application-peers</peer-group>
+                        </config>
+                    </neighbor>
+                </neighbors>
+            </bgp>
+        </protocol>
+    </protocols>
+
 BGP pipeline
 ^^^^^^^^^^^^
 .. figure:: ./images/bgpcep/bgp-pipeline.png
@@ -1974,6 +2147,26 @@ To enable BGP-LS support in BGP plugin, first configure BGP speaker instance:
        </bgp>
    </protocol>
 
+Linkstate path attribute
+''''''''''''''''''''''''
+IANA allocation for BGP-LS path attribute is TYPE 29.
+Some older BGP-LS implementations might still require earliest asigned allocation TYPE 99.
+To use TYPE = 99, you need to set value bellow to false.
+
+**URL:** ``/restconf/config/bgp-linkstate-app-config:bgp-linkstate-app-config``
+
+**Method:** ``PUT``
+
+**Content-Type:** ``application/xml``
+
+**Request Body:**
+
+.. code-block:: xml
+
+   <bgp-linkstate-app-config xmlns="urn:opendaylight:params:xml:ns:yang:controller:bgp:linkstate-app-config">
+       <iana-linkstate-attribute-type>false</iana-linkstate-attribute-type>
+   </bgp-linkstate-app-config>
+
 BGP Peer
 ''''''''
 Here is an example for BGP peer configuration with enabled BGP-LS family.
@@ -3839,6 +4032,24 @@ To enable ADD-PATH capability in BGP plugin, first configure BGP speaker instanc
 
 @line 14: Defines path selection strategy: *send-max* > 1 -> Advertise N Paths or *send-max* = 0 -> Advertise All Paths
 
+Here is an example for update a specific family with enable ADD-PATH capability
+
+**URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/global/afi-safis/afi-safi/openconfig-bgp-types:IPV4%2DUNICAST``
+
+**Method:** ``PUT``
+
+**Content-Type:** ``application/xml``
+
+**Request Body:**
+
+.. code-block:: xml
+
+   <afi-safi xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+      <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-UNICAST</afi-safi-name>
+      <receive>true</receive>
+      <send-max>0</send-max>
+   </afi-safi>
+
 BGP Peer
 ''''''''
 Here is an example for BGP peer configuration with enabled ADD-PATH capability.
@@ -3859,18 +4070,34 @@ Here is an example for BGP peer configuration with enabled ADD-PATH capability.
            <afi-safi>
                <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-LABELLED-UNICAST</afi-safi-name>
            </afi-safi>
-               <afi-safis>
-                   <afi-safi>
-                       <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-UNICAST</afi-safi-name>
-                       <receive>true</receive>
-                       <send-max>0</send-max>
-                   </afi-safi>
-               </afi-safis>
+           <afi-safi>
+               <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-UNICAST</afi-safi-name>
+               <receive>true</receive>
+               <send-max>0</send-max>
+           </afi-safi>
        </afi-safis>
    </neighbor>
 
 .. note:: The path selection strategy is not configurable on per peer basis. The send-max presence indicates a willingness to send ADD-PATH NLRIs to the neighbor.
 
+Here is an example for update specific family BGP peer configuration with enabled ADD-PATH capability.
+
+**URL:** ``/restconf/config/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors/neighbor/192.0.2.1/afi-safis/afi-safi/openconfig-bgp-types:IPV4%2DUNICAST``
+
+**Method:** ``PUT``
+
+**Content-Type:** ``application/xml``
+
+**Request Body:**
+
+.. code-block:: xml
+
+   <afi-safi xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+      <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-UNICAST</afi-safi-name>
+      <receive>true</receive>
+      <send-max>0</send-max>
+   </afi-safi>
+
 Usage
 ^^^^^
 The IPv4 Unicast table with enabled ADD-PATH capability in an instance of the speaker's Loc-RIB can be verified via REST:
@@ -3964,6 +4191,430 @@ References
 ^^^^^^^^^^
 * `Route Refresh Capability for BGP-4 <https://tools.ietf.org/html/rfc2918>`_
 
+Operational State
+-----------------
+
+The OpenDaylight BGP implementation provides a set of APIs (described below), that give its operational state refreshed periodically, by default every 5 seconds.
+The following APIs describe what is available starting with how to change the default refresh rate.
+
+.. contents:: Contents
+   :depth: 2
+   :local:
+
+Operational State Configuration
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+**URL:** ``/restconf/config/bgp-state-config:bgp-state-config``
+
+**Method:** ``PUT``
+
+**Content-Type:** ``application/xml``
+
+**Request Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 3
+
+   <bgp-state-config xmlns="urn:opendaylight:params:xml:ns:yang:controller:config">
+       <config-name xmlns="urn:opendaylight:params:xml:ns:yang:bgp-state-config">operationalState</config-name>
+       <timer xmlns="urn:opendaylight:params:xml:ns:yang:bgp-state-config">1</timer>
+   </bgp-state-config>
+
+@line 3: Time in seconds between operational state update.
+
+BGP RIB Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/global/state``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+
+   <state xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+       <as>65000</as>
+       <router-id>192.0.2.2</router-id>
+       <total-paths>0</total-paths>
+       <total-prefixes>0</total-prefixes>
+   </state>
+
+@line 2: AS number of the remote peer.
+
+@line 3: The unique protocol instance identifier.
+
+@line 4: Total number of Paths installed on RIB (Loc-RIB)
+
+@line 5: Total number of Prefixes installed on RIB (Loc-RIB)
+
+BGP RIB Families Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/global/afi-safis``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 3,5,6
+
+   <afi-safis xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+       <afi-safi>
+           <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-UNICAST</afi-safi-name>
+           <state>
+               <total-paths>0</total-paths>
+               <total-prefixes>0</total-prefixes>
+           </state>
+       </afi-safi>
+       <afi-safi>
+           <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV6-UNICAST</afi-safi-name>
+           <state>
+               <total-paths>0</total-paths>
+               <total-prefixes>0</total-prefixes>
+           </state>
+       </afi-safi>
+       ....
+   </afi-safis>
+
+@line 3: Family Identifier.
+
+@line 5: Total number of Paths installed on RIB (Loc-RIB) per specific family.
+
+@line 6: Total number of Prefixes installed on RIB (Loc-RIB) per specific family.
+
+BGP Neighbors Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 3
+
+   <neighbors xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+       <neighbor>
+           <neighbor-address>192.0.2.1</neighbor-address>
+           .....
+       </neighbor>
+       <neighbor>
+           <neighbor-address>192.0.2.2</neighbor-address>
+           .....
+       </neighbor>
+   </neighbors>
+
+@line 3: IP address of the remote BGP peer. Also serves as an unique identifier of a neighbor in a list of neighbors.
+
+BGP Neighbor Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+.. note:: Supported Capabilities only provided when session has been established.
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbor/127.0.0.2/state``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 2,3,4,7,8,11,12
+
+   <state xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+       <session-state>ESTABLISHED</session-state>
+       <supported-capabilities xmlns:x="http://openconfig.net/yang/bgp-types">x:ASN32</supported-capabilities>
+       <supported-capabilities xmlns:x="http://openconfig.net/yang/bgp-types">x:MPBGP</supported-capabilities>
+       <messages>
+           <sent>
+               <UPDATE>0</UPDATE>
+               <NOTIFICATION>0</NOTIFICATION>
+           </sent>
+           <received>
+               <UPDATE>4</UPDATE>
+               <NOTIFICATION>0</NOTIFICATION>
+           </received>
+       </messages>
+   </state>
+
+@line 2: Session status
+
+@line 3-4: BGP capabilities supported ( ASN32 / MPBGP / ROUTE_REFRESH / GRACEFUL_RESTART / ADD_PATHS)
+
+@line 7: Total count of Update Messages sent
+
+@line 8: Total count of Notification Messages sent
+
+@line 11: Total count of Update Messages received
+
+@line 12: Total count of Notification Messages received
+
+BGP Neighbor Families Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+.. note:: Graceful Restart not supported yet. Planned for Carbon.
+
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors/neighbor/192.0.2.1/afi-safis``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 3,5,7,9,10
+
+   <afi-safis xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+        <afi-safi>
+            <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-UNICAST</afi-safi-name>
+            <state>
+                <active>false</active>
+            </state>
+            <graceful-restart>
+                <state>
+                    <received>false</received>
+                    <advertised>false</advertised>
+                </state>
+            </graceful-restart>
+        </afi-safi>
+        <afi-safi>
+            <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV6-UNICAST</afi-safi-name>
+            <state>
+                <active>false</active>
+            </state>
+            <graceful-restart>
+                <state>
+                    <received>false</received>
+                    <advertised>false</advertised>
+                </state>
+            </graceful-restart>
+        </afi-safi>
+   </afi-safis>
+
+@line 3: Family Identifier.
+
+@line 5: True if family is advertized by peer.
+
+@line 7: Graceful Restart Operational State per specific family.
+
+@line 9: True if the peer supports graceful restart.
+
+@line 10: True if we support graceful restart.
+
+BGP Neighbor Family Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+.. note:: Prefixes state is only provided once session is established.
+.. note:: Graceful Restart not supported yet. Planned to be implemented in Carbon.
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors/neighbor/192.0.2.1/afi-safis/afi-safi/openconfig-bgp-types:IPV4%2DUNICAST``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 2,4,6,7,8
+
+   <afi-safi xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+       <afi-safi-name xmlns:x="http://openconfig.net/yang/bgp-types">x:IPV4-UNICAST</afi-safi-name>
+       <state>
+           <active>true</active>
+           <prefixes>
+               <installed>3</installed>
+               <sent>0</sent>
+               <received>3</received>
+           </prefixes>
+       </state>
+       <graceful-restart>
+           <state>
+               <received>false</received>
+               <advertised>false</advertised>
+           </state>
+       </graceful-restart>
+   </afi-safi>
+
+@line 2: Family Identifier.
+
+@line 4: True if family is advertized to and by peer.
+
+@line 6: Total count of prefixes advertized by peer and installed (effective-rib-in).
+
+@line 7: Total count of prefixes advertized to peer (adj-rib-out).
+
+@line 8: Total count of prefixes advertized by peer (adj-rib-in).
+
+BGP Neighbor Timers Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+.. note:: State is only provided once session is established.
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors/neighbor/192.0.2.1/timers``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 3,4
+
+   <timers xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+       <state>
+           <negotiated-hold-time>180</negotiated-hold-time>
+           <uptime>1580676</uptime>
+       </state>
+   </timers>
+
+@line 3: The negotiated hold-time for the BGP session in seconds.
+
+@line 4: Session duration since establishment in milliseconds.
+
+BGP Neighbor Transport Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+.. note:: State is only provided once session is established.
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors/neighbor/192.0.2.1/transport``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 3,4,5
+
+   <transport xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+       <state>
+           <remote-address>127.0.0.2</remote-address>
+           <remote-port>44718</remote-port>
+           <local-port>1790</local-port>
+       </state>
+   </transport>
+
+@line 3: IP address of the remote BGP peer.
+
+@line 4: Port of the remote BGP peer.
+
+@line 5: Local port.
+
+BGP Neighbor Error Handling Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+.. note:: State is only provided once session is established.
+.. note:: Error handling not supported yet. Planned for Carbon.
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors/neighbor/192.0.2.1/error-handling``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 3
+
+   <error-handling xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+       <state>
+           <erroneous-update-messages>0</erroneous-update-messages>
+       </state>
+   </error-handling>
+
+@line 3: The number of BGP UPDATE messages for which the treat-as-withdraw mechanism has been applied based on
+erroneous message contents
+
+BGP Neighbor Graceful Restart Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+.. note:: Graceful Restart not supported yet. Planned for Carbon.
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/bgp/neighbors/neighbor/192.0.2.1/graceful-restart``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 3,4,5
+
+   <graceful-restart xmlns="urn:opendaylight:params:xml:ns:yang:bgp:openconfig-extensions">
+       <state>
+           <peer-restart-time>0</peer-restart-time>
+           <peer-restarting>false</peer-restarting>
+           <local-restarting>false</local-restarting>
+       </state>
+   </graceful-restart>
+
+@line 3: The period of time (advertised by the peer) that the peer expects a restart of a BGP session to take.
+
+@line 4: This flag indicates whether the remote neighbor is currently in the process of restarting, and hence
+received routes are currently stale.
+
+@line 5: This flag indicates whether the local neighbor is currently restarting. The flag is unset after all NLRI
+have been advertised to the peer, and the End-of-RIB (EOR) marker has been unset.
+
+BGP Peer Groups Operational State
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+**URL:** ``/restconf/operational/openconfig-network-instance:network-instances/network-instance/global-bgp/openconfig-network-instance:protocols/protocol/openconfig-policy-types:BGP/bgp-example/peer-groups``
+
+**Method:** ``GET``
+
+**Content-Type:** ``application/xml``
+
+**Response Body:**
+
+.. code-block:: xml
+   :linenos:
+   :emphasize-lines: 3,5,6
+
+   <peer-groups>
+       <peer-group>
+           <peer-group-name>application-peers</peer-group-name>
+           <state>
+               <total-paths>0</total-paths>
+               <total-prefixes>0</total-prefixes>
+           </state>
+   </peer-group>
+
+@line 3: Peer Group Identifier.
+
+@line 5: At this moment the cost for count path under effect-rib-in is to high. Therefore the value is the same as total prefixes.
+
+@line 6: Total Prefixes installed under by peers pertaining to this peer group (effective-rib-in).
+This count doesn't differentiate repeated prefixes.
+
 High Availability
 -----------------
 Running OpenDaylight BGP in clustered environment brings an advantage of the plugin's high availability (HA).
@@ -4357,6 +5008,45 @@ A sample output below represents a two node topology with two unidirectional lin
        </link>
    </topology>
 
+BGP Network Topology Configuration Loader
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+BGP Network Topology Configuration Loader allows user to define static initial configuration for a BGP protocol instance.
+This service will detect the creation of new configuration files following the pattern "network-topology-*.xml" under the path "etc/opendaylight/bgp".
+Once the file is processed, the defined configuration will be available from the configuration Data Store.
+
+.. note:: If the BGP topology instance is already present, no update or configuration will be applied.
+
+When installing BGP an example will be provided and a default configuration loaded.
+
+**PATH:** ``etc/opendaylight/bgp/network-topology-config.xml``
+
+.. code-block:: xml
+
+    <network-topology xmlns="urn:TBD:params:xml:ns:yang:network-topology">
+        <topology>
+            <topology-id>example-ipv4-topology</topology-id>
+            <topology-types>
+                <bgp-ipv4-reachability-topology xmlns="urn:opendaylight:params:xml:ns:yang:odl-bgp-topology-types"/>
+            </topology-types>
+            <rib-id xmlns="urn:opendaylight:params:xml:ns:yang:odl-bgp-topology-config">example-bgp-rib</rib-id>
+        </topology>
+        <topology>
+            <topology-id>example-ipv6-topology</topology-id>
+            <topology-types>
+                <bgp-ipv6-reachability-topology xmlns="urn:opendaylight:params:xml:ns:yang:odl-bgp-topology-types"/>
+            </topology-types>
+            <rib-id xmlns="urn:opendaylight:params:xml:ns:yang:odl-bgp-topology-config">example-bgp-rib</rib-id>
+        </topology>
+        <topology>
+            <topology-id>example-linkstate-topology</topology-id>
+            <topology-types>
+                <bgp-linkstate-topology xmlns="urn:opendaylight:params:xml:ns:yang:odl-bgp-topology-types"/>
+            </topology-types>
+            <rib-id xmlns="urn:opendaylight:params:xml:ns:yang:odl-bgp-topology-config">example-bgp-rib</rib-id>
+        </topology>
+    </network-topology>
+
 Test Tools
 ----------
 BGP test tools serves to test basic BGP functionality, scalability and performance.
@@ -4422,10 +5112,10 @@ This application is part of the OpenDaylight Karaf distribution.
 
 Configuration
 '''''''''''''
-As a first step install BGP, RESTCONF and NETCONF connector plugin, then configure *Application Peer*.
+As a first step install BGP and RESTCONF, then configure *Application Peer*.
 Install ``odl-bgpcep-bgp-benchmark`` feature and reconfigure BGP Application Peer Benchmark application as per following:
 
-**URL:** ``/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules/module/odl-bgp-benchmark-cfg:app-peer-benchmark/bgp-app-peer-benchmark``
+**URL:** ``/restconf/config/odl-bgp-app-peer-benchmark-config:config``
 
 **Method:** ``PUT``
 
@@ -4435,25 +5125,13 @@ Install ``odl-bgpcep-bgp-benchmark`` feature and reconfigure BGP Application Pee
 
 .. code-block:: xml
    :linenos:
-   :emphasize-lines: 12
-
-   <module xmlns="urn:opendaylight:params:xml:ns:yang:controller:config">
-       <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:odl-bgp-benchmark-cfg">x:app-peer-benchmark</type>
-       <name>bgp-app-peer-benchmark</name>
-       <binding-data-broker xmlns="urn:opendaylight:params:xml:ns:yang:controller:odl-bgp-benchmark-cfg">
-           <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding">x:binding-async-data-broker</type>
-           <name>pingpong-binding-data-broker</name>
-       </binding-data-broker>
-       <rpc-registry xmlns="urn:opendaylight:params:xml:ns:yang:controller:odl-bgp-benchmark-cfg">
-           <type xmlns:x="urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding">x:binding-rpc-registry</type>
-           <name>binding-rpc-broker</name>
-       </rpc-registry>
-       <app-rib-id xmlns="urn:opendaylight:params:xml:ns:yang:controller:odl-bgp-benchmark-cfg">10.25.1.9</app-rib-id>
-   </module>
-
-@line 12: The *Application Peer* identifier.
-
-.. warning:: This configuration will be moved to configuration datastore in Carbon release.
+   :emphasize-lines: 2
+
+   <odl-bgp-app-peer-benchmark-config xmlns="urn:opendaylight:params:xml:ns:yang:odl-bgp-app-peer-benchmark-config">
+      <app-peer-id xmlns="urn:opendaylight:params:xml:ns:yang:odl-bgp-app-peer-benchmark-config">10.25.1.9</app-peer-id>
+   </odl-bgp-app-peer-benchmark-config>
+
+@line 2: The *Application Peer* identifier.
 
 Inject routes
 '''''''''''''