Replace supported admonitions with rst directives
[docs.git] / docs / developer-guide / sxp-developer-guide.rst
1 SXP Developer Guide
2 ===================
3
4 Overview
5 --------
6
7 SXP (Source-Group Tag eXchange Protocol) project is an effort to enhance
8 OpenDaylight platform with IP-SGT (IP Address to Source Group Tag)
9 bindings that can be learned from connected SXP-aware network nodes. The
10 current implementation supports SXP protocol version 4 according to the
11 Smith, Kandula - SXP `IETF
12 draft <https://tools.ietf.org/html/draft-smith-kandula-sxp-04>`__ and
13 grouping of peers and creating filters based on ACL/Prefix-list syntax
14 for filtering outbound and inbound IP-SGT bindings. All protocol legacy
15 versions 1-3 are supported as well. Additionally, version 4 adds
16 bidirectional connection type as an extension of a unidirectional one.
17
18 SXP Architecture
19 ----------------
20
21 The SXP Server manages all connected clients in separate threads and a
22 common SXP protocol agreement is used between connected peers. Each SXP
23 network peer is modelled with its pertaining class, e.g., SXP Server
24 represents the SXP Speaker, SXP Listener the Client. The server program
25 creates the ServerSocket object on a specified port and waits until a
26 client starts up and requests connect on the IP address and port of the
27 server. The client program opens a Socket that is connected to the
28 server running on the specified host IP address and port.
29
30 The SXP Listener maintains connection with its speaker peer. From an
31 opened channel pipeline, all incoming SXP messages are processed by
32 various handlers. Message must be decoded, parsed and validated.
33
34 The SXP Speaker is a counterpart to the SXP Listener. It maintains a
35 connection with its listener peer and sends composed messages.
36
37 The SXP Binding Handler extracts the IP-SGT binding from a message and
38 pulls it into the SXP-Database. If an error is detected during the
39 IP-SGT extraction, an appropriate error code and sub-code is selected
40 and an error message is sent back to the connected peer. All transitive
41 messages are routed directly to the output queue of SXP Binding
42 Dispatcher.
43
44 The SXP Binding Dispatcher represents a selector that will decides how
45 many data from the SXP-database will be sent and when. It is responsible
46 for message content composition based on maximum message length.
47
48 The SXP Binding Filters handles filtering of outgoing and incoming
49 IP-SGT bindings according to BGP filtering using ACL and Prefix List
50 syntax for specifying filter or based on Peer-sequence length.
51
52 The SXP Domains feature provides isolation of SXP peers and bindings
53 learned between them, also exchange of Bindings is possible across
54 SXP-Domains by ACL, Prefix List or Peer-Sequence filters
55
56 Key APIs and Interfaces
57 -----------------------
58
59 As this project is fairly small, it provides only few features that
60 install and provide all APIs and implementations for this project.
61
62 -  sxp-controller
63
64 -  sxp-api
65
66 -  spx-core
67
68 sxp-controller
69 ~~~~~~~~~~~~~~
70
71 RPC request handling
72
73 sxp-api
74 ~~~~~~~
75
76 Contains data holders and entities
77
78 spx-core
79 ~~~~~~~~
80
81 Main logic and core features
82
83 API Reference Documentation
84 ---------------------------
85
86 `RESTCONF Interface and Dynamic
87 Tree <https://wiki.opendaylight.org/images/9/91/SXP_Restconf_Interface_and_Dynamic_Tree.pdf>`__
88 `Specification and
89 Architecture <https://wiki.opendaylight.org/images/6/6e/SXP_Specification_and_Architecture_v03.pdf>`__
90