Removed tab space from group models and formatted the same.
Signed-off-by: Prasanna Huddar <prasanna.huddar@ericsson.com>
Change-Id: I2415ac716c344ae308907f708da3d1f3b5559093
import ietf-inet-types {prefix inet;}
import ietf-yang-types {prefix yang;}
- import opendaylight-flow-types {prefix flow-types;}
+ import opendaylight-flow-types {prefix flow-types;}
- revision "2013-09-17" {
+ revision "2013-09-18" {
description "Initial revision of group service";
}
- typedef group-ref {
- type instance-identifier;
- }
-
- grouping group-types {
- leaf group-type {
- type enumeration {
- enum group-all;
- enum group_select;
- enum group_indirect;
- enum group_ff;
- }
- }
- }
-
- grouping group {
+ typedef group-ref {
+ type instance-identifier;
+ }
+
+ grouping group-types {
+ leaf group-type {
+ type enumeration {
+ enum group-all;
+ enum group_select;
+ enum group_indirect;
+ enum group_ff;
+ }
+ }
+ }
+
+ grouping group {
uses group-types;
-
- leaf group-id {
+
+ leaf group-id {
type group-ref;
}
-
- container buckets {
- list bucket {
- key "order";
- leaf order {
- type int32;
- }
-
- leaf weight {
- type uint16;
- }
-
- leaf watch_port {
- type uint32;
- }
-
- leaf watch_group {
- type uint32;
- }
-
- container actions {
- list action {
- key "action-order";
- leaf action-order {
- type int32;
- }
+
+ container buckets {
+ list bucket {
+ key "order";
+ leaf order {
+ type int32;
+ }
+
+ leaf weight {
+ type uint16;
+ }
+
+ leaf watch_port {
+ type uint32;
+ }
+
+ leaf watch_group {
+ type uint32;
+ }
+
+ container actions {
+ list action {
+ key "action-order";
+ leaf action-order {
+ type int32;
+ }
+
+ uses flow-types:action;
+ }
+ }
+ }
+ }
+ }
+
+ grouping group-statistics-request {
+ list group-stats {
+ key "group-id";
- uses flow-types:action;
- }
- }
- }
- }
+ leaf group-id {
+ type int32;
+ }
+ }
}
-
- grouping group-statistics-request {
- list group-stats {
- key "group-id";
-
- leaf group-id {
- type int32;
- }
- }
- }
-
- grouping group-statistics {
-
- leaf group-id {
+
+ grouping group-statistics {
+
+ leaf group-id {
type int32;
- }
-
- leaf ref-count {
+ }
+
+ leaf ref-count {
type yang:counter32;
- }
-
- leaf packet-count {
+ }
+
+ leaf packet-count {
type yang:counter64;
}
-
+
leaf byte-count {
type yang:counter64;
}
type yang:counter32;
}
}
-
- container buckets {
- list bucket-counter {
- key "order";
- leaf order {
- type int32;
- }
-
- leaf packet-count {
- type yang:counter64;
- }
-
- leaf byte-count {
- type yang:counter64;
- }
- }
- }
+
+ container buckets {
+ list bucket-counter {
+ key "order";
+ leaf order {
+ type int32;
+ }
+
+ leaf packet-count {
+ type yang:counter64;
+ }
+
+ leaf byte-count {
+ type yang:counter64;
+ }
+ }
+ }
}
- grouping group-statistics-reply {
- list group-stats {
- key "group-stats-order";
- leaf group-stats-order {
- type int32;
- }
-
- uses group-statistics;
- }
- }
-
- grouping group-desc-stats {
- list group-desc-stats {
- key "order-id";
-
- leaf order-id {
- type int32;
- }
-
- uses group;
- }
- }
-
+ grouping group-statistics-reply {
+ list group-stats {
+ key "group-stats-order";
+ leaf group-stats-order {
+ type int32;
+ }
+
+ uses group-statistics;
+ }
+ }
+
+ grouping group-desc-stats {
+ list group-desc-stats {
+ key "order-id";
+
+ leaf order-id {
+ type int32;
+ }
+
+ uses group;
+ }
+ }
+
grouping group-features {
- list group-features {
- key "order";
- leaf order {
- type int32;
- }
-
- uses group-types;
- type capabilities {
- enum select-weight;
- enum select-liveness;
- enum chaining;
- enum chaining-checks;
- }
+ list group-features {
+ key "order";
+ leaf order {
+ type int32;
+ }
+
+ uses group-types;
+ type capabilities {
+ enum select-weight;
+ enum select-liveness;
+ enum chaining;
+ enum chaining-checks;
+ }
- leaf-list max-groups {
- type uint32;
- description "Maximum number of groups for each type";
- max-elements 4;
- }
-
- leaf-list actions {
- type uint32;
- description "Bitmap number OFPAT_* that are supported";
- max-elements 4;
- }
- }
- }
+ leaf-list max-groups {
+ type uint32;
+ description "Maximum number of groups for each type";
+ max-elements 4;
+ }
+
+ leaf-list actions {
+ type uint32;
+ description "Bitmap number OFPAT_* that are supported";
+ max-elements 4;
+ }
+ }
+ }
}
\ No newline at end of file
--- /dev/null
+module opendaylight-meter-types {
+ namespace "urn:opendaylight:meter:types";
+ prefix meter;
+
+ import ietf-inet-types {prefix inet;}
+ import ietf-yang-types {prefix yang;}
+
+
+ revision "2013-09-18" {
+ description "Initial revision of meter service";
+ }
+
+ typedef meter-ref {
+ type instance-identifier;
+ }
+
+ grouping meter-flags {
+ leaf flags {
+ type enumeration {
+ enum meter-kbps;
+ enum meter_pktps;
+ enum meter_burst;
+ enum meter_stats;
+ }
+ }
+ }
+
+ grouping meter-band-type {
+ leaf flags {
+ type enumeration {
+ enum ofpmbt-drop;
+ enum ofpmbt-dscp-remark;
+ enum ofpmbt-experimenter;
+ }
+ }
+ }
+
+ grouping band-type {
+ choice band-type {
+ case drop {
+ leaf rate {
+ type uint32;
+ }
+
+ leaf burst-size {
+ type uint32;
+ }
+ }
+
+ case dscp-remark {
+ leaf rate {
+ type uint32;
+ }
+
+ leaf burst-size {
+ type uint32;
+ }
+
+ leaf perc_level {
+ type uint8;
+ }
+ }
+
+ case experimenter {
+ leaf rate {
+ type uint32;
+ }
+
+ leaf burst-size {
+ type uint32;
+ }
+
+ leaf experimenter {
+ type uint32;
+ }
+ }
+ }
+ }
+
+ grouping meter {
+
+ uses meter-flags;
+
+ leaf meter-id {
+ type meter-ref;
+ }
+
+ container meter-band-headers {
+ list meter-band-header {
+ key "order";
+ leaf order {
+ type int32;
+ }
+
+ container meter-band-types {
+ uses meter-band-type;
+ }
+
+ leaf burst-size {
+ type uint32;
+ }
+ uses band-type;
+ }
+ }
+ }
+
+ grouping meter-stats-config-request {
+ list meter-stats {
+ key "meter-id";
+
+ leaf meter-id {
+ type int32;
+ }
+ }
+ }
+
+ grouping meter-statistics {
+
+ leaf meter-id {
+ type int32;
+ }
+
+ leaf flow-count {
+ type yang:counter32;
+ }
+
+ leaf packet-in-count {
+ type yang:counter64;
+ }
+
+ leaf byte-in-count {
+ type yang:counter64;
+ }
+
+ container duration {
+ leaf second {
+ type yang:counter32;
+ }
+ leaf nanosecond {
+ type yang:counter32;
+ }
+ }
+
+ container meter-band-stats {
+ list band-stat {
+ key "order";
+ leaf order {
+ type int32;
+ }
+
+ leaf packet-band-count {
+ type yang:counter64;
+ }
+
+ leaf byte-band-count {
+ type yang:counter64;
+ }
+ }
+ }
+ }
+
+ grouping meter-statistics-reply {
+ list meter-stats {
+ key "meter-stats-order";
+ leaf meter-stats-order {
+ type int32;
+ }
+ uses meter-statistics;
+ }
+ }
+
+ grouping meter-config-stats {
+ list meter-config-stats {
+ key "meter-config-order";
+
+ leaf meter-config-order {
+ type int32;
+ }
+
+ uses meter;
+ }
+ }
+
+ grouping meter-features {
+ list meter-features {
+ key "meter-feature-order";
+
+ leaf meter-feature-order {
+ type yang:counter32;
+ }
+
+ leaf max_meter {
+ type yang:counter32;
+ }
+
+ leaf band_types {
+ type yang:counter32;
+ }
+
+ leaf capabilities {
+ type yang:counter32;
+ }
+
+ leaf max_bands {
+ type uint8;
+ }
+
+ leaf max_color {
+ type uint8;
+ }
+ }
+ }
+}
\ No newline at end of file
import ietf-inet-types {prefix inet;}
import opendaylight-group-types {prefix group-type;}
- revision "2013-09-17" {
+ revision "2013-09-18" {
description "Initial revision of group service";
}
-
+
grouping node-group {
leaf node {
type inv:node-ref;
--- /dev/null
+module sal-meter {
+ namespace "urn:opendaylight:meter:service";
+ prefix meter;
+
+ import yang-ext {prefix ext;}
+ import opendaylight-inventory {prefix inv;}
+ import ietf-inet-types {prefix inet;}
+ import opendaylight-meter-types {prefix meter-type;}
+
+ revision "2013-09-18" {
+ description "Initial revision of meter service";
+ }
+
+ metering node-meter {
+ leaf node {
+ type inv:node-ref;
+ }
+
+ uses meter-type:meter;
+ }
+
+ /** Base configuration structure **/
+ metering meter-update {
+ container original-meter {
+ uses meter-type:meter;
+ }
+ container updated-meter {
+ uses meter-type:meter;
+ }
+ }
+
+ rpc add-meter {
+ input {
+ uses node-meter;
+ }
+ }
+
+ rpc remove-meter {
+ input {
+ uses node-meter;
+ }
+ }
+
+ rpc update-meter {
+ input {
+ uses node-meter;
+ }
+ }
+}
\ No newline at end of file