775dece99c717eaeda041924a20e1f5d06d07d4a
[openflowplugin.git] / openflowplugin-api / src / main / yang / openflow-provider-config.yang
1 module openflow-provider-config {
2     yang-version 1;
3     namespace "urn:opendaylight:params:xml:ns:yang:openflow:provider:config";
4     prefix "openflow-provider-config";
5
6     description
7         "Configuration for an Openflow provider.";
8
9     revision "2016-05-10" {
10         description
11             "Initial revision";
12     }
13
14     typedef non-zero-uint32-type {
15         type uint32 {
16             range "1..max";
17         }
18     }
19
20     typedef non-zero-uint16-type {
21         type uint16 {
22             range "1..max";
23         }
24     }
25
26     container openflow-provider-config {
27         leaf rpc-requests-quota {
28             description "Quota for maximum number of RPC requests";
29             type non-zero-uint16-type;
30             default 20000;
31         }
32
33         leaf switch-features-mandatory {
34             description "This parameter indicates whether it is mandatory for
35                 switch to support OF1.3 features : table, flow, meter,group. If this
36                 is set to true and switch doesn't support these features its
37                 connection will be denied.";
38             type boolean;
39             default false;
40         }
41
42         leaf global-notification-quota {
43             description "Global notification quota";
44             type uint32;
45             default 64000;
46         }
47
48         leaf is-statistics-polling-on {
49             description "If enabled, periodic statistics gathering will be
50                 turned on. If false takes precedence over the per-capability configuration.";
51             type boolean;
52             default "true";
53         }
54
55         leaf is-table-statistics-polling-on {
56             description "If enabled, periodic table statistics gathering will be
57                 turned on";
58             type boolean;
59             default "true";
60         }
61
62         leaf is-flow-statistics-polling-on {
63             description "If enabled, periodic flow statistics gathering will be
64                 turned on";
65             type boolean;
66             default "true";
67         }
68
69         leaf is-group-statistics-polling-on {
70             description "If enabled, periodic group statistics gathering will be
71                 turned on";
72             type boolean;
73             default "true";
74         }
75
76         leaf is-meter-statistics-polling-on {
77             description "If enabled, periodic meter statistics gathering will be
78                 turned on";
79             type boolean;
80             default "true";
81         }
82
83         leaf is-port-statistics-polling-on {
84             description "If enabled, periodic port statistics gathering will be
85                 turned on";
86             type boolean;
87             default "true";
88         }
89
90         leaf is-queue-statistics-polling-on {
91             description "If enabled, periodic queue statistics gathering will be
92                 turned on";
93             type boolean;
94             default "true";
95         }
96
97         leaf is-statistics-rpc-enabled {
98             status deprecated;
99             description "Expose backward compatible statistics rpcs providing
100                 result in form of async notification. This is deprecated, use direct
101                 statistics instead.";
102             type boolean;
103             default "false";
104         }
105
106         leaf barrier-interval-timeout-limit {
107             description "Barrier timeout";
108             type non-zero-uint32-type;
109             default 500;
110         }
111
112         leaf barrier-count-limit {
113             description "Barrier limit";
114             type non-zero-uint16-type;
115             default 25600;
116         }
117
118         leaf echo-reply-timeout {
119             description "How long we should wait for echo reply (value is in
120                 milliseconds";
121             type non-zero-uint32-type;
122             default 2000;
123         }
124
125         leaf thread-pool-min-threads {
126             description "Mininum (starting) number of threads in thread pool";
127             type uint16;
128             default 1;
129         }
130
131         leaf thread-pool-max-threads {
132             description "Maximum number of threads in thread pool";
133             type non-zero-uint16-type;
134             default 32000;
135         }
136
137         leaf thread-pool-timeout {
138             description "After how much time (in seconds) of inactivity will be
139                 threads in pool terminated";
140             type uint32;
141             default 60;
142         }
143
144         leaf enable-flow-removed-notification {
145             description "Turning on flow removed notification";
146             type boolean;
147             default "true";
148         }
149
150         leaf skip-table-features {
151             description "Ability to skip pulling and storing of large table
152                 features. These features are still available via rpc but if set to
153                 true then maintenance in DS will be omitted";
154             type boolean;
155             default "true";
156         }
157
158         leaf basic-timer-delay {
159             description "Initial delay used in polling the statistics, value is
160                 in milliseconds";
161             type non-zero-uint32-type;
162             default 3000;
163         }
164
165         leaf maximum-timer-delay {
166             description "Maximum timer delay is the wait time to collect next
167                 statistics used in polling the statistics, value is in
168                 milliseconds";
169             type non-zero-uint32-type;
170             default 900000;
171         }
172
173         leaf use-single-layer-serialization {
174             description "When true, Yang models are serialized and deserialized
175                 directly to and from format supported by device, so serialization
176                 and deserialization is faster. Otherwise, models are first
177                 serialized to Openflow specification models and then to format
178                 supported by device, and reversed when deserializing.";
179             type boolean;
180             default "true";
181         }
182
183         leaf enable-equal-role {
184                 description "When true, openflowplugin won't send any specific role
185                 request down to the switch after plugin internally decides the
186                 ownership of the device using Entity Ownership Service. In this
187                 scenario, controller connection for the device will be in equal
188                 role. The behavior will be same for single node setup and clustered
189                 setup. In clustered scenario, all the controller will be in equal
190                 role for the device. In this case device will send all asynchronous
191                 event messages (e.g packet_in) to all the controllers, but openflowplugin
192                 will drop these events for the controller instances that is internally
193                 not owning the device.";
194             type boolean;
195             default "false";
196         }
197
198         leaf device-connection-rate-limit-per-min {
199             description "To limit the number of datapath nodes connecting to odl controller
200             instance per minute. Default value 0 indicates that the device connection rate
201             limiter will be disabled.";
202             type uint16;
203             default 0;
204         }
205
206         leaf device-connection-hold-time-in-seconds {
207             description "device connection hold time is the least time delay in seconds a
208             device has to maintain between its consecutive connection attempts. If time delay
209             between the previous connection and the current connection is within device
210             connection hold time, the device will not be allowed to connect to the controller.
211             Default value of the device connection hold time is 0 second.";
212             type uint16;
213             default 0;
214         }
215
216         leaf device-datastore-removal-delay {
217             description "Delay (in milliseconds) before device is removed from
218             the operational data store in the event of device disconnection
219             from the controller.";
220
221             type non-zero-uint32-type;
222             default 500;
223         }
224
225         leaf enable-custom-trust-manager {
226             description "When true would use customtrustmanager to get switch certificate for TLS
227             authentication failure notification. ";
228             type boolean;
229             default "false";
230        }
231     }
232 }