Adding TestVNF netconf server
[demo.git] / vnfs / TestVNF / netconftemplates / netconftemplates / ietf-netconf-notifications@2012-02-06.yin
1 <rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="m-1">
2   <data xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-monitoring">&lt;?xml version="1.0" encoding="UTF-8"?&gt;
3 &lt;module name="ietf-netconf-notifications"
4         xmlns="urn:ietf:params:xml:ns:yang:yin:1"
5         xmlns:ncn="urn:ietf:params:xml:ns:yang:ietf-netconf-notifications"
6         xmlns:inet="urn:ietf:params:xml:ns:yang:ietf-inet-types"
7         xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0"&gt;
8   &lt;namespace uri="urn:ietf:params:xml:ns:yang:ietf-netconf-notifications"/&gt;
9   &lt;prefix value="ncn"/&gt;
10   &lt;import module="ietf-inet-types"&gt;
11     &lt;prefix value="inet"/&gt;
12   &lt;/import&gt;
13   &lt;import module="ietf-netconf"&gt;
14     &lt;prefix value="nc"/&gt;
15   &lt;/import&gt;
16   &lt;organization&gt;
17     &lt;text&gt;IETF NETCONF (Network Configuration Protocol) Working Group&lt;/text&gt;
18   &lt;/organization&gt;
19   &lt;contact&gt;
20     &lt;text&gt;WG Web:   &amp;lt;http://tools.ietf.org/wg/netconf/&amp;gt;
21 WG List:  &amp;lt;mailto:netconf@ietf.org&amp;gt;
22 WG Chair: Bert Wijnen
23           &amp;lt;mailto:bertietf@bwijnen.net&amp;gt;
24 WG Chair: Mehmet Ersue
25           &amp;lt;mailto:mehmet.ersue@nsn.com&amp;gt;
26 Editor:   Andy Bierman
27           &amp;lt;mailto:andy@netconfcentral.org&amp;gt;&lt;/text&gt;
28   &lt;/contact&gt;
29   &lt;description&gt;
30     &lt;text&gt;This module defines a YANG data model for use with the
31 NETCONF protocol that allows the NETCONF client to
32 receive common NETCONF base event notifications.
33 Copyright (c) 2012 IETF Trust and the persons identified as
34 the document authors.  All rights reserved.
35 Redistribution and use in source and binary forms, with or
36 without modification, is permitted pursuant to, and subject
37 to the license terms contained in, the Simplified BSD License
38 set forth in Section 4.c of the IETF Trust's Legal Provisions
39 Relating to IETF Documents
40 (http://trustee.ietf.org/license-info).
41 This version of this YANG module is part of RFC 6470; see
42 the RFC itself for full legal notices.&lt;/text&gt;
43   &lt;/description&gt;
44   &lt;revision date="2012-02-06"&gt;
45     &lt;description&gt;
46       &lt;text&gt;Initial version.&lt;/text&gt;
47     &lt;/description&gt;
48     &lt;reference&gt;
49       &lt;text&gt;RFC 6470: NETCONF Base Notifications&lt;/text&gt;
50     &lt;/reference&gt;
51   &lt;/revision&gt;
52   &lt;grouping name="common-session-parms"&gt;
53     &lt;description&gt;
54       &lt;text&gt;Common session parameters to identify a
55 management session.&lt;/text&gt;
56     &lt;/description&gt;
57     &lt;leaf name="username"&gt;
58       &lt;type name="string"/&gt;
59       &lt;mandatory value="true"/&gt;
60       &lt;description&gt;
61         &lt;text&gt;Name of the user for the session.&lt;/text&gt;
62       &lt;/description&gt;
63     &lt;/leaf&gt;
64     &lt;leaf name="session-id"&gt;
65       &lt;type name="nc:session-id-or-zero-type"/&gt;
66       &lt;mandatory value="true"/&gt;
67       &lt;description&gt;
68         &lt;text&gt;Identifier of the session.
69 A NETCONF session MUST be identified by a non-zero value.
70 A non-NETCONF session MAY be identified by the value zero.&lt;/text&gt;
71       &lt;/description&gt;
72     &lt;/leaf&gt;
73     &lt;leaf name="source-host"&gt;
74       &lt;type name="inet:ip-address"/&gt;
75       &lt;description&gt;
76         &lt;text&gt;Address of the remote host for the session.&lt;/text&gt;
77       &lt;/description&gt;
78     &lt;/leaf&gt;
79   &lt;/grouping&gt;
80   &lt;grouping name="changed-by-parms"&gt;
81     &lt;description&gt;
82       &lt;text&gt;Common parameters to identify the source
83 of a change event, such as a configuration
84 or capability change.&lt;/text&gt;
85     &lt;/description&gt;
86     &lt;container name="changed-by"&gt;
87       &lt;description&gt;
88         &lt;text&gt;Indicates the source of the change.
89 If caused by internal action, then the
90 empty leaf 'server' will be present.
91 If caused by a management session, then
92 the name, remote host address, and session ID
93 of the session that made the change will be reported.&lt;/text&gt;
94       &lt;/description&gt;
95       &lt;choice name="server-or-user"&gt;
96         &lt;mandatory value="true"/&gt;
97         &lt;leaf name="server"&gt;
98           &lt;type name="empty"/&gt;
99           &lt;description&gt;
100             &lt;text&gt;If present, the change was caused
101 by the server.&lt;/text&gt;
102           &lt;/description&gt;
103         &lt;/leaf&gt;
104         &lt;case name="by-user"&gt;
105           &lt;uses name="common-session-parms"/&gt;
106         &lt;/case&gt;
107       &lt;/choice&gt;
108     &lt;/container&gt;
109   &lt;/grouping&gt;
110   &lt;notification name="netconf-config-change"&gt;
111     &lt;description&gt;
112       &lt;text&gt;Generated when the NETCONF server detects that the
113 &amp;lt;running&amp;gt; or &amp;lt;startup&amp;gt; configuration datastore
114 has been changed by a management session.
115 The notification summarizes the edits that
116 have been detected.
117 The server MAY choose to also generate this
118 notification while loading a datastore during the
119 boot process for the device.&lt;/text&gt;
120     &lt;/description&gt;
121     &lt;uses name="changed-by-parms"/&gt;
122     &lt;leaf name="datastore"&gt;
123       &lt;type name="enumeration"&gt;
124         &lt;enum name="running"&gt;
125           &lt;description&gt;
126             &lt;text&gt;The &amp;lt;running&amp;gt; datastore has changed.&lt;/text&gt;
127           &lt;/description&gt;
128         &lt;/enum&gt;
129         &lt;enum name="startup"&gt;
130           &lt;description&gt;
131             &lt;text&gt;The &amp;lt;startup&amp;gt; datastore has changed&lt;/text&gt;
132           &lt;/description&gt;
133         &lt;/enum&gt;
134       &lt;/type&gt;
135       &lt;default value="running"/&gt;
136       &lt;description&gt;
137         &lt;text&gt;Indicates which configuration datastore has changed.&lt;/text&gt;
138       &lt;/description&gt;
139     &lt;/leaf&gt;
140     &lt;list name="edit"&gt;
141       &lt;description&gt;
142         &lt;text&gt;An edit record SHOULD be present for each distinct
143 edit operation that the server has detected on
144 the target datastore.  This list MAY be omitted
145 if the detailed edit operations are not known.
146 The server MAY report entries in this list for
147 changes not made by a NETCONF session (e.g., CLI).&lt;/text&gt;
148       &lt;/description&gt;
149       &lt;leaf name="target"&gt;
150         &lt;type name="instance-identifier"/&gt;
151         &lt;description&gt;
152           &lt;text&gt;Topmost node associated with the configuration change.
153 A server SHOULD set this object to the node within
154 the datastore that is being altered.  A server MAY
155 set this object to one of the ancestors of the actual
156 node that was changed, or omit this object, if the
157 exact node is not known.&lt;/text&gt;
158         &lt;/description&gt;
159       &lt;/leaf&gt;
160       &lt;leaf name="operation"&gt;
161         &lt;type name="nc:edit-operation-type"/&gt;
162         &lt;description&gt;
163           &lt;text&gt;Type of edit operation performed.
164 A server MUST set this object to the NETCONF edit
165 operation performed on the target datastore.&lt;/text&gt;
166         &lt;/description&gt;
167       &lt;/leaf&gt;
168     &lt;/list&gt;
169   &lt;/notification&gt;
170   &lt;notification name="netconf-capability-change"&gt;
171     &lt;description&gt;
172       &lt;text&gt;Generated when the NETCONF server detects that
173 the server capabilities have changed.
174 Indicates which capabilities have been added, deleted,
175 and/or modified.  The manner in which a server
176 capability is changed is outside the scope of this
177 document.&lt;/text&gt;
178     &lt;/description&gt;
179     &lt;uses name="changed-by-parms"/&gt;
180     &lt;leaf-list name="added-capability"&gt;
181       &lt;type name="inet:uri"/&gt;
182       &lt;description&gt;
183         &lt;text&gt;List of capabilities that have just been added.&lt;/text&gt;
184       &lt;/description&gt;
185     &lt;/leaf-list&gt;
186     &lt;leaf-list name="deleted-capability"&gt;
187       &lt;type name="inet:uri"/&gt;
188       &lt;description&gt;
189         &lt;text&gt;List of capabilities that have just been deleted.&lt;/text&gt;
190       &lt;/description&gt;
191     &lt;/leaf-list&gt;
192     &lt;leaf-list name="modified-capability"&gt;
193       &lt;type name="inet:uri"/&gt;
194       &lt;description&gt;
195         &lt;text&gt;List of capabilities that have just been modified.
196 A capability is considered to be modified if the
197 base URI for the capability has not changed, but
198 one or more of the parameters encoded at the end of
199 the capability URI have changed.
200 The new modified value of the complete URI is returned.&lt;/text&gt;
201       &lt;/description&gt;
202     &lt;/leaf-list&gt;
203   &lt;/notification&gt;
204   &lt;notification name="netconf-session-start"&gt;
205     &lt;description&gt;
206       &lt;text&gt;Generated when a NETCONF server detects that a
207 NETCONF session has started.  A server MAY generate
208 this event for non-NETCONF management sessions.
209 Indicates the identity of the user that started
210 the session.&lt;/text&gt;
211     &lt;/description&gt;
212     &lt;uses name="common-session-parms"/&gt;
213   &lt;/notification&gt;
214   &lt;notification name="netconf-session-end"&gt;
215     &lt;description&gt;
216       &lt;text&gt;Generated when a NETCONF server detects that a
217 NETCONF session has terminated.
218 A server MAY optionally generate this event for
219 non-NETCONF management sessions.  Indicates the
220 identity of the user that owned the session,
221 and why the session was terminated.&lt;/text&gt;
222     &lt;/description&gt;
223     &lt;uses name="common-session-parms"/&gt;
224     &lt;leaf name="killed-by"&gt;
225       &lt;when condition="../termination-reason = 'killed'"/&gt;
226       &lt;type name="nc:session-id-type"/&gt;
227       &lt;description&gt;
228         &lt;text&gt;The ID of the session that directly caused this session
229 to be abnormally terminated.  If this session was abnormally
230 terminated by a non-NETCONF session unknown to the server,
231 then this leaf will not be present.&lt;/text&gt;
232       &lt;/description&gt;
233     &lt;/leaf&gt;
234     &lt;leaf name="termination-reason"&gt;
235       &lt;type name="enumeration"&gt;
236         &lt;enum name="closed"&gt;
237           &lt;description&gt;
238             &lt;text&gt;The session was terminated by the client in normal
239 fashion, e.g., by the NETCONF &amp;lt;close-session&amp;gt;
240 protocol operation.&lt;/text&gt;
241           &lt;/description&gt;
242         &lt;/enum&gt;
243         &lt;enum name="killed"&gt;
244           &lt;description&gt;
245             &lt;text&gt;The session was terminated in abnormal
246 fashion, e.g., by the NETCONF &amp;lt;kill-session&amp;gt;
247 protocol operation.&lt;/text&gt;
248           &lt;/description&gt;
249         &lt;/enum&gt;
250         &lt;enum name="dropped"&gt;
251           &lt;description&gt;
252             &lt;text&gt;The session was terminated because the transport layer
253 connection was unexpectedly closed.&lt;/text&gt;
254           &lt;/description&gt;
255         &lt;/enum&gt;
256         &lt;enum name="timeout"&gt;
257           &lt;description&gt;
258             &lt;text&gt;The session was terminated because of inactivity,
259 e.g., waiting for the &amp;lt;hello&amp;gt; message or &amp;lt;rpc&amp;gt;
260 messages.&lt;/text&gt;
261           &lt;/description&gt;
262         &lt;/enum&gt;
263         &lt;enum name="bad-hello"&gt;
264           &lt;description&gt;
265             &lt;text&gt;The client's &amp;lt;hello&amp;gt; message was invalid.&lt;/text&gt;
266           &lt;/description&gt;
267         &lt;/enum&gt;
268         &lt;enum name="other"&gt;
269           &lt;description&gt;
270             &lt;text&gt;The session was terminated for some other reason.&lt;/text&gt;
271           &lt;/description&gt;
272         &lt;/enum&gt;
273       &lt;/type&gt;
274       &lt;mandatory value="true"/&gt;
275       &lt;description&gt;
276         &lt;text&gt;Reason the session was terminated.&lt;/text&gt;
277       &lt;/description&gt;
278     &lt;/leaf&gt;
279   &lt;/notification&gt;
280   &lt;notification name="netconf-confirmed-commit"&gt;
281     &lt;description&gt;
282       &lt;text&gt;Generated when a NETCONF server detects that a
283 confirmed-commit event has occurred.  Indicates the event
284 and the current state of the confirmed-commit procedure
285 in progress.&lt;/text&gt;
286     &lt;/description&gt;
287     &lt;reference&gt;
288       &lt;text&gt;RFC 6241, Section 8.4&lt;/text&gt;
289     &lt;/reference&gt;
290     &lt;uses name="common-session-parms"&gt;
291       &lt;when condition="confirm-event != 'timeout'"/&gt;
292     &lt;/uses&gt;
293     &lt;leaf name="confirm-event"&gt;
294       &lt;type name="enumeration"&gt;
295         &lt;enum name="start"&gt;
296           &lt;description&gt;
297             &lt;text&gt;The confirmed-commit procedure has started.&lt;/text&gt;
298           &lt;/description&gt;
299         &lt;/enum&gt;
300         &lt;enum name="cancel"&gt;
301           &lt;description&gt;
302             &lt;text&gt;The confirmed-commit procedure has been canceled,
303 e.g., due to the session being terminated, or an
304 explicit &amp;lt;cancel-commit&amp;gt; operation.&lt;/text&gt;
305           &lt;/description&gt;
306         &lt;/enum&gt;
307         &lt;enum name="timeout"&gt;
308           &lt;description&gt;
309             &lt;text&gt;The confirmed-commit procedure has been canceled
310 due to the confirm-timeout interval expiring.
311 The common session parameters will not be present
312 in this sub-mode.&lt;/text&gt;
313           &lt;/description&gt;
314         &lt;/enum&gt;
315         &lt;enum name="extend"&gt;
316           &lt;description&gt;
317             &lt;text&gt;The confirmed-commit timeout has been extended,
318 e.g., by a new &amp;lt;confirmed-commit&amp;gt; operation.&lt;/text&gt;
319           &lt;/description&gt;
320         &lt;/enum&gt;
321         &lt;enum name="complete"&gt;
322           &lt;description&gt;
323             &lt;text&gt;The confirmed-commit procedure has been completed.&lt;/text&gt;
324           &lt;/description&gt;
325         &lt;/enum&gt;
326       &lt;/type&gt;
327       &lt;mandatory value="true"/&gt;
328       &lt;description&gt;
329         &lt;text&gt;Indicates the event that caused the notification.&lt;/text&gt;
330       &lt;/description&gt;
331     &lt;/leaf&gt;
332     &lt;leaf name="timeout"&gt;
333       &lt;when condition="../confirm-event = 'start' or ../confirm-event = 'extend'"/&gt;
334       &lt;type name="uint32"/&gt;
335       &lt;units name="seconds"/&gt;
336       &lt;description&gt;
337         &lt;text&gt;The configured timeout value if the event type
338 is 'start' or 'extend'.  This value represents
339 the approximate number of seconds from the event
340 time when the 'timeout' event might occur.&lt;/text&gt;
341       &lt;/description&gt;
342     &lt;/leaf&gt;
343   &lt;/notification&gt;
344 &lt;/module&gt;
345 </data>
346 </rpc-reply>