1 module opendaylight-flow-statistics {
2 namespace "urn:opendaylight:flow:statistics";
5 import yang-ext {prefix ext; revision-date "2013-07-09";}
6 import opendaylight-inventory {prefix inv;revision-date "2013-08-19";}
7 import opendaylight-flow-types {prefix flow-types;revision-date "2013-10-26";}
8 import opendaylight-statistics-types {prefix stat-types;revision-date "2013-09-25";}
9 import opendaylight-table-types {prefix table-types;revision-date "2013-10-26";}
10 import flow-node-inventory {prefix flow-node;revision-date "2013-08-19";}
11 import flow-capable-transaction {prefix tr;}
12 import ietf-inet-types {prefix inet; revision-date "2010-09-24";}
15 revision "2013-08-19" {
16 description "Initial revision of flow statistics service";
19 //Augment flow statistics data to the flow-capable-node->table->flow
20 augment "/inv:nodes/inv:node/flow-node:table/flow-node:flow" {
21 ext:augment-identifier "flow-statistics-data";
25 grouping flow-statistics {
26 container flow-statistics {
28 uses stat-types:generic-statistics;
33 description "flow id";
37 grouping flow-and-statistics-map-list {
38 description "List of flow and statistics map";
39 list flow-and-statistics-map-list {
44 uses flow-and-statistics-map;
48 grouping flow-and-statistics-map{
49 description "Mapping between flow and its statistics";
51 uses stat-types:generic-statistics;
54 // RPC calls to fetch flow statistics
55 rpc get-all-flows-statistics-from-all-flow-tables {
56 description "Fetch statistics of all the flow present in all the flow tables of the switch";
58 uses inv:node-context-ref;
61 uses flow-and-statistics-map-list;
62 uses tr:transaction-aware;
67 rpc get-all-flow-statistics-from-flow-table {
68 description "Fetch statistics of all the flow present in the specific flow table of the switch";
70 uses inv:node-context-ref;
72 type table-types:table-id;
76 uses flow-and-statistics-map-list;
77 uses tr:transaction-aware;
81 rpc get-flow-statistics-from-flow-table {
82 description "Fetch statistics of the specific flow present in the specific flow table of the switch";
84 uses inv:node-context-ref;
88 uses flow-and-statistics-map-list;
89 uses tr:transaction-aware;
93 notification flows-statistics-update {
94 description "Flows statistics sent by switch";
99 uses flow-and-statistics-map-list;
100 uses tr:transaction-aware;
103 //Models for aggregate flow statistics collection
104 augment "/inv:nodes/inv:node/flow-node:table" {
105 ext:augment-identifier "aggregate-flow-statistics-data";
106 uses aggregate-flow-statistics;
109 grouping aggregate-flow-statistics {
110 container aggregate-flow-statistics {
112 uses stat-types:aggregate-flow-statistics;
116 // RPC calls to fetch aggregate flow statistics
117 rpc get-aggregate-flow-statistics-from-flow-table-for-all-flows {
118 description "Fetch aggregate statistics for all the flows present in the specific flow table of the switch";
120 uses inv:node-context-ref;
122 type table-types:table-id;
126 uses stat-types:aggregate-flow-statistics;
127 uses tr:transaction-aware;
130 rpc get-aggregate-flow-statistics-from-flow-table-for-given-match {
131 description "Fetch aggregate statistics for all the flow matches to the given match from the given table of the switch";
133 uses inv:node-context-ref;
134 uses flow-types:flow;
137 uses stat-types:aggregate-flow-statistics;
138 uses tr:transaction-aware;
142 notification aggregate-flow-statistics-update {
143 description "Aggregate flow statistics for a table, sent by switch";
145 uses stat-types:aggregate-flow-statistics;
146 uses tr:multipart-transaction-aware;