Rome hackathon work integrated onto boron. 55/39355/5
authorDonald Hunter <donaldh@cisco.com>
Fri, 20 May 2016 21:42:47 +0000 (22:42 +0100)
committerDonald Hunter <donaldh@cisco.com>
Thu, 2 Jun 2016 13:27:13 +0000 (14:27 +0100)
This patch contains the start of implementing the MEF NRP YANG model. The patch introduces  a framework for multiple backend drivers and provides a first implementation of a Cisco XR Netconf driver.

Everything here is a work in progress from several collaborators at the MEF Rome Hackathon, including:

Alex Feigin from HPE
Bartosz Michalik from Amartus
Sean Condon from Microsemi
Donald Hunter from Cisco

Next steps include
* refining the MEF YANG model
* refactoring drivers into separate OSGi bundles
* refactoring OVSDB backend into same driver framework.

This patch set includes the changes in response to code review comments provided by Alexis de TalhouĆ«t.

Change-Id: I305ef61a622334cdb7a8ab0a878cdb704ea5d032
Signed-off-by: Donald Hunter <donaldh@cisco.com>
91 files changed:
.gitignore
README.md [new file with mode: 0644]
api/src/main/yang/CoreModel-CoreFoundationModule-StateModel.yang [new file with mode: 0644]
api/src/main/yang/CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages.yang [new file with mode: 0644]
api/src/main/yang/CoreModel-CoreFoundationModule-TypeDefinitions.yang [new file with mode: 0644]
api/src/main/yang/CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed.yang [new file with mode: 0644]
api/src/main/yang/CoreModel-CoreModelEnhancements-InformationArchitectureAndPatterns.yang [new file with mode: 0644]
api/src/main/yang/CoreModel-CoreModelEnhancements-InterViewRelationships_Sketch.yang [new file with mode: 0644]
api/src/main/yang/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule.yang [new file with mode: 0644]
api/src/main/yang/CoreModel-CoreModelEnhancements-ViewAbstractionRule_Sketch.yang [new file with mode: 0644]
api/src/main/yang/CoreModel-CoreNetworkModule-ObjectClasses.yang [new file with mode: 0644]
api/src/main/yang/CoreModel-CoreNetworkModule-TypeDefinitions.yang [new file with mode: 0644]
api/src/main/yang/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage.yang [new file with mode: 0644]
api/src/main/yang/NRP_Interface-ObjectClasses-NRP_SpecPackage.yang [new file with mode: 0644]
api/src/main/yang/NRP_Interface-ObjectClasses-TopologyPacs.yang [new file with mode: 0644]
api/src/main/yang/NRP_Interface-TypeDefinitions-NRP_Types.yang [new file with mode: 0644]
api/src/main/yang/NRP_Interface-TypeDefinitions-TopologyPacs.yang [new file with mode: 0644]
api/src/main/yang/NRP_Interface-TypeDefinitions.yang [new file with mode: 0644]
api/src/main/yang/NetworkResource-Main-ObjectClasses.yang [new file with mode: 0644]
artifacts/pom.xml
cisco-xr-driver/pom.xml [new file with mode: 0644]
cisco-xr-driver/src/main/config/default-config.xml [new file with mode: 0755]
cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/CiscoXRDriverProvider.java [new file with mode: 0644]
cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnBridgeActivator.java [new file with mode: 0644]
cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnBridgeDriverBuilder.java [new file with mode: 0644]
cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnXconnectActivator.java [new file with mode: 0644]
cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnXconnectDriverBuilder.java [new file with mode: 0644]
cisco-xr-driver/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/unimgr/cisco/xr/driver/impl/rev160518/UnimgrXRDriverModule.java [new file with mode: 0644]
cisco-xr-driver/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/unimgr/cisco/xr/driver/impl/rev160518/UnimgrXRDriverModuleFactory.java [new file with mode: 0644]
cisco-xr-driver/src/main/yang/unimgr-cisco-xr-driver-impl.yang [new file with mode: 0755]
cisco-xrmodels/pom.xml [new file with mode: 0644]
cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/asr9k/policymgr/cfg/rev150518/IdleTimeoutBuilder.java [new file with mode: 0644]
cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/asr9k/policymgr/cfg/rev150518/PrecedenceBuilder.java [new file with mode: 0644]
cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrAnyBuilder.java [new file with mode: 0644]
cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrCvpBuilder.java [new file with mode: 0644]
cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrNativeBuilder.java [new file with mode: 0644]
cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrNullBuilder.java [new file with mode: 0644]
cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/snmp/agent/cfg/rev151027/SnmpDscpValueBuilder.java [new file with mode: 0644]
cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/snmp/agent/cfg/rev151027/SnmpPrecedenceValue1Builder.java [new file with mode: 0644]
cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/xr/types/rev150629/CharNumBuilder.java [new file with mode: 0644]
cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/xr/types/rev150629/TtyEscapeCharNumBuilder.java [new file with mode: 0644]
cisco-xrmodels/src/main/yang/Cisco-IOS-XR-asr9k-policymgr-cfg@2015-05-18.yang [new file with mode: 0644]
cisco-xrmodels/src/main/yang/Cisco-IOS-XR-ifmgr-cfg@2015-07-30.yang [new file with mode: 0644]
cisco-xrmodels/src/main/yang/Cisco-IOS-XR-ip-static-cfg@2015-09-10.yang [new file with mode: 0644]
cisco-xrmodels/src/main/yang/Cisco-IOS-XR-l2-eth-infra-cfg@2015-11-09.yang [new file with mode: 0644]
cisco-xrmodels/src/main/yang/Cisco-IOS-XR-l2-eth-infra-datatypes@2015-11-09.yang [new file with mode: 0644]
cisco-xrmodels/src/main/yang/Cisco-IOS-XR-l2vpn-cfg@2015-11-09.yang [new file with mode: 0644]
cisco-xrmodels/src/main/yang/Cisco-IOS-XR-snmp-agent-cfg@2015-10-27.yang [new file with mode: 0644]
cisco-xrmodels/src/main/yang/Cisco-IOS-XR-types@2015-06-29.yang [new file with mode: 0644]
edgeassure-1000/pom.xml [new file with mode: 0644]
edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/HostBuilder.java [new file with mode: 0644]
edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/IpAddressBuilder.java [new file with mode: 0644]
edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/IpAddressNoZoneBuilder.java [new file with mode: 0644]
edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/IpPrefixBuilder.java [new file with mode: 0644]
edgeassure-1000/src/main/yang/ENTITY-STATE-TC-MIB@2005-11-22.yang [new file with mode: 0644]
edgeassure-1000/src/main/yang/msea-types@2016-02-29.yang [new file with mode: 0644]
edgeassure-1000/src/main/yang/msea-uni-evc-interface@2016-03-17.yang [new file with mode: 0644]
edgeassure-1000/src/main/yang/msea-uni-evc-service@2016-03-17.yang [new file with mode: 0644]
features/pom.xml
features/src/main/features/features.xml
impl/pom.xml
impl/src/main/java/org/mef/nrp/impl/ActivationDriver.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/ActivationDriverAmbiguousException.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/ActivationDriverBuilder.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/ActivationDriverNotFoundException.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/ActivationDriverRepoService.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/ActivationDriverRepoServiceImpl.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/ActivationTransaction.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/DummyActivationDriver.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/EdgeAssureActivator.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/EdgeAssureDriverBuilder.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/FixedServiceNaming.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/ForwardingConstructHelper.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/MountPointHelper.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/ResourceActivator.java [new file with mode: 0644]
impl/src/main/java/org/mef/nrp/impl/ServiceNaming.java [new file with mode: 0644]
impl/src/main/java/org/opendaylight/unimgr/impl/FCRouteChangeListener.java [new file with mode: 0644]
impl/src/main/java/org/opendaylight/unimgr/impl/FcRouteActivatorService.java [new file with mode: 0644]
impl/src/main/java/org/opendaylight/unimgr/impl/UnimgrProvider.java
impl/src/test/java/org/opendaylight/unimgr/command/DataTreeModificationHelper.java
impl/src/test/java/org/opendaylight/unimgr/impl/EvcDataTreeChangeListenerTest.java
impl/src/test/java/org/opendaylight/unimgr/impl/UniDataTreeChangeListenerTest.java
it/pom.xml
karaf/pom.xml
pom.xml
restclient/README.md [new file with mode: 0644]
restclient/cisco-xr-lab-device.txt [new file with mode: 0644]
restclient/msea1000.postman_collection [new file with mode: 0644]
restclient/nrp-fcroute.txt [new file with mode: 0644]
restclient/nrp-fcspec.txt [new file with mode: 0644]
restclient/unimgr.txt [new file with mode: 0644]

index b7089ba278d6c42b80573c3fe8200c874a4cfdf4..67df13643faceb1d62cb036d3ec9a17cab31640d 100644 (file)
@@ -29,3 +29,4 @@ maven-eclipse.xml
 .checkstyle
 *.html
 maven-metadata-local.xml
+\#*#
diff --git a/README.md b/README.md
new file mode 100644 (file)
index 0000000..27895bc
--- /dev/null
+++ b/README.md
@@ -0,0 +1,41 @@
+unimgr
+------
+
+
+#### Create FcRoute
+```
+POST :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList
+Authorization: :basic-auth
+Content-Type: application/json
+{
+   "FcRoute": {
+       "id" : "new-route",
+       "ForwardingConstruct": [
+       {
+          "uuid": "an-original-name",
+          "FcPort": [ {
+                     "id": "a-end",
+                     "_ltpRefList": [ "host-a:a-end-ltp" ]
+                     }, {
+                     "id": "z-end",
+                     "_ltpRefList": [ "host-z:z-end-ltp" ]
+                     } ],
+          "forwardingDirection": "BIDIRECTIONAL",
+          "layerProtocolName": "funky-layer-protocol",
+          "_fcSpecRef": "nonexistent-fcspec"
+       }
+   ] }
+}
+```
+
+#### Delete FcRoute
+```
+DELETE :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList/FcRoute/new-route
+Authentication: :basic-auth
+```
+
+#### List FcRoute
+```
+GET :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList
+Authorization: :basic-auth
+```
diff --git a/api/src/main/yang/CoreModel-CoreFoundationModule-StateModel.yang b/api/src/main/yang/CoreModel-CoreFoundationModule-StateModel.yang
new file mode 100644 (file)
index 0000000..88cb9c0
--- /dev/null
@@ -0,0 +1,69 @@
+module CoreModel-CoreFoundationModule-StateModel {
+    namespace "uri:onf:CoreModel-CoreFoundationModule-StateModel";
+    prefix CoreModel-CoreFoundationModule-StateModel;
+    revision 2016-04-13{}
+    grouping G_State_Pac {
+        status current;
+        leaf operationalState {
+            type OperationalState;
+            config false;
+            description "The operational state is used to indicate whether or not the resource is installed and working";
+        }
+        leaf administrativeControl {
+            type AdministrativeControl;
+            description "The administrativeControl state provides control of the availability of specific resources without modification to the provisioning of those resources.
+The value is the current control target. The actual administrativeState may or may not be at target.";
+        }
+        leaf adminsatratveState {
+            type AdministrativeState;
+            config false;
+            description "Shows whether or not the client has permission to use or has a prohibition against using the resource.
+The administrative state expresses usage permissions for specific resources without modification to the provisioning of those resources.";
+        }
+        leaf lifecycleState {
+            type LifecycleState;
+            description "Used to track the planned deployment, allocation to clients and withdrawal of resources. ";
+        }
+    }
+    typedef OperationalState {
+        status current;
+        type enumeration {
+            enum DISABLED;
+            enum ENABLED;
+        }
+    }
+    typedef AdministrativeState {
+        status current;
+        type enumeration {
+            enum LOCKED;
+            enum UNLOCKED;
+        }
+    }
+    typedef AdministrativeControl {
+        status deprecated;
+        type enumeration {
+            enum UNLOCK;
+            enum LOCK_PASSIVE;
+            enum LOCK_ACTIVE;
+            enum LOCK_IMMEDIATE;
+        }
+    }
+    typedef ExtendedAdminState {
+        status deprecated;
+        type enumeration {
+            enum LOCKED;
+            enum UNLOCKED;
+            enum SHUTTING_DOWN_ACTIVE;
+            enum SHUTTING_DOWN_PASSIVE;
+        }
+    }
+    typedef LifecycleState {
+        status deprecated;
+        type enumeration {
+            enum PLANNED;
+            enum POTENTIAL;
+            enum INSTALLED;
+            enum PENDING_REMOVAL;
+        }
+    }
+}
diff --git a/api/src/main/yang/CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages.yang b/api/src/main/yang/CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages.yang
new file mode 100644 (file)
index 0000000..cc54739
--- /dev/null
@@ -0,0 +1,129 @@
+module CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages {
+    namespace "uri:onf:CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages";
+    prefix CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages;
+    import CoreModel-CoreFoundationModule-StateModel {
+        prefix CoreModel-CoreFoundationModule-StateModel;
+    }
+    revision 2016-04-13{}
+    grouping G_Name {
+        list nameList {
+            description "List of names.";
+            key 'theValue';
+            config true;
+            ordered-by system;
+            uses G_NameAndValue;
+            min-elements 1;
+        }
+    }
+    list GlobalClass {
+        key 'uuid';
+        config true;
+        ordered-by system;
+        uses G_GlobalClass;
+    }
+    grouping G_GlobalClass {
+        uses G_Name;
+        uses G_Label;
+        uses G_Extension;
+        uses CoreModel-CoreFoundationModule-StateModel:G_State_Pac;
+        list localIdList {
+            description "An identifier that is unique in the context of some scope that is less than the global scope.
+
+(consider in the context of Identifier: A property of an entity/role with a value that is unique within an identifier space, where the identifier space is itself unique, and immutable. The identifier therefore represents the identity of the entity/role. An identifier carries no semantics with respect to the purpose of the entity.)";
+            key 'theValue';
+            config true;
+            ordered-by system;
+            uses G_NameAndValue;
+        }
+        leaf uuid {
+            type UniversalId;
+            description "UUID: An identifier that is universally unique
+
+(consider in the context of Identifier: A property of an entity/role with a value that is unique within an identifier space, where the identifier space is itself globally unique, and immutable. An identifier carries no semantics with respect to the purpose or state of the entity)";
+        }
+    }
+    grouping G_LocalClass {
+        uses G_Name;
+        uses G_Label;
+        uses G_Extension;
+        uses CoreModel-CoreFoundationModule-StateModel:G_State_Pac;
+        list localIdList {
+            description "An identifier that is unique in the context of some scope that is less than the global scope.
+
+(consider in the context of Identifier: A property of an entity/role with a value that is unique within an identifier space, where the identifier space is itself unique, and immutable. The identifier therefore represents the identity of the entity/role. An identifier carries no semantics with respect to the purpose of the entity.)";
+            key 'theValue';
+            config true;
+            ordered-by system;
+            uses G_NameAndValue;
+            min-elements 1;
+        }
+    }
+    grouping G_Label {
+        list labelList {
+            description "List of labels.";
+            key 'theValue';
+            config true;
+            ordered-by system;
+            uses G_NameAndValue;
+        }
+    }
+    grouping G_Extension {
+        list extensionList {
+            description "List of simple name-value extentions";
+            key 'theValue';
+            config true;
+            ordered-by system;
+            uses G_NameAndValue;
+        }
+    }
+    grouping G_UniversalIdAuthority {
+        status current;
+        leaf uuid {
+            type UniversalId;
+            description "The UUID for the UUID authority.";
+        }
+    }
+    list NameAndValueAuthority {
+        key 'uuid';
+        config true;
+        ordered-by system;
+        uses G_NameAndValueAuthority;
+    }
+    grouping G_NameAndValueAuthority {
+        status current;
+        leaf uuid {
+            type UniversalId;
+            description "The UUID for the NameValueAuthority.";
+        }
+    }
+    grouping G_ConditionalPackage {
+        status deprecated;
+        uses G_Extension;
+        uses G_Label;
+    }
+    grouping G_NameAndValue {
+        leaf valueName {
+            type string;
+            description "The name of the value. The value need not have a name.";
+        }
+        leaf theValue {
+            type string;
+            description "The value";
+        }
+        leaf _nameAndValueAuthorityRef {
+            type leafref {
+                path '/CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:NameAndValueAuthority/CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:uuid';
+            }
+            description "The authority that defines the named value.";
+        }
+        leaf _globalClassRef {
+            type leafref {
+                path '/CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:GlobalClass/CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:uuid';
+            }
+            description "The scope of the name uniqueness";
+        }
+    }
+    typedef UniversalId {
+        type string;
+    }
+}
diff --git a/api/src/main/yang/CoreModel-CoreFoundationModule-TypeDefinitions.yang b/api/src/main/yang/CoreModel-CoreFoundationModule-TypeDefinitions.yang
new file mode 100644 (file)
index 0000000..0289201
--- /dev/null
@@ -0,0 +1,17 @@
+module CoreModel-CoreFoundationModule-TypeDefinitions {
+    namespace "uri:onf:CoreModel-CoreFoundationModule-TypeDefinitions";
+    prefix CoreModel-CoreFoundationModule-TypeDefinitions;
+    revision 2016-04-13{}
+    typedef DateAndTime {
+        type string;
+    }
+    typedef BitString {
+        type string;
+    }
+    typedef Real {
+        type string;
+    }
+    typedef PrintableString {
+        type string;
+    }
+}
diff --git a/api/src/main/yang/CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed.yang b/api/src/main/yang/CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed.yang
new file mode 100644 (file)
index 0000000..4a64d34
--- /dev/null
@@ -0,0 +1,62 @@
+module CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed {
+    namespace "uri:onf:CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed";
+    prefix CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed;
+    import CoreModel-CoreNetworkModule-TypeDefinitions {
+        prefix CoreModel-CoreNetworkModule-TypeDefinitions;
+    }
+    revision 2016-04-13{}
+    list ProfileProxy {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ProfileProxy;
+    }
+    grouping G_ProfileProxy {
+        status deprecated;
+        leaf profileProxyMode {
+            type string;
+            description "A parameter profile may be used in a number of different ways:
+- Forces the values on the target with no opportunity to see or override the values in the target
+- Sets the values on the target that can be seen on the target
+- Sets the values on the target and supports override on the target so the target can be set away from the value in the profile
+- etc";
+        }
+        container _controlParameters {
+            description "The control parameters that can be set int the profile and applied to the target.
+Not all parameters need be selected and applied.";
+            config true;
+            uses G_ControlParameters;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list ControlParameters {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ControlParameters;
+    }
+    grouping G_ControlParameters {
+        status deprecated;
+        leaf operType {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:OperType;
+            description "This attribute whether or not the protection scheme is revertive or non-revertive. ";
+        }
+        leaf waitToRestoreTime {
+            type uint64;
+            description "If the protection system is revertive, this attribute specifies the amount of time, in seconds, to wait after a fault clears before restoring traffic to the protected protectionUnit that initiated the switching. Valid values for this attribute are integers.";
+        }
+        leaf protType {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:ProtectionType;
+            description "Indicates the protection scheme that is used for the ProtectionGroup.";
+        }
+        leaf holdOffTime {
+            type uint64;
+            description "This attribute indicates the time, in seconds, between declaration of signal degrade or signal fail, and the initialization of the protection switching algorithm. Valid values are integers in units of seconds.";
+        }
+        leaf id {
+            type string;
+        }
+    }
+}
diff --git a/api/src/main/yang/CoreModel-CoreModelEnhancements-InformationArchitectureAndPatterns.yang b/api/src/main/yang/CoreModel-CoreModelEnhancements-InformationArchitectureAndPatterns.yang
new file mode 100644 (file)
index 0000000..363ab31
--- /dev/null
@@ -0,0 +1,85 @@
+module CoreModel-CoreModelEnhancements-InformationArchitectureAndPatterns {
+    namespace "uri:onf:CoreModel-CoreModelEnhancements-InformationArchitectureAndPatterns";
+    prefix CoreModel-CoreModelEnhancements-InformationArchitectureAndPatterns;
+    revision 2016-04-13{}
+    list Component {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_Component;
+    }
+    grouping G_Component {
+        status deprecated;
+        list _port {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_Port;
+            min-elements 1;
+        }
+        list _attributePackageList {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_AttributePackage;
+        }
+        leaf _boundComponent {
+            type leafref {
+                path '/Component/id';
+            }
+        }
+        leaf _encapsulatedSystem {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-InformationArchitectureAndPatterns:System/CoreModel-CoreModelEnhancements-InformationArchitectureAndPatterns:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list Port {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_Port;
+    }
+    grouping G_Port {
+        status deprecated;
+        leaf Role {
+            type string;
+            default true;
+        }
+        leaf _boundPort {
+            type leafref {
+                path '/Port/id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list System {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_System;
+    }
+    grouping G_System {
+        status deprecated;
+        leaf id {
+            type string;
+        }
+    }
+    list AttributePackage {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_AttributePackage;
+    }
+    grouping G_AttributePackage {
+        status deprecated;
+        leaf id {
+            type string;
+        }
+    }
+}
diff --git a/api/src/main/yang/CoreModel-CoreModelEnhancements-InterViewRelationships_Sketch.yang b/api/src/main/yang/CoreModel-CoreModelEnhancements-InterViewRelationships_Sketch.yang
new file mode 100644 (file)
index 0000000..fe87bbe
--- /dev/null
@@ -0,0 +1,51 @@
+module CoreModel-CoreModelEnhancements-InterViewRelationships_Sketch {
+    namespace "uri:onf:CoreModel-CoreModelEnhancements-InterViewRelationships_Sketch";
+    prefix CoreModel-CoreModelEnhancements-InterViewRelationships_Sketch;
+    revision 2016-04-13{}
+    list Sketch_FC {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_Sketch_FC;
+    }
+    grouping G_Sketch_FC {
+        status deprecated;
+        leaf _supportingFcInOtherViewRef {
+            type leafref {
+                path '/Sketch_FC/id';
+            }
+        }
+        leaf-list _suportedFcInOtherView {
+            ordered-by system;
+            type leafref {
+                path '/Sketch_FC/id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list Sketch_LTP {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_Sketch_LTP;
+    }
+    grouping G_Sketch_LTP {
+        status deprecated;
+        leaf _supportingLtpInOtherViewRef {
+            type leafref {
+                path '/Sketch_LTP/id';
+            }
+        }
+        leaf-list _supportedLtpInOtherViewRef {
+            ordered-by system;
+            type leafref {
+                path '/Sketch_LTP/id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+}
diff --git a/api/src/main/yang/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule.yang b/api/src/main/yang/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule.yang
new file mode 100644 (file)
index 0000000..00821c4
--- /dev/null
@@ -0,0 +1,585 @@
+module CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule {
+    namespace "uri:onf:CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule";
+    prefix CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule;
+    import CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages {
+        prefix CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages;
+    }
+    revision 2016-04-13{}
+    list MultiSwitchedUniFlow {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_MultiSwitchedUniFlow;
+    }
+    grouping G_MultiSwitchedUniFlow {
+        status current;
+        list _ingressFcPort {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_IngressFcPortSet;
+            min-elements 1;
+        }
+        list _egressFcPort {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_EgressFcPortSet;
+            min-elements 1;
+        }
+        container switchControl {
+            config true;
+            uses G_ConfigurationAndSwitchControl;
+        }
+        leaf ingressFcPortSet {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:IngressFcPortSet/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf egressFcPortSet {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:EgressFcPortSet/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list IngressFcPortSet {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_IngressFcPortSet;
+    }
+    grouping G_IngressFcPortSet {
+        status current;
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_LocalClass;
+        leaf id {
+            type string;
+        }
+    }
+    list EgressFcPortSet {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_EgressFcPortSet;
+    }
+    grouping G_EgressFcPortSet {
+        status current;
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_LocalClass;
+        leaf id {
+            type string;
+        }
+    }
+    list ConfigurationAndSwitchControl {
+        key 'id uuid';
+        config true;
+        ordered-by system;
+        uses G_ConfigurationAndSwitchControl;
+    }
+    grouping G_ConfigurationAndSwitchControl {
+        status deprecated;
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_GlobalClass;
+        list switchControlRule {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_ControlRule;
+            min-elements 1;
+        }
+        leaf-list switch {
+            ordered-by system;
+            type string;
+            min-elements 1;
+        }
+        leaf-list egressSelection {
+            ordered-by system;
+            type string;
+            min-elements 1;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    container FcSpecList {
+        list FcSpec {
+            key 'uuid';
+            config true;
+            ordered-by system;
+            uses G_FcSpec;
+        }
+    }
+    grouping G_FcSpec {
+        status current;
+        leaf uuid {
+            type string;
+        }
+        list multiSwitchedUniFlow {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_MultiSwitchedUniFlow;
+            min-elements 1;
+        }
+        list switchControl {
+            key 'id uuid';
+            config true;
+            ordered-by system;
+            uses G_ConfigurationAndSwitchControl;
+        }
+        list fcPortSpec {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_FcPortSetSpec;
+            min-elements 1;
+        }
+        leaf fcSwitchGroupSpec {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:ConfigurationGroupSpec/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:uuid';
+            }
+        }
+        container ltpAssociationRule {
+            config true;
+            uses G_LtpAssociationRule;
+        }
+    }
+    list ConfigurationGroupSpec {
+        key 'uuid';
+        config true;
+        ordered-by system;
+        uses G_ConfigurationGroupSpec;
+    }
+    grouping G_ConfigurationGroupSpec {
+        status deprecated;
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_GlobalClass;
+        container switchControl {
+            config true;
+            uses G_ConfigurationAndSwitchControl;
+        }
+        container fcSpec {
+            config true;
+            uses G_FcSpec;
+        }
+        container ltpAssociationRule {
+            config true;
+            uses G_LtpAssociationRule;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list ControlRule {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ControlRule;
+    }
+    grouping G_ControlRule {
+        status deprecated;
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_LocalClass;
+        leaf switchControl_switch_1 {
+            type string;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list FcPortSetSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_FcPortSetSpec;
+    }
+    grouping G_FcPortSetSpec {
+        status current;
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_LocalClass;
+        leaf-list ingressFcPortSet {
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:IngressFcPortSet/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf-list egressFcPortSet {
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:EgressFcPortSet/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf ltpAssociationRule {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:LtpAssociationRule/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf role {
+            type string;
+            default true;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list LtpAssociationRule {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_LtpAssociationRule;
+    }
+    grouping G_LtpAssociationRule {
+        status current;
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_LocalClass;
+        leaf id {
+            type string;
+        }
+    }
+    list SwitchPropertySpec_Pac {
+        key 'id';
+        status deprecated;
+        config true;
+        leaf id {
+            type string;
+        }
+    }
+    list IngressFcPortSetSpec_Pac {
+        key 'id';
+        status deprecated;
+        config true;
+        leaf id {
+            type string;
+        }
+    }
+    list LpSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_LpSpec;
+    }
+    grouping G_LpSpec {
+        status deprecated;
+        container _adapterSpec {
+            config true;
+            uses G_ConnectionPointAndAdapterSpec;
+        }
+        container _terminationSpec {
+            config true;
+            uses G_TerminationSpec;
+        }
+        list _adapterPropertySpecList {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_AdapterPropertySpec;
+        }
+        container _providerViewSpec {
+            config true;
+            uses G_ProviderViewSpec;
+        }
+        list _serverSpecList {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_ServerSpec;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list ClientSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ClientSpec;
+    }
+    grouping G_ClientSpec {
+        status deprecated;
+        leaf-list _mappingInteractionRuleRefList {
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:MappingInteractionRule/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list MappingInteractionRule {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_MappingInteractionRule;
+    }
+    grouping G_MappingInteractionRule {
+        status deprecated;
+        leaf id {
+            type string;
+        }
+    }
+    list TerminationSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_TerminationSpec;
+    }
+    grouping G_TerminationSpec {
+        status deprecated;
+        container _connectionSpec {
+            config true;
+            uses G_ConnectionSpec;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list AdapterPropertySpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_AdapterPropertySpec;
+    }
+    grouping G_AdapterPropertySpec {
+        status deprecated;
+        list _poolPropertySpecList {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_PoolPropertySpec;
+        }
+        leaf-list _mappingInteractionRuleRefList {
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:MappingInteractionRule/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        list _mappingInteractionRuleList {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_MappingInteractionRule;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list PoolPropertySpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_PoolPropertySpec;
+    }
+    grouping G_PoolPropertySpec {
+        status deprecated;
+        container _clientSpec {
+            config true;
+            uses G_ClientSpec;
+        }
+        leaf clientCapacity {
+            type string;
+            default true;
+        }
+        leaf-list _adapterPropertySpecRefList {
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:AdapterPropertySpec/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list ConnectionSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ConnectionSpec;
+    }
+    grouping G_ConnectionSpec {
+        status deprecated;
+        leaf id {
+            type string;
+        }
+    }
+    list ConnectionPointAndAdapterSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ConnectionPointAndAdapterSpec;
+    }
+    grouping G_ConnectionPointAndAdapterSpec {
+        status deprecated;
+        leaf _connectionSpec {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:ConnectionSpec/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list ProviderViewSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ProviderViewSpec;
+    }
+    grouping G_ProviderViewSpec {
+        status deprecated;
+        leaf-list _poolPropertySpecList {
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:PoolPropertySpec/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list ServerSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ServerSpec;
+    }
+    grouping G_ServerSpec {
+        status deprecated;
+        leaf id {
+            type string;
+        }
+    }
+    list LtpSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_LtpSpec;
+    }
+    grouping G_LtpSpec {
+        status deprecated;
+        leaf-list _lpSpecList {
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:LpSpec/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+            min-elements 1;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list LinkSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_LinkSpec;
+    }
+    grouping G_LinkSpec {
+        status deprecated;
+        leaf id {
+            type string;
+        }
+    }
+    list AnyEntityInstance {
+        key 'id';
+        status deprecated;
+        config true;
+        ordered-by system;
+        leaf-list _profileRefList {
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:ProfileInstance/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf _specRef {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:SpecInstance/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf _class {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:AnyEntityClass/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list ProfileInstance {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ProfileInstance;
+    }
+    grouping G_ProfileInstance {
+        status deprecated;
+        leaf _specInstanceRef {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:SpecInstance/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf _profileClass {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:ProfileClass/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf _class {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:AnyEntityClass/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list SpecInstance {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_SpecInstance;
+    }
+    grouping G_SpecInstance {
+        status deprecated;
+        leaf specClass {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:SpecClass/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf _classRef {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:AnyEntityClass/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list AnyEntityClass {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_AnyEntityClass;
+    }
+    grouping G_AnyEntityClass {
+        status deprecated;
+        leaf id {
+            type string;
+        }
+    }
+    list SpecClass {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_SpecClass;
+    }
+    grouping G_SpecClass {
+        status deprecated;
+        uses G_AnyEntityClass;
+    }
+    list ProfileClass {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ProfileClass;
+    }
+    grouping G_ProfileClass {
+        status deprecated;
+        uses G_AnyEntityClass;
+    }
+}
diff --git a/api/src/main/yang/CoreModel-CoreModelEnhancements-ViewAbstractionRule_Sketch.yang b/api/src/main/yang/CoreModel-CoreModelEnhancements-ViewAbstractionRule_Sketch.yang
new file mode 100644 (file)
index 0000000..461e193
--- /dev/null
@@ -0,0 +1,18 @@
+module CoreModel-CoreModelEnhancements-ViewAbstractionRule_Sketch {
+    namespace "uri:onf:CoreModel-CoreModelEnhancements-ViewAbstractionRule_Sketch";
+    prefix CoreModel-CoreModelEnhancements-ViewAbstractionRule_Sketch;
+    revision 2016-04-13{}
+    list ViewAbstractionRules {
+        key 'id';
+        status deprecated;
+        config true;
+        ordered-by system;
+        leaf-list __ltpRelatestToLtpInOtherView {
+            ordered-by system;
+            type string;
+        }
+        leaf id {
+            type string;
+        }
+    }
+}
diff --git a/api/src/main/yang/CoreModel-CoreNetworkModule-ObjectClasses.yang b/api/src/main/yang/CoreModel-CoreNetworkModule-ObjectClasses.yang
new file mode 100644 (file)
index 0000000..bc5cc64
--- /dev/null
@@ -0,0 +1,815 @@
+module CoreModel-CoreNetworkModule-ObjectClasses {
+    namespace "uri:onf:CoreModel-CoreNetworkModule-ObjectClasses";
+    prefix CoreModel-CoreNetworkModule-ObjectClasses;
+    import CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages {
+        prefix CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages;
+    }
+    import CoreModel-CoreNetworkModule-TypeDefinitions {
+        prefix CoreModel-CoreNetworkModule-TypeDefinitions;
+    }
+    import CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule {
+        prefix CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule;
+    }
+    import CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed {
+        prefix CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed;
+    }
+    revision 2016-04-13{}
+    list ForwardingDomain {
+        key 'uuid';
+        config true;
+        ordered-by system;
+        uses G_ForwardingDomain;
+    }
+    grouping G_ForwardingDomain {
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_GlobalClass;
+        uses G_TopologicalEntity;
+        leaf-list layerProtocolNameList {
+            description "One or more protocol layers at which the FD represents the opportunity to enable forwarding between LTP that bound it.";
+            ordered-by system;
+            type CoreModel-CoreNetworkModule-TypeDefinitions:LayerProtocolName;
+            min-elements 1;
+        }
+        leaf-list _lowerLevelFdRefList {
+            description "The FD object class supports a recursive aggregation relationship (HigherLevelFdEncompassesLowerLevelFds) such that the internal construction of an FD can be exposed as multiple lower level FDs and associated Links (partitioning).
+The aggregated FDs and Links form an interconnected topology that provides and describes the capability of the aggregating FD.
+Note that the model actually represents aggregation of lower level FDs into higher level FDs as views rather than FD partition, and supports multiple views. 
+Aggregation allow reallocation of capacity from lower level FDs to different higher level FDs as if the network is reorganized  (as the association is aggregation not composition).";
+            ordered-by system;
+            type leafref {
+                path '/ForwardingDomain/uuid';
+            }
+        }
+        leaf-list _fcRefList {
+            description "An FD contains one or more FCs. A contained FC connects LTPs that bound the FD.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:ForwardingConstructList/CoreModel-CoreNetworkModule-ObjectClasses:ForwardingConstruct/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+        }
+        leaf-list _ltpRefList {
+            description "An instance of FD is associated with zero or more LTP objects. 
+The LTPs that bound the FD provide capacity for forwarding.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:LogicalTerminationPoint/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+        }
+        leaf-list _linkRefList {
+            description "The FD encompasses Links that interconnect lower level FDs and collect links that are wholly within the bounds of the FD.
+See also _lowerLevelFdRefList.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:Link/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+        }
+    }
+    container ForwardingConstructList {
+      list ForwardingConstruct {
+        key 'uuid';
+        config true;
+        ordered-by system;
+        uses G_ForwardingConstruct;
+      }
+    }
+    grouping G_ForwardingConstruct {
+        leaf uuid {
+            type string;
+        }
+        leaf layerProtocolName {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:LayerProtocolName;
+            description "The layerProtocol at which the FC enables potential for forwarding.";
+        }
+        leaf-list _lowerLevelFcRefList {
+            description "An FC object supports a recursive aggregation relationship such that the internal construction of an FC can be exposed as multiple lower level FC objects (partitioning).
+Aggregation is used as for the FD to allow changes in hierarchy.
+";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:ForwardingConstructList/CoreModel-CoreNetworkModule-ObjectClasses:ForwardingConstruct/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+        }
+        leaf-list _fcRouteRefList {
+            description "An FC object can have zero or more routes, each of which is defined as a list of lower level FC objects describing the flow across the network.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList/CoreModel-CoreNetworkModule-ObjectClasses:FcRoute/CoreModel-CoreNetworkModule-ObjectClasses:id';
+            }
+        }
+        list FcPort {
+            description "The association of the FC to LTPs is made via FcPorts (essentially the ports of the FC).";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_FcPort;
+            min-elements 2;
+        }
+        list _fcSwitchList {
+            description "If an FC exposes protection (having two FcPorts that provide alternative identical inputs/outputs), the FC will have one or more associated FcSwitch objects.
+The arrangement of switches for a particular instance is described by a referenced FcSpec";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_FcSwitch;
+        }
+        list _configurationAndSwitchControlList {
+            description "A multi-switch controller encapsulated in the FC.
+The multi-switch controller coordinates multiple switches in the same FC.";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_ConfigurationAndSwitchController;
+        }
+        leaf _fcSpecRef {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:FcSpecList/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:FcSpec/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:uuid';
+            }
+            description "References the specification that describes the capability and internal structure of of the FC (e.g. The arrangement of switches for a particular instance is described by a referenced FcSpec).
+The specification allows interpretation of FcPort role and switch configurations etc.";
+        }
+        leaf forwardingDirection {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:ForwardingDirection;
+            description "The directionality of the ForwardingConstruct. 
+Is applicable to simple ForwardingConstructs where all FcPorts are BIDIRECTIONAL (the ForwardingConstruct will be BIDIRECTIONAL) or UNIDIRECTIONAL (the ForwardingConstruct will be UNIDIRECTIONAL). 
+Is not present in more complex cases.";
+        }
+    }
+    list NetworkControlDomain {
+        key 'id uuid';
+        status current;
+        config true;
+        ordered-by system;
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_GlobalClass;
+        leaf-list _forwardingDomainRefList {
+            description "The FDs accessible via the NCD.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:ForwardingDomain/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+        }
+        leaf-list _linkRefList {
+            description "The links accessible in the scope of the NCD. 
+The domain is bounded by off-network links.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:Link/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+        }
+        list _networkElementRefList {
+            description "The network elements within the scope of the NCD where each NE is within one and only one domain.";
+            key 'id uuid';
+            config true;
+            ordered-by system;
+            uses G_NetworkElement;
+        }
+        leaf id {
+            type string;
+        }
+        max-elements 2;
+        min-elements 1;
+    }
+    list Link {
+        key 'uuid';
+        config true;
+        ordered-by system;
+        uses G_Link;
+    }
+    grouping G_Link {
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_GlobalClass;
+        uses G_TopologicalEntity;
+        leaf-list layerProtocolNameList {
+            description "The Link can support multiple transport layer protocols via the associated LTP object. 
+For implementation optimization, where appropriate, multiple layer-specific links can be merged and represented as a single Link instance as the Link can represent a list of layer protocols.
+A link may support different layer protocols at each Port when it is a transitional link.";
+            ordered-by system;
+            type CoreModel-CoreNetworkModule-TypeDefinitions:LayerProtocolName;
+            min-elements 1;
+        }
+        leaf-list _fdRefList {
+            description "The Link associates with two or more FDs. 
+This association provides a direct summarization of the association via LinkPort and LTP.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:ForwardingDomain/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+            min-elements 2;
+        }
+        list _linkPortList {
+            description "The association of the Link to LTPs is made via LinkPort (essentially the ports of the Link).";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_LinkPort;
+            min-elements 2;
+        }
+        leaf _linkSpecRef {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:LinkSpec/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+            description "References the specification that describes the capability and internal structure of of the Link (e.g. asymmetric flows between points).
+The specification allows interpretation of LinkPort role and switch configurations etc.
+See also ForwardingConstruct.";
+        }
+        leaf-list _aggregatedLink {
+            description "A link may formed from subordinate links (similar FD formations from subordiate FDs). This association is intended to cover concepts such as serial compound links. ";
+            ordered-by system;
+            type leafref {
+                path '/Link/uuid';
+            }
+        }
+        leaf linkDirection {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:ForwardingDirection;
+            description "The directionality of the Link. 
+Is applicable to simple Links where all LinkPorts are BIDIRECTIONAL (the Link will be BIDIRECTIONAL) or UNIDIRECTIONAL (the Link will be UNIDIRECTIONAL). 
+Is not present in more complex cases.";
+        }
+    }
+    list NetworkElement {
+        key 'id uuid';
+        config true;
+        ordered-by system;
+        uses G_NetworkElement;
+    }
+    grouping G_NetworkElement {
+        status deprecated;
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_GlobalClass;
+        list _fdRefList {
+            description "Represents the FD that is completely within the boundary of the NE.
+At a low level of recursion, an FD (within a network element (NE)) represents a switch matrix (i.e., a fabric). 
+Note that an NE can encompass multiple switch matrices (FDs) and the FD representing the switch matrix can be further partitioned.
+Where an FD is referenced by the NeEncompassesFd association, any FDs that it encompasses (i.e., that are associated with it by HigherLevelFdEncompassesLowerLevelFds), must also be encompassed by the NE and hence must have the NeEncompassesFd association.
+";
+            key 'uuid';
+            config true;
+            ordered-by system;
+            uses G_ForwardingDomain;
+        }
+        leaf-list _ltppList {
+            description "OBSOLETE. Was reference to LtpPool. The pool has now been subsumed into the LTP.
+This will be deleted in the next release.";
+            ordered-by system;
+            type string;
+        }
+        list _ltpRefList {
+            description "An NE has associated LTPs that are at its boundary.
+The NeEncompassesFd association occurs for FDs that are within the bounds of the NetworkElement definition such that the FD is bounded by LTPs, all of which are on the boundary of the NetworkElement or are within the NetworkElement. 
+An LTP can be independent of an NE.";
+            key 'uuid';
+            config true;
+            ordered-by system;
+            uses G_LogicalTerminationPoint;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    grouping G_SdnController {
+        status current;
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_GlobalClass;
+    }
+    list LayerProtocol {
+        key 'layerProtocolName';
+        config true;
+        ordered-by system;
+        uses G_LayerProtocol;
+    }
+    grouping G_LayerProtocol {
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_LocalClass;
+        leaf layerProtocolName {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:LayerProtocolName;
+            description "Indicate the specific layer-protocol described by the LayerProtocol entity.";
+        }
+        leaf _lpSpec {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:LpSpec/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+            description "The LpSpec identifies the interna structure of the LP explaining internal flexibilities, degree of termination and degree of adaptation on both client and server side.";
+        }
+        leaf configuredClientCapacity {
+            type string;
+            description "Provides a summarized view of the client capacity that is configurable for use.
+Note the cleint LTP association should provide all necessary detail hence this attribute is questionable.";
+        }
+        leaf lpDirection {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:TerminationDirection;
+            description "The overall directionality of the LP. 
+- A BIDIRECTIONAL LP will have some SINK and/or SOURCE flowss.
+- A SINK LP can only contain elements with SINK flows or CONTRA_DIRECTION_SOURCE flows
+- A SOURCE LP can only contain SOURCE flows or CONTRA_DIRECTION_SINK flows";
+        }
+        leaf terminationState {
+            type string;
+            description "Indicates whether the layer is terminated and if so how.";
+        }
+    }
+    list LogicalTerminationPoint {
+        key 'uuid';
+        config true;
+        ordered-by system;
+        uses G_LogicalTerminationPoint;
+    }
+    grouping G_LogicalTerminationPoint {
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_GlobalClass;
+        leaf-list _serverLtpRefList {
+            description "References contained LTPs representing servers of this LTP in an inverse multiplexing configuration (e.g. VCAT).";
+            ordered-by system;
+            type leafref {
+                path '/LogicalTerminationPoint/uuid';
+            }
+        }
+        leaf-list _clientLtpRefList {
+            description "References contained LTPs representing client traffic of this LTP for normal cases of multiplexing.";
+            ordered-by system;
+            type leafref {
+                path '/LogicalTerminationPoint/uuid';
+            }
+        }
+        list _lpList {
+            description "Ordered list of LayerProtocols that this LTP is comprised of where the first entry in the list is the lowest server layer (e.g. physical)";
+            key 'layerProtocolName';
+            config true;
+            ordered-by system;
+            uses G_LayerProtocol;
+            min-elements 1;
+        }
+        leaf _connectedLtpRef {
+            type leafref {
+                path '/LogicalTerminationPoint/uuid';
+            }
+            description "Applicable in a simple context where two LTPs are associated via a non-adjustable enabled forwarding.
+Reduces clutter removing the need for two additional LTPs and an FC with a pair of FcPorts.";
+        }
+        leaf _peerLtpRef {
+            type leafref {
+                path '/LogicalTerminationPoint/uuid';
+            }
+            description "References contained LTPs representing the reversal of orientation of flow where two LTPs are associated via a non-adjustable enabled forwarding and where the referenced LTP is fully dependent on the this LTP.";
+        }
+        leaf _ltpSpec {
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:LtpSpec/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:id';
+            }
+            description "The specification of the LTP defines internal structure of the LTP.
+The specification allows interpretation of organisatoon of LPs making up the LTP and also identifies which inter-LTP associations are valid.";
+        }
+        leaf-list physicalPortReference {
+            description "One or more text labels for the unmodelled physical port associated with the LTP.
+In many cases there is no associated physical port";
+            ordered-by system;
+            type string;
+        }
+        leaf-list _ltpRefList {
+            description "References one or more LTPs in other views that represent this LTP. 
+The referencing LTP is the rovider of capability.";
+            ordered-by system;
+            type leafref {
+                path '/LogicalTerminationPoint/uuid';
+            }
+        }
+        leaf ltpDirection {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:TerminationDirection;
+            description "The overall directionality of the LTP. 
+- A BIDIRECTIONAL LTP must have at least some LPs that are BIDIRECTIONAL but may also have some SINK and/or SOURCE LPs.
+- A SINK LTP can only contain SINK LPs
+- A SOURCE LTP can only contain SOURCE LPs";
+        }
+    }
+    container FcRouteList {
+        list FcRoute {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_FcRoute;
+        }
+    }
+    grouping G_FcRoute {
+        list ForwardingConstruct {
+            key "uuid";
+            uses G_ForwardingConstruct;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list LinkPort {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_LinkPort;
+    }
+    grouping G_LinkPort {
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_LocalClass;
+        leaf _ltpp {
+            type string;
+            description "OBSOLETE. Was reference to LtpPool. The pool has now been subsumed into the LTP.
+This will be deleted in the next release.";
+        }
+        leaf-list _ltpRefList {
+            description "The LinkPort may be associated with more than one LTP when the LinkPort is bidirectional and the LTPs are unidirectional.
+Multiple Ltp
+- Bidirectional LinkPort to two Uni Ltps
+Zero Ltp
+- BreakBeforeMake transition
+- Planned Ltp not yet in place
+- Off-network LTP referenced through other mechanism";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:LogicalTerminationPoint/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+        }
+        leaf role {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:PortRole;
+            description "Each LinkPort of the Link has a role (e.g., symmetric, hub, spoke, leaf, root)  in the context of the Link with respect to the Link function. ";
+        }
+        leaf offNetworkAddress {
+            type string;
+            description "A freeform opportunity to express a reference for an Port of the Link that is not outside the scope of the control domain.
+This attribute is expected to convey a foreign identifier/name/address or a shared reference for some mid-span point at the boundary between two administrative domains.
+This attribute is used when an LTP cannot be referenced.";
+        }
+        leaf linkPortDirection {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:PortDirection;
+            description "The orientation of defined flow at the LinkPort.";
+        }
+        leaf id {
+            type string;
+        }
+    }
+    grouping G_TransferCost_Pac {
+        list costCharacteristicList {
+            description "The list of costs where each cost relates to some aspect of the TopologicalEntity.";
+            key 'costName';
+            config true;
+            ordered-by system;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_CostCharacteristics;
+            min-elements 1;
+        }
+    }
+    grouping G_RiskParameter_Pac {
+        list riskCharacteristicList {
+            description "A list of risk characteristics for consideration in an analysis of shared risk. Each element of the list represents a specific risk consideration.";
+            key 'riskCharacteristicName';
+            config true;
+            ordered-by system;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_RiskCharacteristic;
+            min-elements 1;
+        }
+    }
+    grouping G_LayerProtocolTransition_Pac {
+        leaf-list transitionedLayerProtocolList {
+            description "Provides the ordered structure of layer protocol transitions encapsulated in the TopologicalEntity. The ordering relates to the LinkPort role.";
+            ordered-by system;
+            type string;
+            min-elements 1;
+        }
+        leaf-list _ltpRefList {
+            description "Lists the LTPs that define the layer protocol transition of the transitional link.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:LogicalTerminationPoint/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+            min-elements 1;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    feature feature1 {
+        description "Present if jitterCharacteristics information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if jitterCharacteristics is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.
+            Note that this only applies to TDM.";
+    }
+    feature feature2 {
+        description "Present if wanderCharacteristics information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if wanderCharacteristics is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.
+            Note that this only applies to TDM.";
+    }
+    feature feature3 {
+        description "Present if queuingLatencyCharacteristics information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            There may be more than one instance if the queuing behavior depends upon traffic properties.
+            Note that if queuingLatencyCharacteristics is relevant but consistent statement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.
+            Note that this only applies to packet system.";
+    }
+    grouping G_TransferTiming_Pac {
+        leaf fixedLatencyCharacteristic {
+            type string;
+            description "A TopologicalEntity suffers delay caused by the realization of the servers (e.g. distance related; FEC encoding etc.) along with some client specific processing. This is the total average latency effect of the TopologicalEntity";
+        }
+        leaf jitterCharacteristic {
+            type string;
+            description "High frequency deviation from true periodicity of a signal and therefore a small high rate of change of transfer latency.
+Applies to TDM systems (and not packet).";
+            if-feature feature1;
+        }
+        leaf wanderCharacteristic {
+            type string;
+            description "Low frequency deviation from true periodicity of a signal and therefore a small low rate of change of transfer latency.
+Applies to TDM systems (and not packet).";
+            if-feature feature2;
+        }
+        list queuingLatencyList {
+            description "The effect on the latency of a queuing process. This only has significant effect for packet based systems and has a complex characteristic.";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_QueuingLatency;
+            if-feature feature3;
+        }
+    }
+    feature feature4 {
+        description "Present if errorCharacteristics information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if errorCharacteristics is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.
+            Note that this only applies to TDM.";
+    }
+    feature feature5 {
+        description "Present if lossCharacteristics information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if lossCharacteristics is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.
+            Note that this only applies to packet systems.";
+    }
+    feature feature6 {
+        description "Present if repeatCharacteristics information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if repeatCharacteristics is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.
+            Note that this primarily applies to packet systemswhere a packet may be delivered more than once (in fault recovery for example). 
+            Note that it can also apply to TDM where several frames may  be received twice due to switching in a system with a large differential propagation delay.";
+    }
+    feature feature7 {
+        description "Present if deliveryOrderCharacteristics information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if deliveryOrderCharacteristics is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.
+            Note that this only applies to packet systems.
+            ";
+    }
+    feature feature8 {
+        description "Present if serverIntegrityProcessCharacteristics information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if serverIntegrityProcessCharacteristics is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.
+            Note that this only applies where the server has some error recovery mechanism alters the characteristics of the link from a normal distribution.";
+    }
+    grouping G_TransferIntegrity_Pac {
+        leaf errorCharacteristic {
+            type string;
+            description "Describes the degree to which the signal propagated can be errored. 
+Applies to TDM systems as the errored signal will be propagated and not packet as errored packets will be discarded.";
+            if-feature feature4;
+        }
+        leaf lossCharacteristic {
+            type string;
+            description "Describes the acceptable characteristic of lost packets where loss may result from discard due to errors or overflow.
+Applies to packet systems and not TDM (as for TDM errored signals are propagated unless grossly errored and overflow/underflow turns into timing slips).";
+            if-feature feature5;
+        }
+        leaf repeatDeliveryCharacteristic {
+            type string;
+            description "Primarily applies to packet systems where a packet may be delivered more than once (in fault recovery for example). 
+It can also apply to TDM where several frames may be received twice due to switching in a system with a large differential propagation delay.";
+            if-feature feature6;
+        }
+        leaf deliveryOrderCharacteristic {
+            type string;
+            description "Describes the degree to which packets will be delivered out of sequence.
+Does not apply to TDM as the TDM protocols maintain strict order.";
+            if-feature feature7;
+        }
+        leaf unavailableTimeCharacteristic {
+            type string;
+            description "Describes the duration for which there may be no valid signal propagated.";
+        }
+        leaf serverIntegrityProcessCharacteristic {
+            type string;
+            description "Describes the effect of any server integrity enhancement process on the characteristics of the TopologicalEntity.";
+            if-feature feature8;
+        }
+    }
+    grouping G_TransferCapacity_Pac {
+        container totalPotentialCapacity {
+            description "An optimistic view of the capacity of the TopologicalEntity assuming that any shared capacity is available to be taken.";
+            config true;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_Capacity;
+        }
+        container availableCapacity {
+            description "Capacity available to be assigned.";
+            config true;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_Capacity;
+        }
+        list capacityAssignedToUserView {
+            description "Capacity already assigned";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_Capacity;
+        }
+        leaf capacityInteractionAlgorithm {
+            type string;
+            description "A reference to an algorithm that describes how various chunks of allocated capacity interact (e.g. when shared)";
+        }
+    }
+    feature feature9 {
+        description "Present if risk information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if risk is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.";
+    }
+    feature feature10 {
+        description "Present if cost information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if cost is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.";
+    }
+    feature feature11 {
+        description "Present if transfer timing information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if transfer timing is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.";
+    }
+    feature feature12 {
+        description "Present if transfer capacity information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if transfer capacity is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.";
+    }
+    feature feature13 {
+        description "Present if transfer integrity information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if transfer integrity is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.";
+    }
+    feature feature14 {
+        description "Present if validation information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if validation is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.
+            Note that validation may not be possible for the specific layer protocol or in the particular case.";
+    }
+    feature feature15 {
+        description "Present if layer transition information is relevant to usage and statement can be made that applies equally to all flows that can be supported by the TopologicalEntity.
+            Note that if layer transiotio is relevant but consistent ststement cannot be made then the TopologicalEntity should be described in terms of subordinate parts against which coherent statements can be made.
+            Note that layer transition occurs in a limited number of cases.";
+    }
+    grouping G_TopologicalEntity {
+        container _riskParameter_Pac {
+            config true;
+            uses G_RiskParameter_Pac;
+        }
+        container _transferCost_Pac {
+            config true;
+            uses G_TransferCost_Pac;
+        }
+        container _transferTiming_Pac {
+            config true;
+            uses G_TransferTiming_Pac;
+        }
+        container _transferCapacity_Pac {
+            config true;
+            uses G_TransferCapacity_Pac;
+        }
+        container _transferIntegrity_Pac {
+            config true;
+            uses G_TransferIntegrity_Pac;
+        }
+        container _validation_Pac {
+            config true;
+            uses G_Validation_Pac;
+        }
+        list _layerTransition_Pac {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_LayerProtocolTransition_Pac;
+            if-feature feature15;
+        }
+    }
+    grouping G_Validation_Pac {
+        list validationMechanismList {
+            description "Provides details of the specific validation mechanism(s) used to confirm the presence of an intended topologicalEntity.";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_ValidationMechanism;
+            min-elements 1;
+        }
+    }
+    list FcPort {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_FcPort;
+    }
+    grouping G_FcPort {
+        leaf-list _ltpRefList {
+            description "The FcPort may be associated with more than one LTP when the FcPort is bidirectional and the LTPs are unidirectional.
+Multiple Ltp
+- Bidirectional FcPort to two Uni Ltps
+Zero Ltp
+- BreakBeforeMake transition
+- Planned Ltp not yet in place
+- Off-network LTP referenced through other mechanism";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:LogicalTerminationPoint/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+            max-elements 2;
+        }
+        leaf role {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:PortRole;
+            description "Each FcPort of the FC has a role (e.g., working, protection, protected, symmetric, hub, spoke, leaf, root)  in the context of the FC with respect to the FC function. ";
+        }
+        leaf fcPortDirection {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:PortDirection;
+            description "The orientation of defined flow at the FcPort.";
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list FcSwitch {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_FcSwitch;
+    }
+    grouping G_FcSwitch {
+        uses CoreModel-CoreFoundationModule-SuperClassesAndCommonPackages:G_LocalClass;
+        leaf holdOffTime {
+            type uint64;
+            description "This attribute indicates the time, in seconds, between declaration of unacceptable quality of signal on the currently selected FcPort, and the initialization of the protection switching algorithm. ";
+        }
+        leaf waitToRestoreTime {
+            type uint64;
+            description "If the protection system is revertive, this attribute specifies the amount of time, in seconds, to wait after the preferred FcPort returns to an acceptable state of operaion (e.g a fault has cleared) before restoring traffic to that preferred FcPort. ";
+        }
+        leaf protType {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:ProtectionType;
+            description "Indicates the protection scheme that is used for the ProtectionGroup.";
+        }
+        leaf operType {
+            type CoreModel-CoreNetworkModule-TypeDefinitions:OperType;
+            description "This attribute whether or not the protection scheme is revertive or non-revertive. ";
+        }
+        leaf-list _selectedFcPortRefList {
+            description "Indicates which points are selected by the switch.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:FcPort/CoreModel-CoreNetworkModule-ObjectClasses:id';
+            }
+            min-elements 1;
+        }
+        leaf-list _profileProxyRefList {
+            description "Provides a set of predefined values for switch control in place of the direct values avaiable via the FcSwitch or via _configurationAndSwitchControl ";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed:ProfileProxy/CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed:id';
+            }
+        }
+        leaf _configurationAndSwitchControlRef {
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:ConfigurationAndSwitchController/CoreModel-CoreNetworkModule-ObjectClasses:id';
+            }
+            description "A multi-switch controller external to the FcSwitch.
+The multi-switch controller coordinates multiple switches in the same FC or across multple FCs";
+        }
+        container _configurationAndSwitchControl {
+            description "A switch controller encapsulated in the FcSwitch.
+";
+            config true;
+            uses G_ConfigurationAndSwitchController;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list ConfigurationAndSwitchController {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_ConfigurationAndSwitchController;
+    }
+    grouping G_ConfigurationAndSwitchController {
+        status deprecated;
+        leaf SwichRule {
+            type string;
+            description "A sketch of the presence of complex rules governing the switch behavior.";
+        }
+        leaf-list _fcSwitchRefList {
+            description "The switch being controlled.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:FcSwitch/CoreModel-CoreNetworkModule-ObjectClasses:id';
+            }
+        }
+        container _controlParameters {
+            description "The control parameters to be aplied if local parameters are used rather than profiles";
+            config true;
+            uses CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed:G_ControlParameters;
+        }
+        leaf-list _profileProxyRef {
+            description "Applied profiles.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed:ProfileProxy/CoreModel-CoreModelEnhancements-FcSwitchEnhancements_Developed:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list ConfigurationGroup {
+        key 'id';
+        status deprecated;
+        config true;
+        list _configurationAndSwitchControlRefList {
+            description "A controller operating in the scope defined.";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_ConfigurationAndSwitchController;
+        }
+        leaf id {
+            type string;
+        }
+    }
+}
diff --git a/api/src/main/yang/CoreModel-CoreNetworkModule-TypeDefinitions.yang b/api/src/main/yang/CoreModel-CoreNetworkModule-TypeDefinitions.yang
new file mode 100644 (file)
index 0000000..a632e6d
--- /dev/null
@@ -0,0 +1,163 @@
+module CoreModel-CoreNetworkModule-TypeDefinitions {
+    namespace "uri:onf:CoreModel-CoreNetworkModule-TypeDefinitions";
+    prefix CoreModel-CoreNetworkModule-TypeDefinitions;
+    revision 2016-04-13{}
+    typedef OperationalState {
+        status obsolete;
+        type enumeration {
+            enum ENABLED;
+            enum DISABLED;
+        }
+    }
+    typedef OperType {
+        type enumeration {
+            enum REVERTIVE;
+            enum NON-REVERTIVE;
+        }
+    }
+    typedef Directionality {
+        status obsolete;
+        type enumeration {
+            enum SINK;
+            enum SOURCE;
+            enum BIDIRECTIONAL;
+        }
+    }
+    grouping G_CostCharacteristics {
+        leaf costName {
+            type string;
+            description "The cost characteristic will related to some aspect of the TopologicalEntity (e.g. $ cost, routing weight). This aspect will be conveyed by the costName.";
+        }
+        leaf costValue {
+            type string;
+            description "The specific cost.";
+        }
+        leaf costAlgorithm {
+            type string;
+            description "The cost may vary based upon some properties of the TopologicalEntity. The rules for the variation are conveyed by the costAlgorithm.";
+        }
+    }
+    grouping G_RiskCharacteristic {
+        leaf riskCharacteristicName {
+            type string;
+            description "The name of the risk characteristic. The characteristic may be related to a specific degree of closeness. 
+For example a particular characteristic may apply to failures that are localized (e.g. to one side of a road) where as another characteristic may relate to failures that have a broader impact (e.g. both sides of a road that crosses a bridge).
+Depending upon the importance of the traffic being routed different risk characteristics will be evaluated.";
+        }
+        leaf-list riskIdentifierList {
+            description "A list of the identifiers of each physical/geographic unit (with the specific risk characteristic) that is related to a segment of the TopologicalEntity.";
+            ordered-by system;
+            type string;
+            min-elements 1;
+        }
+    }
+    grouping G_Capacity {
+        leaf totalSize {
+            type string;
+            description "Total capacity of the TopologicalEntity in MB/s";
+        }
+        leaf numberOfClientInstances {
+            type string;
+            description "Where there is some limit to the number of client (e.g. in a channelized case).";
+        }
+        leaf maximumClientSize {
+            type string;
+            description "Where a client is of variable capacity but due to some underlying realization the maximum size of the client is smaller than the totalSize.";
+        }
+        leaf numberingRange {
+            type string;
+            description "Method for identifying units of capacity via some numbering scheme.";
+        }
+        leaf id {
+            type string;
+        }
+    }
+    grouping G_ValidationMechanism {
+        leaf validationMechanism {
+            type string;
+            description "Name of mechanism used to validate adjacency";
+        }
+        leaf layerProtocolAdjacencyValidated {
+            type string;
+            description "State of validatiion";
+        }
+        leaf validationRobustness {
+            type string;
+            description "Quality of validation (i.e. how likely is the stated validation to be invalid)";
+        }
+        leaf id {
+            type string;
+        }
+    }
+    grouping G_QueuingLatency {
+        leaf trafficProperty {
+            type string;
+            description "The identifier of the specific traffic property to which the queuing latency applies.";
+        }
+        leaf latencyForTrafficWithProperty {
+            type string;
+            description "The specific queuing latency for the traffic property.";
+        }
+        leaf id {
+            type string;
+        }
+    }
+    typedef LayerProtocolName {
+        status current;
+        type string;
+    }
+    typedef PortRole {
+        status current;
+        type string;
+    }
+    typedef PortDirection {
+        type enumeration {
+            enum BIDIRECTIONAL;
+            enum INPUT;
+            enum OUTPUT;
+            enum UNIDENTIFIED_OR_UNKNOWN;
+        }
+    }
+    typedef ForwardingDirection {
+        type enumeration {
+            enum BIDIRECTIONAL;
+            enum UNIDIRECTIONAL;
+            enum UNDEFINED_OR_UNKNOWN;
+        }
+    }
+    typedef TerminationDirection {
+        type enumeration {
+            enum BIDIRECTIONAL;
+            enum SINK;
+            enum SOURCE;
+            enum UNDEFINED_OR_UNKNOWN;
+        }
+    }
+    typedef ExtendedTerminationDirection {
+        status deprecated;
+        type enumeration {
+            enum BIDIRECTIONAL;
+            enum SINK;
+            enum SOURCE;
+            enum UNDEFINED_OR_UNKNOWN;
+            enum CONTRA_DIRECTION_SINK;
+            enum CONTRA_DIRECTION_SOURCE;
+        }
+    }
+    typedef ProtectionType {
+        status deprecated;
+        type string;
+    }
+    typedef TerminationState {
+        status deprecated;
+        type enumeration {
+            enum LP_CAN_NEVER_TERMINATE;
+            enum LT_NOT_TERMINATED;
+            enum TERMINATED_SERVER_TO_CLIENT_FLOW;
+            enum TERMINATED_CLIENT_TO_SERVER_FLOW;
+            enum TERMINATED_BIDIRECTIONAL;
+            enum LT_PERMENANTLY_TERMINATED;
+            enum TERMINATION_STATE_UNKNOWN;
+        }
+    }
+}
diff --git a/api/src/main/yang/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage.yang b/api/src/main/yang/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage.yang
new file mode 100644 (file)
index 0000000..c327844
--- /dev/null
@@ -0,0 +1,461 @@
+module NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage {
+    namespace "uri:onf:NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage";
+    prefix NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage;
+    import NRP_Interface-TypeDefinitions-NRP_Types {
+        prefix NRP_Interface-TypeDefinitions-NRP_Types;
+    }
+    revision 2016-04-13{}
+    grouping G_NRP_PcpCosId {
+        leaf nrp_vlanTag {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_VlanTag;
+            description "Which vlan tag pcp to be used for cos identier, S tag or C tag. S tag is not valid for EvcEndPoint. ";
+        }
+        leaf-list nrp_pcpValue {
+            description "List of PCP values that map to the cos name.";
+            ordered-by system;
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            min-elements 1;
+        }
+        leaf nrp_cosName {
+            type string;
+            description "Class of Service name.";
+        }
+    }
+    list NRP_DscpCosId {
+        key 'nrp_cosName';
+        config true;
+        ordered-by system;
+        uses G_NRP_DscpCosId;
+    }
+    grouping G_NRP_DscpCosId {
+        leaf nrp_ipVersion {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_IpVersion;
+            description "IPv4, or IPv6, or both IPv4 and IPv6.";
+        }
+        leaf-list nrp_dscpValue {
+            description "List DSCP values map to the same cos name.";
+            ordered-by system;
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            min-elements 1;
+        }
+        leaf nrp_cosName {
+            type string;
+            description "Class of Service name.";
+        }
+    }
+    list NRP_PcpEecId {
+        key 'nrp_eecName';
+        config true;
+        ordered-by system;
+        uses G_NRP_PcpEecId;
+    }
+    grouping G_NRP_PcpEecId {
+        leaf nrp_vlanTag {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_VlanTag;
+            description "Which vlan tag pcp to be used for ceec identier, S tag or C tag. S tag is not valid for EvcEndPoint. ";
+        }
+        leaf-list nrp_pcpValue {
+            description "List of PCP values that map to the eec name.";
+            ordered-by system;
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            min-elements 1;
+        }
+        leaf nrp_eecName {
+            type string;
+            description "Egress Equivelance Class name.";
+        }
+    }
+    list NRP_DscpEecId {
+        key 'nrp_eecName';
+        config true;
+        ordered-by system;
+        uses G_NRP_DscpEecId;
+    }
+    grouping G_NRP_DscpEecId {
+        leaf nrp_ipVersion {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_IpVersion;
+            description "IPv4, or IPv6, or both IPv4 and IPv6.";
+        }
+        leaf-list nrp_dscpValue {
+            description "List DSCP values map to the same eec name.";
+            ordered-by system;
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            min-elements 1;
+        }
+        leaf nrp_eecName {
+            type string;
+            description "Egress Equivalence Class name.";
+        }
+    }
+    grouping G_NRP_ServiceAccessPointEecId {
+        leaf nrp_eecName {
+            type string;
+            description "Egress Equivalence Class name.";
+        }
+    }
+    list NRP_EecIdentifier {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_EecIdentifier;
+    }
+    grouping G_NRP_EecIdentifier {
+        container nrp_pcpeecid {
+            config true;
+            uses G_NRP_PcpEecId;
+        }
+        container nrp_dscpeecid {
+            config true;
+            uses G_NRP_DscpEecId;
+        }
+        container nrp_serviceaccesspointeecid {
+            config true;
+            uses G_NRP_ServiceAccessPointEecId;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list NRP_PcpForColorEgressMap {
+        key 'nrp_vlanTag';
+        config true;
+        ordered-by system;
+        uses G_NRP_PcpForColorEgressMap;
+    }
+    grouping G_NRP_PcpForColorEgressMap {
+        leaf nrp_vlanTag {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_VlanTag;
+            description "S tag or C tag for OvcEndPoint and C tag for EvcEndPoint.";
+        }
+        leaf nrp_ingressCosName {
+            type string;
+            description "Ingress CoS name.";
+        }
+        leaf nrp_ingressColor {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_FrameColor;
+            description "The ingress color may be considered as part of the egress mapping. ";
+        }
+        leaf nrp_pcpValue {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_PcpOrDiscard;
+            description "Egress frame PCP value (S tag ot C tag is from vlanTag attribute), mapping from ingress CoS name and ingress frame color. ";
+        }
+    }
+    list NRP_EgressMap {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_EgressMap;
+    }
+    grouping G_NRP_EgressMap {
+        container nrp_deiforcoloregressmap {
+            config true;
+            uses G_NRP_DeiForColorEgressMap;
+        }
+        container nrp_pcpforcoloregressmap {
+            config true;
+            uses G_NRP_PcpForColorEgressMap;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list NRP_DeiForColorEgressMap {
+        key 'nrp_vlanTag';
+        config true;
+        ordered-by system;
+        uses G_NRP_DeiForColorEgressMap;
+    }
+    grouping G_NRP_DeiForColorEgressMap {
+        leaf nrp_vlanTag {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_VlanTag;
+            description "S tag or C tag for OvcEndPoint and C tag for EvcEndPoint.";
+        }
+        leaf nrp_ingressCosName {
+            type string;
+            description "Ingress CoS name.";
+        }
+        leaf nrp_ingressColor {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_FrameColor;
+            description "The ingress color may be considered as part of the egress mapping. ";
+        }
+        leaf nrp_deiValue {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_DeiOrDiscard;
+            description "Egress frame DEI value (S tag ot C tag is from vlanTag attribute), including the ingress color indication.";
+        }
+    }
+    list NRP_BwpFlow {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_BwpFlow;
+    }
+    grouping G_NRP_BwpFlow {
+        leaf nrp_bwpFlowIndex {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_PositiveInteger;
+            description "The index i=1,2,ā€¦,n is used to index the Bandwidth Profile Flow among all Bandwidth Profile Flows that are mapped to a given Envelope";
+        }
+        leaf nrp_cir {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "Committed Information Rate that limits the average rate of frames that will be declared Green. In bits per second.";
+        }
+        leaf nrp_cirMax {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "Maximum Committed Information Rate that limits the rate of tokens added to the committed token bucket. In bits per second.";
+        }
+        leaf nrp_cbs {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "Committed Burst Size that limits the maximum number of bytes available for a burst of frames that will be declared Green, in bytes,";
+        }
+        leaf nrp_eir {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "Excess Information Rate that limits the average rate of frames that will be declared Yellow, in bits per second.";
+        }
+        leaf nrp_eirMax {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "Maximum Excess Infor-mation Rate that Limits the rate of tokens added to the excess token bucket, in bits per second.";
+        }
+        leaf nrp_ebs {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "Excessive Burst Size that limits the maximum number of bytes available for a burst of frames that will be declared Yellow, in bytes.";
+        }
+        leaf nrp_couplingFlag {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "Coupling Flag that Determines if overflow Green tokens can be used as Yellow tokens. Value 0 for NO and value 1 for YES.";
+        }
+        leaf nrp_colorMode {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_ColorMode;
+            description "Color Mode that Indicates whether the Color Identifier of the frame is considered by the Bandwidth Profile Algorithm.";
+        }
+        leaf nrp_rank {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_PositiveInteger;
+            description "Bandwidth prorile flow rank in an associated Envelope.";
+        }
+        leaf nrp_tokenRequestOffset {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "Adjusts the number of tokens requested for each external interface frame.";
+        }
+        leaf-list nrp_bwpflowrank {
+            ordered-by system;
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:NRP_BwpFlowRank/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list NRP_IngressBwpPerCosName {
+        key 'nrp_cosName';
+        config true;
+        ordered-by system;
+        uses G_NRP_IngressBwpPerCosName;
+    }
+    grouping G_NRP_IngressBwpPerCosName {
+        leaf nrp_cosName {
+            type string;
+            description "Class of Service name.";
+        }
+        container nrp_bwpflow {
+            config true;
+            uses G_NRP_BwpFlow;
+        }
+    }
+    list NRP_EgressBwpPerEecName {
+        key 'nrp_eecName';
+        config true;
+        ordered-by system;
+        uses G_NRP_EgressBwpPerEecName;
+    }
+    grouping G_NRP_EgressBwpPerEecName {
+        leaf nrp_eecName {
+            type string;
+            description "Egress Equivelance Class name.";
+        }
+    }
+    grouping G_NRP_ServiceAccessPointColorId {
+        leaf nrp_color {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_FrameColor;
+            description "Green or Yellow.";
+        }
+    }
+    grouping G_NRP_PcpColorId {
+        leaf nrp_vlanTag {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_VlanTag;
+            description "Which vlan tag pcp to be used for color identier, S tag or C tag. S-tag is not valid for EvcEndPoint. ";
+        }
+        leaf-list nrp_pcpValue {
+            description "List PCP values map to the same color.";
+            ordered-by system;
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            min-elements 1;
+        }
+        leaf nrp_color {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_FrameColor;
+            description "Green or Yellow.";
+        }
+    }
+    grouping G_NRP_DeiColorId {
+        leaf nrp_vlanTag {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_VlanTag;
+            description "Which vlan tag pcp to be used for color identier, S tag or C tag. S-tag is not valid for EvcEndPoint. ";
+        }
+        leaf-list nrp_deiValue {
+            description "DEI=0 or DEI=1";
+            ordered-by system;
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            max-elements 2;
+            min-elements 1;
+        }
+        leaf nrp_color {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_FrameColor;
+            description "Green or Yellow";
+        }
+    }
+    grouping G_NRP_DespColorId {
+        leaf nrp_ipVersion {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_IpVersion;
+            description "IPv4, or IPv6, or both IPv4 and IPv6.";
+        }
+        leaf-list nrp_dscpValue {
+            description "List DSCP values map to the same color.";
+            ordered-by system;
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+        }
+        leaf nrp_color {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_FrameColor;
+            description "Green or Yellow";
+        }
+    }
+    grouping G_NRP_ColorIdentifier {
+        container nrp_endPointColorId {
+            description "A choice that maps EVC End Point or OVC End Point to Color.";
+            config true;
+            uses G_NRP_ServiceAccessPointColorId;
+        }
+        container nrp_pcpColorId {
+            description "A choice that maps Vlan tag PCPs to Color.";
+            config true;
+            uses G_NRP_PcpColorId;
+        }
+        container nrp_deiColorId {
+            description "A choice that maps Vlan tag DEI to Color.";
+            config true;
+            uses G_NRP_DeiColorId;
+        }
+        container nrp_despColorId {
+            description "A choice that maps DSCP values to Color.";
+            config true;
+            uses G_NRP_DespColorId;
+        }
+    }
+    list NRP_BwpFlowRank {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_BwpFlowRank;
+    }
+    grouping G_NRP_BwpFlowRank {
+        leaf nrp_bwpFlowRankInEnvelope {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+        }
+        leaf nrp_bwpflow {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:NRP_BwpFlow/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:id';
+            }
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list NRP_Envelope {
+        key 'nrp_envelopeId';
+        config true;
+        ordered-by system;
+        uses G_NRP_Envelope;
+    }
+    grouping G_NRP_Envelope {
+        leaf nrp_envelopeId {
+            type string;
+        }
+        leaf nrp_couplingFlagForIndexZero {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "Coupling flag for index zero. 0 for NO and 1 for YES (overflow Green tokens can be used as Yellow tokens)";
+        }
+        leaf-list nrp_bwpflowrank {
+            ordered-by system;
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:NRP_BwpFlowRank/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:id';
+            }
+        }
+    }
+    grouping G_NRP_EtherTypeL2cpId {
+        leaf nrp_etherTypeValue {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "EtherType, e.g., 0x8809";
+        }
+        leaf-list nrp_subType {
+            description "List of sub types. Can be NULL.";
+            ordered-by system;
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+        }
+    }
+    grouping G_NRP_LlcAddressL2cpId {
+        leaf nrp_llcAddress {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "LLC Address";
+        }
+    }
+    grouping G_NRP_L2cpProtocolIdentifier {
+        container nrp_llcAddressL2cpId {
+            description "Choice of L2CP Protocol Identifier based on LLC Address.";
+            config true;
+            uses G_NRP_LlcAddressL2cpId;
+        }
+        container nrp_etherTypeL2cpId {
+            description "Choice of L2CP Protocol Identifier based on EtherType w/o SubTypes";
+            config true;
+            uses G_NRP_EtherTypeL2cpId;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    grouping G_NRP_ServiceAccessPointCosId {
+        leaf nrp_cosName {
+            type string;
+            description "Class of Service name.";
+        }
+        list nrp_l2cpprotocolidentifier {
+            description "List of L2CP Protocol Identifiers that map to the CoS Name.";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_NRP_L2cpProtocolIdentifier;
+        }
+    }
+    grouping G_NRP_DataFrameCosIdentifier {
+        container nrp_endPointCosId {
+            description "This is one choice of the CosProfile, for the EVC based CoS Identifier.";
+            config true;
+            uses G_NRP_ServiceAccessPointCosId;
+        }
+        list nrp_pcpCosId {
+            description "This is one choice of the CosProfile, for the PCP based CoS Identifier.";
+            key 'nrp_cosName';
+            config true;
+            ordered-by system;
+            uses G_NRP_PcpCosId;
+            max-elements 8;
+            min-elements 1;
+        }
+        list nrp_dscpCosId {
+            description "This is one choice of the CosProfile, for the DSCP based CoS Identifier.";
+            key 'nrp_cosName';
+            config true;
+            ordered-by system;
+            uses G_NRP_DscpCosId;
+            max-elements 64;
+            min-elements 1;
+        }
+    }
+}
diff --git a/api/src/main/yang/NRP_Interface-ObjectClasses-NRP_SpecPackage.yang b/api/src/main/yang/NRP_Interface-ObjectClasses-NRP_SpecPackage.yang
new file mode 100644 (file)
index 0000000..de1d7ae
--- /dev/null
@@ -0,0 +1,658 @@
+module NRP_Interface-ObjectClasses-NRP_SpecPackage {
+    namespace "uri:onf:NRP_Interface-ObjectClasses-NRP_SpecPackage";
+    prefix NRP_Interface-ObjectClasses-NRP_SpecPackage;
+    import NetworkResource-Main-ObjectClasses {
+        prefix NetworkResource-Main-ObjectClasses;
+    }
+    import NRP_Interface-TypeDefinitions-NRP_Types {
+        prefix NRP_Interface-TypeDefinitions-NRP_Types;
+    }
+    import NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage {
+        prefix NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage;
+    }
+    revision 2016-04-13{}
+    list NRP_TerminationSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_TerminationSpec;
+    }
+    grouping G_NRP_TerminationSpec {
+        uses NetworkResource-Main-ObjectClasses:G_CeTerminSpec;
+        leaf nrp_physicalLayer {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_PhysicalLayer;
+            description "This attribute is a list of physical layers, one for each physical link implementing the UNI or ENNI. Different physical links can use different physical layers. The Physical Layer for each physical link implementing the UNI or ENNI MUST be one of the PHYs listed in IEEE Std 802.3 ā€“ 2012 but excluding 1000BASE-PX-D and 1000BASE-PX-U.
+Reference MEF 10.3, Section 9.2.";
+        }
+        list nrp_syncMode {
+            description "The Synchronous Mode Service Attribute is a list with one item for each of the physical links. When the value of an item is ā€œEnabled,ā€ the bits transmitted from the CEN to the CE on the physical link corresponding to the item can be used by the CE as a bit clock reference.
+Reference MEF 10.3, Section 9.3.";
+            key 'linkId';
+            config true;
+            ordered-by system;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_SyncModePerLink;
+            min-elements 1;
+        }
+        leaf nrp_numberOfLinks {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute specifies the number of links at the Ethernet Service Interface (UNI or ENNI).
+MEF 10.3, Section 9.4.";
+        }
+        leaf nrp_resiliency {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_InterfaceResiliency;
+            description "This attribute value is one of None, 2-Link Active/Standby, All Active, or Other.
+MEF 10.3, Section 9.5.  MEF 10.3.2, MEF 26.2
+";
+        }
+        container nrp_portConvsIdToAggLinkMap {
+            description "The Port Conversation ID to Aggregation Link Map Attribute is applicable only when the EthernetServiceInterface resiliency attribute has the value of All Active. Its value is a Port Conversation ID to Aggregation Link Map as defined in IEEE Std 802.1AX ā€“ 2014.
+MEF 10.3.2";
+            config true;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_ConversationIdToAggrgationLinkMap;
+        }
+        leaf nrp_maxFrameSize {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This value limits the length of frames carried by an EVC/OVC that associates an EVC/OVC End Point. The minimum of this maxinum number for UNI and ENNI are different.
+MEF 10.3, Section 9.7.";
+        }
+        leaf nrp_linkOamEnabled {
+            type boolean;
+            description "When the value of the Link OAM attribute is Enabled, Link OAM musd tbe run on all physical links in the UNI/ENNI.
+MEF 10.3, Section 9.16.";
+        }
+        leaf nrp_tokenShareEnabled {
+            type boolean;
+            description "When the value of the Token Share Service attribute is Enabled, at least one Envelope at the UNI/ENNI MUST be able to have two or more Bandwidth Profiles mapped to it.
+MEF 6.2, Section 8.2.1. ";
+        }
+        leaf-list nrp_CeServiceAccessPoint {
+            description "The Network Interface relationship to supporting zero to many Logical Interface flow points.";
+            ordered-by system;
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_ConnAdaptSpec/NRP_Interface-ObjectClasses-NRP_SpecPackage:id';
+            }
+        }
+        leaf-list nrp_envelope {
+            description "MEF 10.3, Section 12.1.
+MEF 6.2, Section 8.2.2.";
+            ordered-by system;
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:NRP_Envelope/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:nrp_envelopeId';
+            }
+        }
+        leaf nrp_serviceProviderUniId {
+            type string;
+            description "MEF 10.3, Section 9.1.";
+        }
+    }
+    list NRP_ENNI_TerminationSpec {
+        key 'id';
+        config true;
+        uses G_NRP_TerminationSpec;
+        leaf nrp_linkAggLinkMegEnabled {
+            type string;
+            description " When the value of the Operator UNI LAG Link MEG Service Attribute is Enabled, the Operator CEN MUST operate the LAG Link MEG on each link in the UNI. This may be a candidate for UNI service attribute.
+MEF 26.2";
+        }
+    }
+    list NRP_INNI_TerminationSpec {
+        key 'id';
+        config true;
+        uses G_NRP_TerminationSpec;
+    }
+    list NRP_UNI_TerminationSpec {
+        key 'id';
+        config true;
+        uses G_NRP_TerminationSpec;
+        container nrp_defaultCeVlanId {
+            description "This is the CE-VLAN ID value assigned to Untagged Service Frames and Priority Tagged Service Frames. In MEF 10.3, it is called CE Vlan ID for untagged and priority tagged service frames.
+MEF 10.3, Section 9.9.";
+            config true;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+        }
+        leaf nrp_uniMegEnabled {
+            type boolean;
+            description "When the value of the UNI MEG Service Attribute is Enabled, the CEN MUST meet the mandatory requirements in MEF 30.1 that apply to the UNI MEG
+MEF 10.3, Section 9.17.";
+        }
+        leaf nrp_elmiEnabled {
+            type boolean;
+            description "When the value of the E-LMI Service Attribute is Enabled, the CEN MUST meet the mandatory requirements in MEF 16 that apply to the UNI-N.
+MEF 10.3, Section 9.18";
+        }
+        leaf nrp_serviceprovideruniprofile {
+            type string;
+        }
+        leaf nrp_operatoruniprofile {
+            type string;
+        }
+        leaf nrp_ingressBwpUni {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:NRP_BwpFlow/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:id';
+            }
+            description "MEF 10.3, Section 9.14";
+        }
+        leaf nrp_egressBwpUni {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:NRP_BwpFlow/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:id';
+            }
+            description "MEF 10.3, Section 9.15";
+        }
+    }
+    list NRP_EvcEndpoint_ConnAdaptSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_EvcEndpoint_ConnAdaptSpec;
+        min-elements 2;
+    }
+    grouping G_NRP_EvcEndpoint_ConnAdaptSpec {
+        uses G_NRP_ConnAdaptSpec;
+        leaf nrp_evcEndPointId {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_Identifier45;
+            description "The EVC End Point Identification. This attribute is adapted from MEF 26.2. MEF 10.3 uses \"EVC per UNI\" for EVC End Point, therefore there is no identificaiton attribute. ";
+        }
+        leaf nrp_testMegEnabled {
+            type boolean;
+            description "When the value of the Test MEG Service Attribute is Enabled, the CEN MUST meet the mandatory requirements in Section 7.5 of MEF 30.1.
+that apply to the Test MEG";
+        }
+        leaf nrp_evcEndPointRole {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_EvcEndPointRole;
+            description "The EVC End Point Role is ROOF or LEAF.";
+        }
+        list nrp_evcEndPointMap {
+            description "This attribute provides the list of CE-VLAN IDs that maps to the EVC. MEF 10.3 and MEF 6.2 list this attriubte (CE-VLAN ID/EVC map) as UNI service attribute while MEF 26.2 decided to move this on as endpoint service attribute, just as MEF 10.1 and MEF 6.1 did. Decided to move this one to endpoint to be consistent. To be consitent, changing its name to EvcEntPointMap (MEF 26.2 lists as OVC Endpoint Map).
+";
+            key 'vid';
+            config true;
+            ordered-by system;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+            min-elements 1;
+        }
+        leaf nrp_subscriberMegMipEbabled {
+            type boolean;
+            description "When the value of the Subscriber MEG MIP Service Attribute is Enabled, the CEN MUST instantiate a Subscriber Level MIP.";
+        }
+        container nrp_elasticserviceconstraintprofile {
+            config true;
+            uses G_NRP_ElasticServiceConstraintProfile;
+        }
+        leaf nrp_evc {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_EdgeCeFcSpec/NRP_Interface-ObjectClasses-NRP_SpecPackage:uuid';
+            }
+        }
+    }
+    list NRP_IvcEndpoint_ConnAdaptSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_IvcEndpoint_ConnAdaptSpec;
+    }
+    grouping G_NRP_IvcEndpoint_ConnAdaptSpec {
+        uses G_NRP_ConnAdaptSpec;
+        leaf nrp_ivcEndPointId {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_Identifier45;
+            description "The EVC End Point Identification. This attribute is adapted from MEF 26.2. MEF 10.3 uses \"EVC per UNI\" for EVC End Point, therefore there is no identificaiton attribute. ";
+        }
+        leaf nrp_testMegEnabled {
+            type boolean;
+            description "When the value of the Test MEG Service Attribute is Enabled, the CEN MUST meet the mandatory requirements in Section 7.5 of MEF 30.1.
+that apply to the Test MEG";
+        }
+        leaf nrp_ivcEndPointRole {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_EndPointRole;
+            description "The EVC End Point Role is ROOF or LEAF.";
+        }
+        leaf-list nrp_ivcEndPointMap {
+            description "This attribute provides the list of CE-VLAN IDs that maps to the EVC. MEF 10.3 and MEF 6.2 list this attriubte (CE-VLAN ID/EVC map) as UNI service attribute while MEF 26.2 decided to move this on as endpoint service attribute, just as MEF 10.1 and MEF 6.1 did. Decided to move this one to endpoint to be consistent. To be consitent, changing its name to EvcEntPointMap (MEF 26.2 lists as OVC Endpoint Map).
+";
+            ordered-by system;
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_EndPointMap/NRP_Interface-ObjectClasses-NRP_SpecPackage:id';
+            }
+            min-elements 1;
+        }
+        leaf nrp_subscriberMegMipEbabled {
+            type boolean;
+            description "When the value of the Subscriber MEG MIP Service Attribute is Enabled, the CEN MUST instantiate a Subscriber Level MIP.";
+        }
+    }
+    list NRP_ConnAdaptSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_ConnAdaptSpec;
+    }
+    grouping G_NRP_ConnAdaptSpec {
+        uses NetworkResource-Main-ObjectClasses:G_CeConnPtAndAdaptSpec;
+        container nrp_sourceMacAddressLimit {
+            description "MEF 10.3, Section 10.9";
+            config true;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_SourceMacAddressLimit;
+        }
+        leaf nrp_CeExternalInterface {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_TerminationSpec/NRP_Interface-ObjectClasses-NRP_SpecPackage:id';
+            }
+        }
+        container nrp_egressMap {
+            description "MEF 7.3";
+            config true;
+            uses NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:G_NRP_EgressMap;
+        }
+        container nrp_eecIdentifier {
+            config true;
+            uses NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:G_NRP_EecIdentifier;
+        }
+        container nrp_coloridentifier {
+            config true;
+            uses NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:G_NRP_ColorIdentifier;
+        }
+        leaf nrp_ingressBwpFlow {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:NRP_BwpFlow/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:id';
+            }
+        }
+        leaf nrp_egressBwpFlow {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:NRP_BwpFlow/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:id';
+            }
+        }
+        container nrp_cosidentifier {
+            config true;
+            uses NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:G_NRP_DataFrameCosIdentifier;
+        }
+        container nrp_ingressbwppercosname {
+            config true;
+            uses NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:G_NRP_IngressBwpPerCosName;
+        }
+        container nrp_egressbwppereecname {
+            config true;
+            uses NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:G_NRP_EgressBwpPerEecName;
+        }
+        leaf nrp_l2cpAddressSet {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_L2cpAddressSet;
+        }
+        list nrp_l2cpPeering {
+            description "The L2CP Peering service attribute value MUST be an empty list, or a list
+of entries identifying protocols to be Peered where each entry consists of
+{Destination Address, Protocol Identifier} or {Destination Address, Protocol
+Identifier, Link Identifier}.
+MEF 45, Section 8.2";
+            key 'protocolId';
+            config true;
+            ordered-by system;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_L2cpPeering;
+        }
+    }
+    list NRP_EdgeCeFcSpec {
+        key 'uuid';
+        config true;
+        ordered-by system;
+        uses G_NRP_EdgeCeFcSpec;
+    }
+    grouping G_NRP_EdgeCeFcSpec {
+        uses G_NRP_CeFcSpec;
+        list nrp_evcEndpoint {
+            key 'id';
+            config true;
+            ordered-by system;
+            uses G_NRP_EvcEndpoint_ConnAdaptSpec;
+            min-elements 1;
+        }
+        leaf-list nrp_ovcEndpoint {
+            ordered-by system;
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_OvcEndpoint_ConnAdaptSpec/NRP_Interface-ObjectClasses-NRP_SpecPackage:id';
+            }
+        }
+        leaf-list nrp_ivcEndpoint {
+            ordered-by system;
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_IvcEndpoint_ConnAdaptSpec/NRP_Interface-ObjectClasses-NRP_SpecPackage:id';
+            }
+        }
+        leaf nrp_ceVlanIdPreservation {
+            type boolean;
+            description "The CE-VLAN ID preserved represents the CE-VLAN ID relationship between the ingress Service Frame and its corresponding egress Service Frame(s). Reference MEF 10.3, Section 8.6.1.";
+        }
+        leaf nrp_ceVlanCosPreservation {
+            type boolean;
+            description "The CE-VLAN CoS preservation represents the PCP value relationship between the ingress Service Frame and its corresponding egress Service Frame(s). Reference MEF 10.3, Section 8.6.2.";
+        }
+        leaf nrp_CeEvcFcPortSetSpec {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_CeEvcFcPortSetSpec/NRP_Interface-ObjectClasses-NRP_SpecPackage:id';
+            }
+        }
+    }
+    list NRP_ElasticServiceConstraintProfile {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_ElasticServiceConstraintProfile;
+    }
+    grouping G_NRP_ElasticServiceConstraintProfile {
+        leaf nrp_cirUpperBound {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute sets the elastic CIR upper bound.";
+        }
+        leaf nrp_cirEirLowerBound {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute sets the elastic CIR and EIR lower bound.";
+        }
+        leaf nrp_cirEirUpperBound {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute sets the elastic CIR and EIR upper bound.";
+        }
+        leaf nrp_modReqLimit {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute sets the modification request limit.";
+        }
+        leaf nrp_modIntervalLimit {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attributes sets the modification interval limit. ";
+        }
+        leaf nrp_currentCir {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute reflects the current CIR.";
+        }
+        leaf nrp_currentCbs {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute reflects the current CBS.";
+        }
+        leaf nrp_currentEir {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute reflects the current EIR.";
+        }
+        leaf nrp_currentEbs {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute reflects the current EBS.";
+        }
+        list nrp_currentCeVlanIdList {
+            description "This attribute reflects the current CE-VLAN ID list.";
+            key 'vid';
+            config true;
+            ordered-by system;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+            min-elements 1;
+        }
+        container nrp_currentUniACeVlanId {
+            description "This attribute reflects the current UNI A CE-VLAN ID.";
+            config true;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+        }
+        container nrp_currentUniZCeVlanId {
+            description "This attribute reflects the current UNI Z CE-VLAN ID.";
+            config true;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    list NRP_TransitCeFcSpec {
+        key 'uuid';
+        config true;
+        uses G_NRP_CeFcSpec;
+        leaf nrp_sVlanIdPreservation {
+            type boolean;
+            description "The OVC S-VLAN ID Preservation Service Attribute describes a relationship between the S-VLAN ID value of a frame at one ENNI and the S-VLAN ID value of the corresponding frame at another ENNI supported by the Operator CEN where each ENNI has an OVC End Point that is associated by the OVC";
+        }
+        leaf nrp_sVlanPcpPreservation {
+            type boolean;
+            description "The OVC S-VLAN PCP Preservation Service Attribute describes a relationship between the S-VLAN PCP value of a frame at one ENNI and the S-VLAN PCP of the corresponding frame at another ENNI supported by the Operator CEN where each ENNI has an OVC End Point that is associated by the OVC";
+        }
+        leaf-list nrp_ListOfCosNames {
+            description "The value of the List of Class of Service Names Service Attribute is a list of Class of Service Names. Each ingress ENNI Frame or ingress Service Frame is assigned a Class of Service Name via the frameā€™s Class of Service Identifier. The Class of Service Name that is assigned to a frame indicates the performance objectives that apply to frame under appropriate conditions.";
+            ordered-by system;
+            type string;
+        }
+        leaf-list nrp_ovcEndpoint {
+            ordered-by system;
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_OvcEndpoint_ConnAdaptSpec/NRP_Interface-ObjectClasses-NRP_SpecPackage:id';
+            }
+        }
+        leaf-list nrp_ivcEndpoint {
+            ordered-by system;
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_IvcEndpoint_ConnAdaptSpec/NRP_Interface-ObjectClasses-NRP_SpecPackage:id';
+            }
+        }
+        leaf nrp_CeEthFcPortSetSpec {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_CeEthFcPortSetSpec/NRP_Interface-ObjectClasses-NRP_SpecPackage:id';
+            }
+        }
+    }
+    list NRP_CeFcSpec {
+        key 'uuid';
+        config true;
+        ordered-by system;
+        uses G_NRP_CeFcSpec;
+    }
+    grouping G_NRP_CeFcSpec {
+        uses NetworkResource-Main-ObjectClasses:G_CeFcSpec;
+        leaf nrp_connectionType {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_ConnectionType;
+            description "Virtual connection (EVC or OVC).";
+        }
+        leaf nrp_unicastFrameDelivery {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_ServiceFrameDelivery;
+            description "A Data Service Frame with a unicast Destination MAC Address is defined to be a Multicast Data Service Frame. Reference MEF 10.3, Section 8.5.2.";
+        }
+        leaf nrp_multicastFrameDelivery {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_ServiceFrameDelivery;
+        }
+        leaf nrp_broadcastFrameDelivery {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_ServiceFrameDelivery;
+            description "A Data Service Frame with a broadcast Destination MAC Address is defined to be a Broadcast Data Service Frame. Reference MEF 10.3, Section 8.5.2 for EVC and MEF 26.1, Section x.y for OVC.";
+        }
+        leaf nrp_vcMaxServiceFrame {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_PositiveInteger;
+            description "The value for the EVC or OVC Maximum Service Frame Size is a positive integer in bytes. Reference MEF 10.3, Section 8.9 for EVC and MEF 26.1 Section x.y for OVC.";
+        }
+        leaf nrp_vcId {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_Identifier45;
+            description "The EVC ID is an arbitrary string administered by the Service Provider that is used to identify an EVC within the CEN.
+MEF 10.3, Section 8.2.";
+        }
+    }
+    list NRP_EndPointMap {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_EndPointMap;
+    }
+    grouping G_NRP_EndPointMap {
+        container nrp_endPointMapFormE {
+            description "Form E (E for ENNI).";
+            config true;
+            uses G_NRP_EndPointMapFormE;
+        }
+        container nrp_endPointMapFormT {
+            description "Form T (T for Trunk) ";
+            config true;
+            uses G_NRP_EndPointMapFormT;
+        }
+        container nrp_endPointMapFormV {
+            description "Form V (V for VUNI).";
+            config true;
+            uses G_NRP_EndPointMapFormV;
+        }
+        container nrp_endPointMapFormU {
+            description "Form U (U for UNI) .";
+            config true;
+            uses G_NRP_EndPointMapFormU;
+        }
+        leaf id {
+            type string;
+        }
+    }
+    grouping G_NRP_EndPointMapFormE {
+        list nrp_sVid {
+            description "List of S-VLAN IDs";
+            key 'vid';
+            config true;
+            ordered-by system;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+            min-elements 1;
+        }
+    }
+    grouping G_NRP_EndPointMapFormT {
+        container nrp_rootSVid {
+            description "Root S-VLAN ID";
+            config true;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+        }
+        container nrp_leafSVid {
+            description "Leaf S-VLAN ID";
+            config true;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+        }
+    }
+    grouping G_NRP_EndPointMapFormV {
+        container nrp_sVid {
+            description "S-VLAN ID";
+            config true;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+        }
+        list nrp_enniCeVid {
+            description "List of ENNI CE-CLAN IDs";
+            key 'vid';
+            config true;
+            ordered-by system;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+            min-elements 1;
+        }
+    }
+    grouping G_NRP_EndPointMapFormU {
+        list nrp_cVid {
+            description "List of CE-VLAN IDs";
+            key 'vid';
+            config true;
+            ordered-by system;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+            min-elements 1;
+        }
+    }
+    list NRP_OvcEndpoint_ConnAdaptSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_OvcEndpoint_ConnAdaptSpec;
+    }
+    grouping G_NRP_OvcEndpoint_ConnAdaptSpec {
+        uses G_NRP_ConnAdaptSpec;
+        leaf nrp_ovcEndPointId {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_Identifier45;
+            description "OVC End Point Identifier (MEF 26.2).";
+        }
+        leaf nrp_ovcEndPointRole {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_EndPointRole;
+            description "OVC End Point Role is ROOF, LEAF, or TRUNK.";
+        }
+        leaf nrp_mipEnabled {
+            type boolean;
+            description "When the value is Enabled, several parameter values, including the MEG Level, need to be determined as described in MEF 30.1. This Service Attribute is only applicable when the OVC End Point is at an ENNI and not in a VUNI.";
+        }
+        list nrp_enniMepList {
+            description "The value of the OVC End Point Maintenance End Point List Service Attribute is a list of pairs, one for each MEP that is instantiated. Each pair is of the form <l,d> where l equals the MEG Level, and d is the direction for the MEP, either Up or Down. ";
+            key 'nrp_megId';
+            config true;
+            ordered-by system;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_MepLevelAndDirection;
+        }
+        leaf nrp_enniTaggedL2cp801dotCompliant {
+            type boolean;
+            description "This attribute reflects the capability of the ENNI to process S-VLAN-tagged L2CP Frames in an 802.1 compliant manner.";
+        }
+        container nrp_endPointMap {
+            config true;
+            uses G_NRP_EndPointMap;
+        }
+        list nrp_aggregationLinkDepth {
+            description "This attribute only applies to OVC End Points at an ENNI and the ENNI linkAggregation has the value ALL_ACTIVE, or EVC/OVC End Points at UNI and the UNI linkAggregation has the value ALL_ACTIVE. The attribute value is a list of pairs of the form (s,n) where s is an VLAN ID value that is contained in the value of the OVC End Point Map Service Attribute and n is an integer in the range 1 to the value of the ENNI Number of Links. n specifies the number of links in the ENNI Port Conversation ID to Aggregation Link Map for the S-VLAN ID value s.";
+            key 'nrp_linkNumber';
+            config true;
+            ordered-by system;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_AggLinkDepth;
+        }
+    }
+    list NRP_VUNI {
+        key 'id';
+        config true;
+        uses G_NRP_OvcEndpoint_ConnAdaptSpec;
+        leaf nrp_vuniIdentifier {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_Identifier45;
+            description "This allows the SP/SO and the Operator to uniquely identify a VUNI for operations purposes";
+        }
+        container nrp_sVid {
+            description "The value of this attribute uniquely identifies the VUNI at the ENNI.";
+            config true;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+        }
+        container nrp_defaultCeVid {
+            description "This attribute is needed for the definition of the ENNI CE-VLAN ID for an ENNI Frame. The ENNI CE-VLAN ID is used in Form V of the OVC End Point Map Service Attribute at an ENNI.  0 for no C-TAG";
+            config true;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_VlanId;
+        }
+        leaf nrp_maxNumOvcEndpoint {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute defines the maximum number of OVC End Points that the ENNI can support.";
+        }
+        leaf nrp_maxNumEnniCeVlanIdPerOvcEndPoint {
+            type NRP_Interface-TypeDefinitions-NRP_Types:NRP_NaturalNumber;
+            description "This attribute value is the largest number of ENNI CE-VLAN ID values that can map to an OVC End Point in a value of the OVC End Point Map Service Attribute for an OVC End Point that is in the VUNI.";
+        }
+        list nrp_vuniEndPointMepList {
+            description "This attribute provides a list of pairs, one for each MEP that is instantiated. Each pair is of the form <l,d> where š‘™ equals the MEG Level, and š‘‘ is the direction for the MEP, either Up or Down.";
+            key 'nrp_megId';
+            config true;
+            ordered-by system;
+            uses NRP_Interface-TypeDefinitions-NRP_Types:G_NRP_MepLevelAndDirection;
+        }
+        leaf nrp_ingressbwp {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:NRP_BwpFlow/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:id';
+            }
+        }
+        leaf nrp_egressbwp {
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:NRP_BwpFlow/NRP_Interface-ObjectClasses-NRP_BandwidthProfilePackage:id';
+            }
+        }
+        leaf-list nrp_ovcendpoint {
+            ordered-by system;
+            type leafref {
+                path '/NRP_Interface-ObjectClasses-NRP_SpecPackage:NRP_OvcEndpoint_ConnAdaptSpec/NRP_Interface-ObjectClasses-NRP_SpecPackage:id';
+            }
+        }
+    }
+    list NRP_CeEvcFcPortSetSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_CeEvcFcPortSetSpec;
+    }
+    grouping G_NRP_CeEvcFcPortSetSpec {
+        uses NetworkResource-Main-ObjectClasses:G_CeEvcFcPortSetSpec;
+    }
+    list NRP_CeEthFcPortSetSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_NRP_CeEthFcPortSetSpec;
+    }
+    grouping G_NRP_CeEthFcPortSetSpec {
+        uses NetworkResource-Main-ObjectClasses:G_CeEthFcPortSetSpec;
+    }
+    list NRP_CeLtpSpec {
+        key 'id';
+        config true;
+        uses NetworkResource-Main-ObjectClasses:G_CeLtpSpec;
+    }
+}
diff --git a/api/src/main/yang/NRP_Interface-ObjectClasses-TopologyPacs.yang b/api/src/main/yang/NRP_Interface-ObjectClasses-TopologyPacs.yang
new file mode 100644 (file)
index 0000000..60dd94e
--- /dev/null
@@ -0,0 +1,164 @@
+module NRP_Interface-ObjectClasses-TopologyPacs {
+    namespace "uri:onf:NRP_Interface-ObjectClasses-TopologyPacs";
+    prefix NRP_Interface-ObjectClasses-TopologyPacs;
+    import CoreModel-CoreNetworkModule-TypeDefinitions {
+        prefix CoreModel-CoreNetworkModule-TypeDefinitions;
+    }
+    import CoreModel-CoreNetworkModule-ObjectClasses {
+        prefix CoreModel-CoreNetworkModule-ObjectClasses;
+    }
+    revision 2016-04-13{}
+    grouping G_TransferCost_Pac {
+        list costCharacteristicList {
+            description "The list of costs where each cost relates to some aspect of the TopologicalEntity.";
+            key 'costName';
+            config true;
+            ordered-by system;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_CostCharacteristics;
+            min-elements 1;
+        }
+    }
+    grouping G_RiskParameter_Pac {
+        list riskCharacteristicList {
+            description "A list of risk characteristics for consideration in an analysis of shared risk. Each element of the list represents a specific risk consideration.";
+            key 'riskCharacteristicName';
+            config true;
+            ordered-by system;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_RiskCharacteristic;
+            min-elements 1;
+        }
+    }
+    grouping G_LayerProtocolTransition_Pac {
+        leaf-list transitionedLayerProtocolList {
+            description "Provides the ordered structure of layer protocol transitions encapsulated in the TopologicalEntity. The ordering relates to the LinkPort role.";
+            ordered-by system;
+            type string;
+            min-elements 1;
+        }
+        leaf-list _ltpRefList {
+            description "Lists the LTPs that define the layer protocol transition of the transitional link.";
+            ordered-by system;
+            type leafref {
+                path '/CoreModel-CoreNetworkModule-ObjectClasses:LogicalTerminationPoint/CoreModel-CoreNetworkModule-ObjectClasses:uuid';
+            }
+            min-elements 1;
+        }
+    }
+    grouping G_TransferTiming_Pac {
+        leaf fixedLatencyCharacteristic {
+            type string;
+            description "A TopologicalEntity suffers delay caused by the realization of the servers (e.g. distance related; FEC encoding etc.) along with some client specific processing. This is the total average latency effect of the TopologicalEntity";
+        }
+        leaf jitterCharacteristic {
+            type string;
+            description "High frequency deviation from true periodicity of a signal and therefore a small high rate of change of transfer latency.
+Applies to TDM systems (and not packet).";
+        }
+        leaf wanderCharacteristic {
+            type string;
+            description "Low frequency deviation from true periodicity of a signal and therefore a small low rate of change of transfer latency.
+Applies to TDM systems (and not packet).";
+        }
+        list queuingLatencyList {
+            description "The effect on the latency of a queuing process. This only has significant effect for packet based systems and has a complex characteristic.";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_QueuingLatency;
+        }
+    }
+    grouping G_TransferIntegrity_Pac {
+        leaf errorCharacteristic {
+            type string;
+            description "Describes the degree to which the signal propagated can be errored. 
+Applies to TDM systems as the errored signal will be propagated and not packet as errored packets will be discarded.";
+        }
+        leaf lossCharacteristic {
+            type string;
+            description "Describes the acceptable characteristic of lost packets where loss may result from discard due to errors or overflow.
+Applies to packet systems and not TDM (as for TDM errored signals are propagated unless grossly errored and overflow/underflow turns into timing slips).";
+        }
+        leaf repeatDeliveryCharacteristic {
+            type string;
+            description "Primarily applies to packet systems where a packet may be delivered more than once (in fault recovery for example). 
+It can also apply to TDM where several frames may be received twice due to switching in a system with a large differential propagation delay.";
+        }
+        leaf deliveryOrderCharacteristic {
+            type string;
+            description "Describes the degree to which packets will be delivered out of sequence.
+Does not apply to TDM as the TDM protocols maintain strict order.";
+        }
+        leaf unavailableTimeCharacteristic {
+            type string;
+            description "Describes the duration for which there may be no valid signal propagated.";
+        }
+        leaf serverIntegrityProcessCharacteristic {
+            type string;
+            description "Describes the effect of any server integrity enhancement process on the characteristics of the TopologicalEntity.";
+        }
+    }
+    grouping G_TransferCapacity_Pac {
+        container totalPotentialCapacity {
+            description "An optimistic view of the capacity of the TopologicalEntity assuming that any shared capacity is available to be taken.";
+            config true;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_Capacity;
+        }
+        container availableCapacity {
+            description "Capacity available to be assigned.";
+            config true;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_Capacity;
+        }
+        list capacityAssignedToUserView {
+            description "Capacity already assigned";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_Capacity;
+        }
+        leaf capacityInteractionAlgorithm {
+            type string;
+            description "A reference to an algorithm that describes how various chunks of allocated capacity interact (e.g. when shared)";
+        }
+    }
+    grouping G_TopologicalEntity {
+        container _riskParameter_Pac {
+            config true;
+            uses G_RiskParameter_Pac;
+        }
+        container _transferCost_Pac {
+            config true;
+            uses G_TransferCost_Pac;
+        }
+        container _transferTiming_Pac {
+            config true;
+            uses G_TransferTiming_Pac;
+        }
+        container _transferCapacity_Pac {
+            config true;
+            uses G_TransferCapacity_Pac;
+        }
+        container _transferIntegrity_Pac {
+            config true;
+            uses G_TransferIntegrity_Pac;
+        }
+        container _validation_Pac {
+            config true;
+            uses G_Validation_Pac;
+        }
+        list _layerTransition_Pac {
+            config true;
+            ordered-by system;
+            uses G_LayerProtocolTransition_Pac;
+        }
+    }
+    grouping G_Validation_Pac {
+        list validationMechanismList {
+            description "Provides details of the specific validation mechanism(s) used to confirm the presence of an intended topologicalEntity.";
+            key 'id';
+            config true;
+            ordered-by system;
+            uses CoreModel-CoreNetworkModule-TypeDefinitions:G_ValidationMechanism;
+            min-elements 1;
+        }
+    }
+}
diff --git a/api/src/main/yang/NRP_Interface-TypeDefinitions-NRP_Types.yang b/api/src/main/yang/NRP_Interface-TypeDefinitions-NRP_Types.yang
new file mode 100644 (file)
index 0000000..05f8cde
--- /dev/null
@@ -0,0 +1,262 @@
+module NRP_Interface-TypeDefinitions-NRP_Types {
+    namespace "uri:onf:NRP_Interface-TypeDefinitions-NRP_Types";
+    prefix NRP_Interface-TypeDefinitions-NRP_Types;
+    revision 2016-04-13{}
+    grouping G_NRP_SourceMacAddressLimit {
+        leaf enabled {
+            type boolean;
+        }
+        leaf limit {
+            type NRP_NaturalNumber;
+        }
+        leaf timeInterval {
+            type NRP_NaturalNumber;
+        }
+    }
+    grouping G_NRP_VlanId {
+        leaf vid {
+            type NRP_PositiveInteger;
+        }
+    }
+    typedef NRP_EvcEndPointRole {
+        type enumeration {
+            enum ROOT;
+            enum LEAF;
+        }
+    }
+    typedef NRP_Identifier45 {
+        type string;
+    }
+    typedef NRP_L2cpAddressSet {
+        type enumeration {
+            enum CTA;
+            enum CTB;
+            enum CTB2;
+        }
+    }
+    typedef NRP_PhysicalLayer {
+        type enumeration {
+            enum 10BASE2;
+            enum 10BASE5;
+            enum 10BASE_F;
+            enum 10BASE_FB;
+            enum 10BASE_FL;
+            enum 10BASE_FP;
+            enum 10BASE_T;
+            enum 10BASE_TE;
+            enum 10BROAD36;
+            enum 10PASS_TS;
+            enum 100BASE_BX10;
+            enum 100BASE_FX;
+            enum 100BASE_LX10;
+            enum 100BASE_T;
+            enum 100BASE_T2;
+            enum 100BASE_T4;
+            enum 100BASE_TX;
+            enum 100BASE_X;
+            enum 1000BASE_BX10;
+            enum 1000BASE_CX;
+            enum 1000BASE_KX;
+            enum 1000BASE_LX;
+            enum 1000BASE_LX10;
+            enum 1000BASE_PX10;
+            enum 1000BASE_PX20;
+            enum 1000BASE_SX;
+            enum 1000BASE_T;
+            enum 1000BASE_X;
+            enum 10GBASE_CX4;
+            enum 10GBASE_E;
+            enum 10GBASE_ER;
+            enum 10GBASE_EW;
+            enum 10GBASE_KR;
+            enum 10GBASE_KX4;
+            enum 10GBASE_L;
+            enum 10GBASE_LR;
+            enum 10GBASE_LRM;
+            enum 10GBASE_LW;
+            enum 10GBASE_LX4;
+            enum 10GBASE_PR;
+            enum 10GBASE_PRX;
+            enum 10GBASE_R;
+            enum 10GBASE_S;
+            enum 10GBASE_SR;
+            enum 10GBASE_SW;
+            enum 10GBASE_T;
+            enum 10GBASE_W;
+            enum 10GBASE_X;
+            enum 100GBASE_R;
+            enum 100GBASE_CR10;
+            enum 100GBASE_ER4;
+            enum 100GBASE_LR4;
+            enum 100GBASE_SR10;
+            enum 40GBASE_R;
+            enum 40GBASE_CR4;
+            enum 40GBASE__FR;
+            enum 40GBASE_KR4;
+            enum 40GBASE_LR4;
+            enum 40GBASE_SR4;
+            enum 1BASE5;
+            enum 2BASE_TL;
+            enum 1G_EPON;
+            enum 10G_EPON;
+            enum 10_1G_EPON;
+            enum 10_10G_EPON;
+            enum NONE;
+        }
+    }
+    typedef NRP_NaturalNumber {
+        type enumeration {
+            enum ENABLED;
+            enum DISABLED;
+        }
+    }
+    grouping G_NRP_SyncModePerLink {
+        leaf linkId {
+            type string;
+        }
+        leaf syncModeEnabled {
+            type boolean;
+        }
+    }
+    typedef NRP_ProtocolFrameType {
+        type enumeration {
+            enum ETHERTYPE;
+            enum LLC_ADDRESS;
+            enum OTHER;
+        }
+    }
+    typedef NRP_InterfaceResiliency {
+        type enumeration {
+            enum NONE;
+            enum 2_LINK_ACTIVE_STANDBY;
+            enum ALL_ACTIVE;
+            enum OTHER;
+        }
+    }
+    grouping G_NRP_ConversationIdToAggrgationLinkMap {
+        leaf conversationId {
+            type NRP_NaturalNumber;
+        }
+        leaf linkId {
+            type NRP_NaturalNumber;
+        }
+    }
+    grouping G_NRP_L2cpPeering {
+        leaf destinationMacAddress {
+            type string;
+            description "The destination address determines the intended recipient device for the frame.";
+        }
+        leaf protocolType {
+            type NRP_ProtocolFrameType;
+            description "Protocol Identifier is either an LLC Address or an Ethertype, and it could have subtypes. The list specifies only the L2CP Frames that
+are to be Peered. Any L2CP Frame that is not Peered will either be Discarded or Passed
+as a result of the flow charts and requirements specified in MEF 45, Section 9.";
+        }
+        leaf linkId {
+            type string;
+            description "Identifies the physical link identifier for protocols (e.g. LLDP, ESMC) that can operate over the individual physical links.
+If no link identifier is specified then the list entry will apply to all physical links. 
+MEF 45, Section 8.2";
+        }
+        leaf protocolId {
+            type string;
+        }
+    }
+    typedef NRP_ColorMode {
+        type enumeration {
+            enum COLOR_AWARE;
+            enum COLOR_BLIND;
+        }
+    }
+    typedef NRP_PositiveInteger {
+        type enumeration {
+            enum ENABLED;
+            enum DISABLED;
+        }
+    }
+    typedef NRP_VlanTag {
+        type enumeration {
+            enum S_TAG;
+            enum C_TAG;
+        }
+    }
+    typedef NRP_IpVersion {
+        type enumeration {
+            enum IPV4;
+            enum IPV6;
+            enum IPV4_AND_IPV6;
+        }
+    }
+    typedef NRP_FrameColor {
+        type enumeration {
+            enum GREEN;
+            enum YELLOW;
+        }
+    }
+    typedef NRP_PcpOrDiscard {
+        type enumeration {
+            enum DISCARD;
+            enum 0;
+            enum 1;
+            enum 2;
+            enum 3;
+            enum 4;
+            enum 5;
+            enum 6;
+            enum 7;
+        }
+    }
+    typedef NRP_DeiOrDiscard {
+        type enumeration {
+            enum DISCARD;
+            enum 0;
+            enum 1;
+        }
+    }
+    grouping G_NRP_AggLinkDepth {
+        container nrp_vlanId {
+            config true;
+            uses G_NRP_VlanId;
+        }
+        leaf nrp_linkNumber {
+            type NRP_NaturalNumber;
+        }
+    }
+    typedef NRP_ConnectionType {
+        type enumeration {
+            enum POINT_TO_POINT;
+            enum MULTIPOINT;
+            enum ROOTED_MULTIPOINT;
+        }
+    }
+    typedef NRP_ServiceFrameDelivery {
+        type enumeration {
+            enum CONDITIONALLY;
+            enum UNCONDITIONALLY;
+        }
+    }
+    typedef NRP_EndPointRole {
+        type enumeration {
+            enum ROOT;
+            enum LEAF;
+            enum TRUNK;
+        }
+    }
+    typedef NRP_MepDirection {
+        type enumeration {
+            enum DOWN;
+            enum UP;
+        }
+    }
+    grouping G_NRP_MepLevelAndDirection {
+        leaf nrp_level {
+            type NRP_NaturalNumber;
+        }
+        leaf nrp_direction {
+            type NRP_MepDirection;
+        }
+        leaf nrp_megId {
+            type string;
+        }
+    }
+}
diff --git a/api/src/main/yang/NRP_Interface-TypeDefinitions-TopologyPacs.yang b/api/src/main/yang/NRP_Interface-TypeDefinitions-TopologyPacs.yang
new file mode 100644 (file)
index 0000000..037c440
--- /dev/null
@@ -0,0 +1,75 @@
+module NRP_Interface-TypeDefinitions-TopologyPacs {
+    namespace "uri:onf:NRP_Interface-TypeDefinitions-TopologyPacs";
+    prefix NRP_Interface-TypeDefinitions-TopologyPacs;
+    revision 2016-04-13{}
+    grouping G_CostCharacteristics {
+        leaf costName {
+            type string;
+            description "The cost characteristic will related to some aspect of the TopologicalEntity (e.g. $ cost, routing weight). This aspect will be conveyed by the costName.";
+        }
+        leaf costValue {
+            type string;
+            description "The specific cost.";
+        }
+        leaf costAlgorithm {
+            type string;
+            description "The cost may vary based upon some properties of the TopologicalEntity. The rules for the variation are conveyed by the costAlgorithm.";
+        }
+    }
+    grouping G_RiskCharacteristic {
+        leaf riskCharacteristicName {
+            type string;
+            description "The name of the risk characteristic. The characteristic may be related to a specific degree of closeness. 
+For example a particular characteristic may apply to failures that are localized (e.g. to one side of a road) where as another characteristic may relate to failures that have a broader impact (e.g. both sides of a road that crosses a bridge).
+Depending upon the importance of the traffic being routed different risk characteristics will be evaluated.";
+        }
+        leaf-list riskIdentifierList {
+            description "A list of the identifiers of each physical/geographic unit (with the specific risk characteristic) that is related to a segment of the TopologicalEntity.";
+            ordered-by system;
+            type string;
+            min-elements 1;
+        }
+    }
+    grouping G_Capacity {
+        leaf totalSize {
+            type string;
+            description "Total capacity of the TopologicalEntity in MB/s";
+        }
+        leaf numberOfClientInstances {
+            type string;
+            description "Where there is some limit to the number of client (e.g. in a channelized case).";
+        }
+        leaf maximumClientSize {
+            type string;
+            description "Where a client is of variable capacity but due to some underlying realization the maximum size of the client is smaller than the totalSize.";
+        }
+        leaf numberingRange {
+            type string;
+            description "Method for identifying units of capacity via some numbering scheme.";
+        }
+    }
+    grouping G_ValidationMechanism {
+        leaf validationMechanism {
+            type string;
+            description "Name of mechanism used to validate adjacency";
+        }
+        leaf layerProtocolAdjacencyValidated {
+            type string;
+            description "State of validatiion";
+        }
+        leaf validationRobustness {
+            type string;
+            description "Quality of validation (i.e. how likely is the stated validation to be invalid)";
+        }
+    }
+    grouping G_QueuingLatency {
+        leaf trafficProperty {
+            type string;
+            description "The identifier of the specific traffic property to which the queuing latency applies.";
+        }
+        leaf latencyForTrafficWithProperty {
+            type string;
+            description "The specific queuing latency for the traffic property.";
+        }
+    }
+}
diff --git a/api/src/main/yang/NRP_Interface-TypeDefinitions.yang b/api/src/main/yang/NRP_Interface-TypeDefinitions.yang
new file mode 100644 (file)
index 0000000..02232bf
--- /dev/null
@@ -0,0 +1,77 @@
+module NRP_Interface-TypeDefinitions {
+    namespace "uri:onf:NRP_Interface-TypeDefinitions";
+    prefix NRP_Interface-TypeDefinitions;
+    revision 2016-04-13{}
+    typedef OperationalState {
+        type enumeration {
+            enum ENABLED;
+            enum DISABLED;
+        }
+    }
+    typedef OperType {
+        type enumeration {
+            enum REVERTIVE;
+            enum NON-REVERTIVE;
+        }
+    }
+    typedef Directionality {
+        type enumeration {
+            enum SINK;
+            enum SOURCE;
+            enum BIDIRECTIONAL;
+        }
+    }
+    typedef LayerProtocolName {
+        type string;
+    }
+    typedef PortRole {
+        type string;
+    }
+    typedef PortDirection {
+        type enumeration {
+            enum BIDIRECTIONAL;
+            enum INPUT;
+            enum OUTPUT;
+            enum UNIDENTIFIED_OR_UNKNOWN;
+        }
+    }
+    typedef ForwardingDirection {
+        type enumeration {
+            enum BIDIRECTIONAL;
+            enum UNIDIRECTIONAL;
+            enum UNDEFINED_OR_UNKNOWN;
+        }
+    }
+    typedef TerminationDirection {
+        type enumeration {
+            enum BIDIRECTIONAL;
+            enum SINK;
+            enum SOURCE;
+            enum UNDEFINED_OR_UNKNOWN;
+        }
+    }
+    typedef ExtendedTerminationDirection {
+        type enumeration {
+            enum BIDIRECTIONAL;
+            enum SINK;
+            enum SOURCE;
+            enum UNDEFINED_OR_UNKNOWN;
+            enum CONTRA_DIRECTION_SINK;
+            enum CONTRA_DIRECTION_SOURCE;
+        }
+    }
+    typedef ProtectionType {
+        type string;
+    }
+    typedef TerminationState {
+        type enumeration {
+            enum LP_CAN_NEVER_TERMINATE;
+            enum LT_NOT_TERMINATED;
+            enum TERMINATED_SERVER_TO_CLIENT_FLOW;
+            enum TERMINATED_CLIENT_TO_SERVER_FLOW;
+            enum TERMINATED_BIDIRECTIONAL;
+            enum LT_PERMENANTLY_TERMINATED;
+            enum TERMINATION_STATE_UNKNOWN;
+        }
+    }
+}
diff --git a/api/src/main/yang/NetworkResource-Main-ObjectClasses.yang b/api/src/main/yang/NetworkResource-Main-ObjectClasses.yang
new file mode 100644 (file)
index 0000000..f3283db
--- /dev/null
@@ -0,0 +1,197 @@
+module NetworkResource-Main-ObjectClasses {
+    namespace "uri:onf:NetworkResource-Main-ObjectClasses";
+    prefix NetworkResource-Main-ObjectClasses;
+    import CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule {
+        prefix CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule;
+    }
+    revision 2016-04-13{}
+    grouping G_CeLPSpec {
+        uses CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:G_LpSpec;
+    }
+    grouping G_CeTerminSpec {
+        uses CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:G_TerminationSpec;
+    }
+    grouping G_CeConnPtAndAdaptSpec {
+        uses CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:G_ConnectionPointAndAdapterSpec;
+    }
+    list CeLtpSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_CeLtpSpec;
+    }
+    grouping G_CeLtpSpec {
+        uses CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:G_LtpSpec;
+    }
+    grouping G_CeEndPointLpSpec {
+        uses G_CeLPSpec;
+    }
+    list CeSpUniLpSpec {
+        key 'id';
+        config true;
+        uses G_CeUniLpSpec;
+    }
+    list CeEvcEndPointLpSpec {
+        key 'id';
+        config true;
+        uses G_CeEndPointLpSpec;
+    }
+    list CeEnniOvcEndPointLpSpec {
+        key 'id';
+        config true;
+        uses G_CeEndPointLpSpec;
+    }
+    list CeUniOvcEndPoint {
+        key 'id';
+        config true;
+        uses G_CeEndPointLpSpec;
+    }
+    grouping G_CeUniTerminSpec {
+        uses G_CeTerminSpec;
+    }
+    list CeSpUniTerminSpec {
+        key 'id';
+        config true;
+        uses G_CeUniTerminSpec;
+    }
+    list CeOpUniTerminSpec {
+        key 'id';
+        config true;
+        uses G_CeUniTerminSpec;
+    }
+    grouping G_CeUniConnPtAndAdaptSpec {
+        uses G_CeConnPtAndAdaptSpec;
+    }
+    list CeSpUniConnPtAndAdaptSpec {
+        key 'id';
+        config true;
+        uses G_CeUniConnPtAndAdaptSpec;
+    }
+    list CeOpUniConnPtAndAdaptSpec {
+        key 'id';
+        config true;
+        uses G_CeUniConnPtAndAdaptSpec;
+    }
+    list CeEvcEndPointConnPtAndAdaptSpec {
+        key 'id';
+        config true;
+        uses G_CeEndPointConnPtAndAdaptSpec;
+    }
+    grouping G_CeEndPointConnPtAndAdaptSpec {
+        uses G_CeConnPtAndAdaptSpec;
+    }
+    list CeEnniLpSpec {
+        key 'id';
+        config true;
+        uses G_CeLPSpec;
+    }
+    list CeInniLpSpec {
+        key 'id';
+        config true;
+        uses G_CeLPSpec;
+    }
+    list CeUniOvcEndPointConnPtAndAdaptSpec {
+        key 'id';
+        config true;
+        uses G_CeEndPointConnPtAndAdaptSpec;
+    }
+    list CeEnniOvcEndPointConnPtAndAdaptSpec {
+        key 'id';
+        config true;
+        uses G_CeEndPointConnPtAndAdaptSpec;
+    }
+    grouping G_CeUniLpSpec {
+        uses G_CeLPSpec;
+    }
+    list CeOpUniLpSpec {
+        key 'id';
+        config true;
+        uses G_CeUniLpSpec;
+    }
+    list CeEtyLpSpec {
+        key 'id';
+        config true;
+        uses G_CeLPSpec;
+    }
+    list CeEvcFcPortSetSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_CeEvcFcPortSetSpec;
+    }
+    grouping G_CeEvcFcPortSetSpec {
+        uses G_CeFcPortSetSpec;
+    }
+    list CeFcSpec {
+        key 'uuid';
+        config true;
+        ordered-by system;
+        uses G_CeFcSpec;
+    }
+    grouping G_CeFcSpec {
+        uses CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:G_FcSpec;
+    }
+    list CeFcPortSetSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_CeFcPortSetSpec;
+    }
+    grouping G_CeFcPortSetSpec {
+        uses CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:G_FcPortSetSpec;
+    }
+    list CeEvcFcSpec {
+        key 'uuid';
+        config true;
+        uses G_CeFcSpec;
+    }
+    list CeOvcSpec {
+        key 'uuid';
+        config true;
+        uses G_CeFcSpec;
+    }
+    list CeOvcFcPortSetSpec {
+        key 'id';
+        config true;
+        uses G_CeFcPortSetSpec;
+    }
+    list CeEthFrameAggregateLpSpec {
+        key 'id';
+        config true;
+        uses G_CeLPSpec;
+    }
+    list CeEthFrameFlowLpSpec {
+        key 'id';
+        config true;
+        uses G_CeLPSpec;
+    }
+    list CeEthFrameAggregateTerminSpec {
+        key 'id';
+        config true;
+        uses G_CeTerminSpec;
+    }
+    list CeEthFrameAggregateConnPtAndAdaptSpec {
+        key 'id';
+        config true;
+        uses G_CeConnPtAndAdaptSpec;
+    }
+    list CeEthFrameFlowConnPtAndAdaptLpSpec {
+        key 'id';
+        config true;
+        uses G_CeConnPtAndAdaptSpec;
+    }
+    list CeEthFc {
+        key 'uuid';
+        config true;
+        uses G_CeFcSpec;
+    }
+    list CeEthFcPortSetSpec {
+        key 'id';
+        config true;
+        ordered-by system;
+        uses G_CeEthFcPortSetSpec;
+    }
+    grouping G_CeEthFcPortSetSpec {
+        uses G_CeFcPortSetSpec;
+    }
+}
index 077c90e54ae4b099c1c48f690ae012ad1b5a19ca..514bc404a3d6956980e57142a484c6bf8744a96f 100644 (file)
@@ -34,6 +34,11 @@ and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
         <artifactId>unimgr-impl</artifactId>
         <version>${project.version}</version>
       </dependency>
+      <dependency>
+        <groupId>${project.groupId}</groupId>
+        <artifactId>unimgr-cisco-xr-driver</artifactId>
+        <version>${project.version}</version>
+      </dependency>
       <dependency>
         <groupId>${project.groupId}</groupId>
         <artifactId>unimgr-features</artifactId>
diff --git a/cisco-xr-driver/pom.xml b/cisco-xr-driver/pom.xml
new file mode 100644 (file)
index 0000000..71c3946
--- /dev/null
@@ -0,0 +1,107 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (c) 2015 Cisco Systems, Inc. All rights reserved.
+
+This program and the accompanying materials are made available under the
+terms of the Eclipse Public License v1.0 which accompanies this distribution,
+and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
+    <parent>
+        <groupId>org.opendaylight.controller</groupId>
+        <artifactId>config-parent</artifactId>
+        <version>0.5.0-SNAPSHOT</version>
+        <relativePath/>
+    </parent>
+
+    <properties>
+        <checkstyle.skip>true</checkstyle.skip>
+        <powermock.version>1.6.4</powermock.version>
+    </properties>
+
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.opendaylight.unimgr</groupId>
+    <artifactId>unimgr-cisco-xr-driver</artifactId>
+    <version>0.1.0-SNAPSHOT</version>
+    <packaging>bundle</packaging>
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-compiler-plugin</artifactId>
+                <configuration>
+                    <source>1.8</source>
+                    <target>1.8</target>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+    <dependencies>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>unimgr-impl</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+
+        <!-- Cisco -->
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>cisco-xrmodels</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+
+        <!-- Testing Dependencies -->
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.mockito</groupId>
+            <artifactId>mockito-all</artifactId>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-core</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-module-junit4</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-api-mockito</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-api-support</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-reflect</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.opendaylight.mdsal.model</groupId>
+            <artifactId>ietf-yang-types-20130715</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-core</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-classic</artifactId>
+        </dependency>
+    </dependencies>
+</project>
diff --git a/cisco-xr-driver/src/main/config/default-config.xml b/cisco-xr-driver/src/main/config/default-config.xml
new file mode 100755 (executable)
index 0000000..5a90f2a
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (c) 2015 Cable Television Laboratories, Inc. All rights reserved.
+
+This program and the accompanying materials are made available under the
+terms of the Eclipse Public License v1.0 which accompanies this distribution,
+and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
+-->
+<snapshot>
+  <required-capabilities>
+      <capability>urn:opendaylight:params:xml:ns:yang:unimgr:impl?module=unimgr-impl&amp;revision=2015-10-12</capability>
+      <capability>urn:opendaylight:params:xml:ns:yang:unimgr:cisco-xr-driver:impl?module=unimgr-cisco-xr-driver-impl&amp;revision=2016-05-18</capability>
+      <capability>urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding?module=opendaylight-md-sal-binding&amp;revision=2013-10-28</capability>
+  </required-capabilities>
+  <configuration>
+
+    <data xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
+      <modules xmlns="urn:opendaylight:params:xml:ns:yang:controller:config">
+        <module>
+          <type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:unimgr:cisco-xr-driver:impl">prefix:unimgr-cisco-xr-driver</type>
+          <name>unimgr-cisco-xr-driver-default</name>
+          <broker>
+            <type xmlns:binding="urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding">binding:binding-broker-osgi-registry</type>
+            <name>binding-osgi-broker</name>
+          </broker>
+          <data-broker>
+            <type xmlns:binding="urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding">binding:binding-async-data-broker</type>
+            <name>binding-data-broker</name>
+          </data-broker>
+        </module>
+      </modules>
+    </data>
+  </configuration>
+</snapshot>
diff --git a/cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/CiscoXRDriverProvider.java b/cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/CiscoXRDriverProvider.java
new file mode 100644 (file)
index 0000000..80ad4ef
--- /dev/null
@@ -0,0 +1,44 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.cisco.xr;
+
+import org.mef.nrp.impl.ActivationDriverRepoService;
+import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ProviderContext;
+import org.opendaylight.controller.sal.binding.api.BindingAwareProvider;
+import org.osgi.framework.BundleContext;
+import org.osgi.framework.FrameworkUtil;
+import org.osgi.framework.ServiceReference;
+
+public class CiscoXRDriverProvider implements BindingAwareProvider, AutoCloseable {
+
+    public CiscoXRDriverProvider() {
+    }
+
+    @Override
+    public void onSessionInitiated(ProviderContext session) {
+
+        final BundleContext context = FrameworkUtil.getBundle(this.getClass()).getBundleContext();
+        ServiceReference<ActivationDriverRepoService> serviceRef =
+                context.getServiceReference(ActivationDriverRepoService.class);
+        ActivationDriverRepoService driverRepo = context.getService(serviceRef);
+
+        L2vpnXconnectDriverBuilder l2vpnXconnectDriverBuilder = new L2vpnXconnectDriverBuilder();
+        l2vpnXconnectDriverBuilder.onSessionInitialized(session);
+        driverRepo.bindBuilder(l2vpnXconnectDriverBuilder);
+
+        L2vpnBridgeDriverBuilder l2vpnBridgeDriverBuilder = new L2vpnBridgeDriverBuilder();
+        l2vpnBridgeDriverBuilder.onSessionInitialized(session);
+        driverRepo.bindBuilder(l2vpnBridgeDriverBuilder);
+    }
+
+    @Override
+    public void close() throws Exception {
+        // TODO Auto-generated method stub
+    }
+}
diff --git a/cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnBridgeActivator.java b/cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnBridgeActivator.java
new file mode 100644 (file)
index 0000000..be75a2b
--- /dev/null
@@ -0,0 +1,199 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.cisco.xr;
+
+import java.util.LinkedList;
+import java.util.List;
+
+import org.mef.nrp.impl.MountPointHelper;
+import org.mef.nrp.impl.ResourceActivator;
+import org.opendaylight.controller.md.sal.binding.api.DataBroker;
+import org.opendaylight.controller.md.sal.binding.api.MountPointService;
+import org.opendaylight.controller.md.sal.binding.api.WriteTransaction;
+import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType;
+import org.opendaylight.controller.md.sal.common.api.data.TransactionCommitFailedException;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730.InterfaceActive;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730.InterfaceConfigurations;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730.InterfaceConfigurationsBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730._interface.configurations.InterfaceConfiguration;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730._interface.configurations.InterfaceConfigurationBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730._interface.configurations.InterfaceConfigurationKey;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.InterfaceConfiguration3;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.InterfaceConfiguration3Builder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.L2vpn;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.L2vpnBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109._interface.configurations._interface.configuration.L2Transport;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109._interface.configurations._interface.configuration.L2TransportBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.Database;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.DatabaseBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.XconnectGroups;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.XconnectGroupsBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.XconnectGroup;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.XconnectGroupBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.XconnectGroupKey;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.P2pXconnects;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.P2pXconnectsBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.P2pXconnect;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.P2pXconnectBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.P2pXconnectKey;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.AttachmentCircuitsBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.PseudowiresBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.attachment.circuits.AttachmentCircuit;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.attachment.circuits.AttachmentCircuitBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.pseudowires.Pseudowire;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.xr.types.rev150629.CiscoIosXrString;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.xr.types.rev150629.InterfaceName;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import com.google.common.base.Optional;
+
+public class L2vpnBridgeActivator implements ResourceActivator {
+
+    private static final Logger log = LoggerFactory.getLogger(L2vpnBridgeActivator.class);
+    private MountPointService mountService;
+
+    public L2vpnBridgeActivator(DataBroker dataBroker, MountPointService mountService) {
+        this.mountService = mountService;
+    }
+
+    @Override
+    public void activate(String nodeName, String outerName, String innerName, GFcPort port, GFcPort neighbor, long mtu) {
+
+        String aEndLtpId = port.getLtpRefList().get(0).getValue();
+        String zEndLtpId = neighbor.getLtpRefList().get(0).getValue();
+
+        InterfaceName aEndIfName = new InterfaceName(aEndLtpId.split(":")[1]);
+        InterfaceName zEndIfName = new InterfaceName(zEndLtpId.split(":")[1]);
+        InterfaceName[] both = new InterfaceName[] { aEndIfName, zEndIfName };
+
+        List<InterfaceConfiguration> intConfigs = new LinkedList<>();
+        for (InterfaceName ifName : both) {
+            InterfaceConfigurationBuilder intConfigBuilder = new InterfaceConfigurationBuilder();
+            intConfigBuilder.setInterfaceName(ifName).setActive(new InterfaceActive("act")).setShutdown(Boolean.FALSE);
+
+            L2Transport l2transport = new L2TransportBuilder().setEnabled(true).build();
+            InterfaceConfiguration3 augmentation = new InterfaceConfiguration3Builder().setL2Transport(l2transport)
+                    .build();
+            intConfigBuilder.addAugmentation(InterfaceConfiguration3.class, augmentation);
+
+            intConfigs.add(intConfigBuilder.build());
+        }
+        InterfaceConfigurationsBuilder intConfigsBuilder = new InterfaceConfigurationsBuilder();
+        intConfigsBuilder.setInterfaceConfiguration(intConfigs);
+
+        InstanceIdentifier<InterfaceConfigurations> intConfigsId = InstanceIdentifier
+                .builder(InterfaceConfigurations.class).build();
+
+        AttachmentCircuitBuilder attachmentCircuitBuilderA = new AttachmentCircuitBuilder();
+        attachmentCircuitBuilderA.setName(aEndIfName).setEnable(Boolean.TRUE);
+        AttachmentCircuitBuilder attachmentCircuitBuilderZ = new AttachmentCircuitBuilder();
+        attachmentCircuitBuilderZ.setName(zEndIfName).setEnable(Boolean.TRUE);
+
+        List<AttachmentCircuit> attachmentCircuits = new LinkedList<>();
+        attachmentCircuits.add(attachmentCircuitBuilderA.build());
+        attachmentCircuits.add(attachmentCircuitBuilderZ.build());
+
+        AttachmentCircuitsBuilder attachmentCircuitsBuilder = new AttachmentCircuitsBuilder();
+        attachmentCircuitsBuilder.setAttachmentCircuit(attachmentCircuits);
+
+        List<Pseudowire> pseudowires = new LinkedList<>();
+        PseudowiresBuilder pseudowiresBuilder = new PseudowiresBuilder();
+        pseudowiresBuilder.setPseudowire(pseudowires);
+
+        P2pXconnectBuilder p2pXconnectBuilder = new P2pXconnectBuilder();
+        p2pXconnectBuilder.setName(new CiscoIosXrString(innerName))
+                .setAttachmentCircuits(attachmentCircuitsBuilder.build()).setPseudowires(pseudowiresBuilder.build());
+
+        List<P2pXconnect> p2pXconnects = new LinkedList<>();
+        p2pXconnects.add(p2pXconnectBuilder.build());
+        P2pXconnectsBuilder p2pXconnectsBuilder = new P2pXconnectsBuilder();
+        p2pXconnectsBuilder.setP2pXconnect(p2pXconnects);
+
+        XconnectGroupBuilder xconnectGroupBuilder = new XconnectGroupBuilder();
+        xconnectGroupBuilder.setKey(new XconnectGroupKey(new CiscoIosXrString("local")));
+        xconnectGroupBuilder.setName(new CiscoIosXrString("local")).setP2pXconnects(p2pXconnectsBuilder.build());
+
+        List<XconnectGroup> xconnectGroups = new LinkedList<>();
+        xconnectGroups.add(xconnectGroupBuilder.build());
+        XconnectGroupsBuilder xconnectGroupsBuilder = new XconnectGroupsBuilder();
+        xconnectGroupsBuilder.setXconnectGroup(xconnectGroups);
+
+        DatabaseBuilder dbBuilder = new DatabaseBuilder();
+        dbBuilder.setXconnectGroups(xconnectGroupsBuilder.build());
+
+        L2vpnBuilder l2vpnBuilder = new L2vpnBuilder();
+        l2vpnBuilder.setDatabase(dbBuilder.build());
+
+        InstanceIdentifier<L2vpn> l2vpnId = InstanceIdentifier.builder(L2vpn.class).build();
+
+        Optional<DataBroker> optional = MountPointHelper.getDataBroker(mountService, nodeName);
+        if (optional.isPresent() == false) {
+            log.error("Could not retrieve MountPoint for {}", nodeName);
+            return;
+        }
+        DataBroker nodeDataBroker = optional.get();
+
+        WriteTransaction w = null;
+        try {
+            w = nodeDataBroker.newWriteOnlyTransaction();
+            w.merge(LogicalDatastoreType.CONFIGURATION, intConfigsId, intConfigsBuilder.build());
+            w.merge(LogicalDatastoreType.CONFIGURATION, l2vpnId, l2vpnBuilder.build());
+            try {
+                w.submit().checkedGet();
+                log.info("Service activated: {} {} {}", nodeName, outerName, innerName);
+            } catch (TransactionCommitFailedException e) {
+                log.error("Transaction failed", e);
+            }
+        } catch (Throwable t) {
+            if (w != null)
+                w.cancel();
+            log.error("Failed to create write transaction", t);
+        }
+    }
+
+    @Override
+    public void deactivate(String nodeName, String outerName, String innerName, GFcPort port, GFcPort neighbor,
+            long mtu) {
+        String portLtpId = port.getLtpRefList().get(0).getValue();
+        InterfaceName interfaceName = new InterfaceName(portLtpId.split(":")[1]);
+
+        InterfaceActive intActive = new InterfaceActive("act");
+
+        InstanceIdentifier<P2pXconnect> p2pId = InstanceIdentifier.builder(L2vpn.class).child(Database.class)
+                .child(XconnectGroups.class)
+                .child(XconnectGroup.class, new XconnectGroupKey(new CiscoIosXrString("local")))
+                .child(P2pXconnects.class).child(P2pXconnect.class, new P2pXconnectKey(new CiscoIosXrString(innerName)))
+                .build();
+
+        InstanceIdentifier<InterfaceConfiguration> intConfigId = InstanceIdentifier
+                .builder(InterfaceConfigurations.class)
+                .child(InterfaceConfiguration.class, new InterfaceConfigurationKey(intActive, interfaceName)).build();
+
+        Optional<DataBroker> optional = MountPointHelper.getDataBroker(mountService, nodeName);
+        if (optional.isPresent() == false) {
+            log.error("Could not retrieve MountPoint for {}", nodeName);
+            return;
+        }
+        DataBroker nodeDataBroker = optional.get();
+        WriteTransaction w = nodeDataBroker.newWriteOnlyTransaction();
+        w.delete(LogicalDatastoreType.CONFIGURATION, p2pId);
+        w.delete(LogicalDatastoreType.CONFIGURATION, intConfigId);
+
+        try {
+            w.submit().checkedGet();
+            log.info("Service deactivated: {} {} {}", nodeName, outerName, innerName);
+        } catch (TransactionCommitFailedException e) {
+            log.error("Transaction failed", e);
+        }
+    }
+
+}
diff --git a/cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnBridgeDriverBuilder.java b/cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnBridgeDriverBuilder.java
new file mode 100644 (file)
index 0000000..2e64db4
--- /dev/null
@@ -0,0 +1,99 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.cisco.xr;
+
+import java.util.Optional;
+
+import org.mef.nrp.impl.ActivationDriver;
+import org.mef.nrp.impl.ActivationDriverBuilder;
+import org.opendaylight.controller.md.sal.binding.api.DataBroker;
+import org.opendaylight.controller.md.sal.binding.api.MountPointService;
+import org.opendaylight.controller.sal.binding.api.BindingAwareBroker;
+import org.opendaylight.controller.sal.binding.api.BindingAwareConsumer;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GForwardingConstruct;
+
+/**
+ * Provides drivers for binding two ports on the same node.
+ * @author bartosz.michalik@amartus.com
+ */
+public class L2vpnBridgeDriverBuilder implements ActivationDriverBuilder, BindingAwareConsumer {
+
+    private L2vpnBridgeActivator activator;
+
+    @Override
+    public void onSessionInitialized(BindingAwareBroker.ConsumerContext session) {
+         DataBroker dataBroker = session.getSALService(DataBroker.class);
+         MountPointService mountService = session.getSALService(MountPointService.class);
+         activator = new L2vpnBridgeActivator(dataBroker, mountService);
+    }
+
+    @Override
+    public Optional<ActivationDriver> driverFor(GFcPort port, BuilderContext _ctx) {
+        return Optional.empty();
+    }
+
+    @Override
+    public Optional<ActivationDriver> driverFor(GFcPort aPort, GFcPort zPort, BuilderContext context) {
+        return Optional.of(getDriver());
+    }
+
+    protected ActivationDriver getDriver() {
+        final ActivationDriver driver = new ActivationDriver() {
+            public GForwardingConstruct ctx;
+            public GFcPort aEnd;
+            public GFcPort zEnd;
+
+            @Override
+            public void commit() {
+                //ignore for the moment
+            }
+
+            @Override
+            public void rollback() {
+                //ignore for the moment
+            }
+
+            @Override
+            public void initialize(GFcPort from, GFcPort to, GForwardingConstruct ctx) {
+                this.zEnd = to;
+                this.aEnd = from;
+                this.ctx = ctx;
+            }
+
+            @Override
+            public void activate() {
+                String id = ctx.getUuid();
+                long mtu = 1500;
+                String outerName = "outer";
+                String innerName = "inner";
+
+                String aEndNodeName = aEnd.getLtpRefList().get(0).getValue().split(":")[0];
+                activator.activate(aEndNodeName, outerName, innerName, aEnd, zEnd, mtu);
+            }
+
+            @Override
+            public void deactivate() {
+                String id = ctx.getUuid();
+                long mtu = 1500;
+                String outerName = "outer";
+                String innerName = "inner";
+
+                String aEndNodeName = aEnd.getLtpRefList().get(0).getValue().split(":")[0];
+                activator.deactivate(aEndNodeName, outerName, innerName, aEnd, zEnd, mtu);
+            }
+
+            @Override
+            public int priority() {
+                return 0;
+            }
+        };
+        return driver;
+    }
+}
diff --git a/cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnXconnectActivator.java b/cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnXconnectActivator.java
new file mode 100644 (file)
index 0000000..df61d8f
--- /dev/null
@@ -0,0 +1,251 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.cisco.xr;
+
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Map;
+import java.util.concurrent.atomic.AtomicLong;
+
+import org.mef.nrp.impl.MountPointHelper;
+import org.mef.nrp.impl.ResourceActivator;
+import org.opendaylight.controller.md.sal.binding.api.DataBroker;
+import org.opendaylight.controller.md.sal.binding.api.MountPointService;
+import org.opendaylight.controller.md.sal.binding.api.WriteTransaction;
+import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType;
+import org.opendaylight.controller.md.sal.common.api.data.TransactionCommitFailedException;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730.InterfaceActive;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730.InterfaceConfigurations;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730.InterfaceConfigurationsBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730._interface.configurations.InterfaceConfiguration;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730._interface.configurations.InterfaceConfigurationBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730._interface.configurations.InterfaceConfigurationKey;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730._interface.configurations._interface.configuration.MtusBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730._interface.configurations._interface.configuration.mtus.Mtu;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.ifmgr.cfg.rev150730._interface.configurations._interface.configuration.mtus.MtuBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.InterfaceConfiguration3;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.InterfaceConfiguration3Builder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.L2vpn;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.L2vpnBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.PseudowireIdRange;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.PseudowireLabelRange;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109._interface.configurations._interface.configuration.L2Transport;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109._interface.configurations._interface.configuration.L2TransportBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.Database;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.DatabaseBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.XconnectGroups;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.XconnectGroupsBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.XconnectGroup;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.XconnectGroupBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.XconnectGroupKey;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.P2pXconnects;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.P2pXconnectsBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.P2pXconnect;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.P2pXconnectBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.P2pXconnectKey;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.AttachmentCircuitsBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.PseudowiresBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.attachment.circuits.AttachmentCircuit;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.attachment.circuits.AttachmentCircuitBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.pseudowires.Pseudowire;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.pseudowires.PseudowireBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.pseudowires.pseudowire.Neighbor;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.pseudowires.pseudowire.NeighborBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2vpn.cfg.rev151109.l2vpn.database.xconnect.groups.xconnect.group.p2p.xconnects.p2p.xconnect.pseudowires.pseudowire.pseudowire.content.MplsStaticLabelsBuilder;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.xr.types.rev150629.CiscoIosXrString;
+import org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.xr.types.rev150629.InterfaceName;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4AddressNoZone;
+import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import com.google.common.base.Optional;
+import com.google.common.collect.ImmutableMap;
+
+public class L2vpnXconnectActivator implements ResourceActivator {
+
+    private static final Logger log = LoggerFactory.getLogger(L2vpnXconnectActivator.class);
+    private static final Map<String, String> loopbackMap = ImmutableMap.of("asr-101", "192.168.0.1", "asr-102",
+            "192.168.0.2", "asr-103", "192.168.0.3");
+    private static final AtomicLong pwIdGenerator = new AtomicLong(2000L);
+    private MountPointService mountService;
+
+    public L2vpnXconnectActivator(DataBroker dataBroker, MountPointService mountService) {
+        this.mountService = mountService;
+    }
+
+    @Override
+    public void activate(String nodeName, String outerName, String innerName, GFcPort port, GFcPort neighbor, long mtu) {
+
+        String portLtpId = port.getLtpRefList().get(0).getValue();
+        String neighborLtpId = neighbor.getLtpRefList().get(0).getValue();
+
+        String neighborHostname = neighborLtpId.split(":")[0];
+        InterfaceName interfaceName = new InterfaceName(portLtpId.split(":")[1]);
+
+        // XXX: need to flesh out real method to find neighbor's loopback
+        String neighborLoopback = loopbackMap.get(neighborHostname);
+        if (neighborLoopback == null) {
+            log.warn("No loopback address found for {}", neighborHostname);
+            neighborLoopback = "127.0.0.1";
+        }
+
+        Ipv4AddressNoZone neighborAddress = new Ipv4AddressNoZone(neighborLoopback);
+        InterfaceActive intActive = new InterfaceActive("act");
+
+        // XXX: need to implement real pseudowire-id generator
+        long pwIdVal = pwIdGenerator.getAndIncrement();
+
+        MtuBuilder mtuBuilder = new MtuBuilder();
+        mtuBuilder.setMtu(mtu);
+        mtuBuilder.setOwner(new CiscoIosXrString("GigabitEthernet"));
+
+        List<Mtu> mtus = new LinkedList<>();
+        mtus.add(mtuBuilder.build());
+        MtusBuilder mtusBuilder = new MtusBuilder();
+        mtusBuilder.setMtu(mtus);
+
+        InterfaceConfigurationBuilder intConfigBuilder = new InterfaceConfigurationBuilder();
+        intConfigBuilder.setInterfaceName(interfaceName).setActive(intActive).setMtus(mtusBuilder.build())
+                .setShutdown(Boolean.FALSE);
+
+        L2Transport l2transport = new L2TransportBuilder().setEnabled(true).build();
+        InterfaceConfiguration3 augmentation = new InterfaceConfiguration3Builder().setL2Transport(l2transport).build();
+        intConfigBuilder.addAugmentation(InterfaceConfiguration3.class, augmentation);
+
+        List<InterfaceConfiguration> intConfigs = new LinkedList<>();
+        intConfigs.add(intConfigBuilder.build());
+        InterfaceConfigurationsBuilder intConfigsBuilder = new InterfaceConfigurationsBuilder();
+        intConfigsBuilder.setInterfaceConfiguration(intConfigs);
+
+        InstanceIdentifier<InterfaceConfigurations> intConfigsId = InstanceIdentifier
+                .builder(InterfaceConfigurations.class).build();
+
+        AttachmentCircuitBuilder attachmentCircuitBuilder = new AttachmentCircuitBuilder();
+        attachmentCircuitBuilder.setName(interfaceName).setEnable(Boolean.TRUE);
+
+        List<AttachmentCircuit> attachmentCircuits = new LinkedList<>();
+        attachmentCircuits.add(attachmentCircuitBuilder.build());
+        AttachmentCircuitsBuilder attachmentCircuitsBuilder = new AttachmentCircuitsBuilder();
+        attachmentCircuitsBuilder.setAttachmentCircuit(attachmentCircuits);
+
+        PseudowireLabelRange label = new PseudowireLabelRange(pwIdVal);
+        MplsStaticLabelsBuilder labelBuilder = new MplsStaticLabelsBuilder();
+        labelBuilder.setLocalStaticLabel(label).setRemoteStaticLabel(label);
+
+        NeighborBuilder neighborBuilder = new NeighborBuilder();
+        neighborBuilder.setNeighbor(neighborAddress).setMplsStaticLabels(labelBuilder.build())
+                .setXmlClass(new CiscoIosXrString("static"));
+
+        List<Neighbor> neighbors = new LinkedList<>();
+        neighbors.add(neighborBuilder.build());
+
+        // XXX
+        PseudowireIdRange pwId = new PseudowireIdRange(pwIdVal);
+        PseudowireBuilder pseudowireBuilder = new PseudowireBuilder();
+        pseudowireBuilder.setNeighbor(neighbors).setPseudowireId(pwId);
+
+        List<Pseudowire> pseudowires = new LinkedList<>();
+        pseudowires.add(pseudowireBuilder.build());
+        PseudowiresBuilder pseudowiresBuilder = new PseudowiresBuilder();
+        pseudowiresBuilder.setPseudowire(pseudowires);
+
+        P2pXconnectBuilder p2pXconnectBuilder = new P2pXconnectBuilder();
+        p2pXconnectBuilder.setName(new CiscoIosXrString(innerName))
+                .setAttachmentCircuits(attachmentCircuitsBuilder.build()).setPseudowires(pseudowiresBuilder.build());
+
+        List<P2pXconnect> p2pXconnects = new LinkedList<>();
+        p2pXconnects.add(p2pXconnectBuilder.build());
+        P2pXconnectsBuilder p2pXconnectsBuilder = new P2pXconnectsBuilder();
+        p2pXconnectsBuilder.setP2pXconnect(p2pXconnects);
+
+        XconnectGroupBuilder xconnectGroupBuilder = new XconnectGroupBuilder();
+        xconnectGroupBuilder.setKey(new XconnectGroupKey(new CiscoIosXrString(outerName)));
+        xconnectGroupBuilder.setName(new CiscoIosXrString(outerName)).setP2pXconnects(p2pXconnectsBuilder.build());
+
+        List<XconnectGroup> xconnectGroups = new LinkedList<>();
+        xconnectGroups.add(xconnectGroupBuilder.build());
+        XconnectGroupsBuilder xconnectGroupsBuilder = new XconnectGroupsBuilder();
+        xconnectGroupsBuilder.setXconnectGroup(xconnectGroups);
+
+        DatabaseBuilder dbBuilder = new DatabaseBuilder();
+        dbBuilder.setXconnectGroups(xconnectGroupsBuilder.build());
+
+        L2vpnBuilder l2vpnBuilder = new L2vpnBuilder();
+        l2vpnBuilder.setDatabase(dbBuilder.build());
+
+        InstanceIdentifier<L2vpn> l2vpnId = InstanceIdentifier.builder(L2vpn.class).build();
+
+        Optional<DataBroker> optional = MountPointHelper.getDataBroker(mountService, nodeName);
+        if (optional.isPresent() == false) {
+            log.error("Could not retrieve MountPoint for {}", nodeName);
+            return;
+        }
+        DataBroker nodeDataBroker = optional.get();
+        WriteTransaction w = nodeDataBroker.newWriteOnlyTransaction();
+        w.merge(LogicalDatastoreType.CONFIGURATION, intConfigsId, intConfigsBuilder.build());
+        w.merge(LogicalDatastoreType.CONFIGURATION, l2vpnId, l2vpnBuilder.build());
+
+        try {
+            w.submit().checkedGet();
+            log.info("Service activated: {} {} {}", nodeName, outerName, innerName);
+        } catch (TransactionCommitFailedException e) {
+            log.error("Transaction failed", e);
+        }
+    }
+
+    @Override
+    public void deactivate(String nodeName, String outerName, String innerName, GFcPort port, GFcPort neighbor,
+            long mtu) {
+        String portLtpId = port.getLtpRefList().get(0).getValue();
+        String neighborLtpId = neighbor.getLtpRefList().get(0).getValue();
+
+        String neighborHostname = neighborLtpId.split(":")[0];
+        InterfaceName interfaceName = new InterfaceName(portLtpId.split(":")[1]);
+
+        // XXX: need to flesh out real method to find neighbor's loopback
+        String neighborLoopback = loopbackMap.get(neighborHostname);
+        if (neighborLoopback == null) {
+            log.warn("No loopback address found for {}", neighborHostname);
+            neighborLoopback = "127.0.0.1";
+        }
+
+        Ipv4AddressNoZone neighborAddress = new Ipv4AddressNoZone(neighborLoopback);
+        InterfaceActive intActive = new InterfaceActive("act");
+
+        InstanceIdentifier<P2pXconnect> p2pId = InstanceIdentifier.builder(L2vpn.class).child(Database.class)
+                .child(XconnectGroups.class)
+                .child(XconnectGroup.class, new XconnectGroupKey(new CiscoIosXrString(outerName)))
+                .child(P2pXconnects.class).child(P2pXconnect.class, new P2pXconnectKey(new CiscoIosXrString(innerName)))
+                .build();
+
+        InstanceIdentifier<InterfaceConfiguration> intConfigId = InstanceIdentifier
+                .builder(InterfaceConfigurations.class)
+                .child(InterfaceConfiguration.class, new InterfaceConfigurationKey(intActive, interfaceName)).build();
+
+        Optional<DataBroker> optional = MountPointHelper.getDataBroker(mountService, nodeName);
+        if (optional.isPresent() == false) {
+            log.error("Could not retrieve MountPoint for {}", nodeName);
+            return;
+        }
+        DataBroker nodeDataBroker = optional.get();
+        WriteTransaction w = nodeDataBroker.newWriteOnlyTransaction();
+        w.delete(LogicalDatastoreType.CONFIGURATION, p2pId);
+        w.delete(LogicalDatastoreType.CONFIGURATION, intConfigId);
+
+        try {
+            w.submit().checkedGet();
+            log.info("Service deactivated: {} {} {}", nodeName, outerName, innerName);
+        } catch (TransactionCommitFailedException e) {
+            log.error("Transaction failed", e);
+        }
+    }
+
+}
diff --git a/cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnXconnectDriverBuilder.java b/cisco-xr-driver/src/main/java/org/mef/nrp/cisco/xr/L2vpnXconnectDriverBuilder.java
new file mode 100644 (file)
index 0000000..d5467c1
--- /dev/null
@@ -0,0 +1,109 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.cisco.xr;
+
+import java.util.Optional;
+
+import org.mef.nrp.impl.ActivationDriver;
+import org.mef.nrp.impl.ActivationDriverBuilder;
+import org.mef.nrp.impl.FixedServiceNaming;
+import org.opendaylight.controller.md.sal.binding.api.DataBroker;
+import org.opendaylight.controller.md.sal.binding.api.MountPointService;
+import org.opendaylight.controller.sal.binding.api.BindingAwareBroker;
+import org.opendaylight.controller.sal.binding.api.BindingAwareConsumer;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GForwardingConstruct;
+
+/**
+ * Xconnect builder (FIXME no decision logic yet)
+ * @author bartosz.michalik@amartus.com
+ */
+public class L2vpnXconnectDriverBuilder implements ActivationDriverBuilder, BindingAwareConsumer {
+
+    private final FixedServiceNaming namingProvider;
+    private L2vpnXconnectActivator xconnectActivator;
+    private static DataBroker dataBroker;
+    private static MountPointService mountService;
+
+    @Override
+    public void onSessionInitialized(BindingAwareBroker.ConsumerContext session) {
+         dataBroker = session.getSALService(DataBroker.class);
+         mountService = session.getSALService(MountPointService.class);
+         xconnectActivator = new L2vpnXconnectActivator(dataBroker, mountService);
+    }
+
+    public L2vpnXconnectDriverBuilder() {
+        this.namingProvider = new FixedServiceNaming();
+    }
+
+    @Override
+    public Optional<ActivationDriver> driverFor(GFcPort port,BuilderContext _ctx) {
+        return Optional.of(getDriver());
+    }
+
+    @Override
+    public Optional<ActivationDriver> driverFor(GFcPort aPort, GFcPort zPort, BuilderContext context) {
+        return Optional.empty();
+    }
+
+    protected ActivationDriver getDriver() {
+        final ActivationDriver driver = new ActivationDriver() {
+            public GForwardingConstruct ctx;
+            public GFcPort aEnd;
+            public GFcPort zEnd;
+
+            @Override
+            public void commit() {
+                //ignore for the moment
+            }
+
+            @Override
+            public void rollback() {
+                //ignore for the moment
+            }
+
+            @Override
+            public void initialize(GFcPort from, GFcPort to, GForwardingConstruct ctx) {
+                this.zEnd = to;
+                this.aEnd = from;
+                this.ctx = ctx;
+            }
+
+            @Override
+            public void activate() {
+                String id = ctx.getUuid();
+                long mtu = 1500;
+                String outerName = namingProvider.getOuterName(id);
+                String innerName = namingProvider.getInnerName(id);
+
+                String aEndNodeName = aEnd.getLtpRefList().get(0).getValue().split(":")[0];
+                xconnectActivator.activate(aEndNodeName, outerName, innerName, aEnd, zEnd, mtu);
+
+            }
+
+            @Override
+            public void deactivate() {
+                String id = ctx.getUuid();
+                long mtu = 1500;
+                String outerName = namingProvider.getOuterName(id);
+                String innerName = namingProvider.getInnerName(id);
+
+                String aEndNodeName = aEnd.getLtpRefList().get(0).getValue().split(":")[0];
+                xconnectActivator.deactivate(aEndNodeName, outerName, innerName, aEnd, zEnd, mtu);
+            }
+
+            @Override
+            public int priority() {
+                return 0;
+            }
+        };
+
+        return driver;
+    }
+}
diff --git a/cisco-xr-driver/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/unimgr/cisco/xr/driver/impl/rev160518/UnimgrXRDriverModule.java b/cisco-xr-driver/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/unimgr/cisco/xr/driver/impl/rev160518/UnimgrXRDriverModule.java
new file mode 100644 (file)
index 0000000..0b5375e
--- /dev/null
@@ -0,0 +1,38 @@
+package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.unimgr.cisco.xr.driver.impl.rev160518;
+
+import org.mef.nrp.cisco.xr.CiscoXRDriverProvider;
+import org.opendaylight.controller.sal.binding.api.BindingAwareBroker;
+
+public class UnimgrXRDriverModule extends
+        org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.unimgr.cisco.xr.driver.impl.rev160518.AbstractUnimgrXRDriverModule {
+
+    public UnimgrXRDriverModule(
+            org.opendaylight.controller.config.api.ModuleIdentifier identifier,
+            org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) {
+        super(identifier, dependencyResolver);
+    }
+
+    public UnimgrXRDriverModule(
+            org.opendaylight.controller.config.api.ModuleIdentifier identifier,
+            org.opendaylight.controller.config.api.DependencyResolver dependencyResolver,
+            org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.unimgr.cisco.xr.driver.impl.rev160518.UnimgrXRDriverModule oldModule,
+            java.lang.AutoCloseable oldInstance) {
+        super(identifier, dependencyResolver, oldModule, oldInstance);
+    }
+
+    @Override
+    public void customValidation() {
+        // add custom validation form module attributes here.
+    }
+
+    @Override
+    public java.lang.AutoCloseable createInstance() {
+
+        final CiscoXRDriverProvider provider = new CiscoXRDriverProvider();
+
+        BindingAwareBroker broker = getBrokerDependency();
+        broker.registerProvider(provider);
+
+        return provider;
+    }
+}
diff --git a/cisco-xr-driver/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/unimgr/cisco/xr/driver/impl/rev160518/UnimgrXRDriverModuleFactory.java b/cisco-xr-driver/src/main/java/org/opendaylight/yang/gen/v1/urn/opendaylight/params/xml/ns/yang/unimgr/cisco/xr/driver/impl/rev160518/UnimgrXRDriverModuleFactory.java
new file mode 100644 (file)
index 0000000..1d4d562
--- /dev/null
@@ -0,0 +1,13 @@
+/*
+* Generated file
+*
+* Generated from: yang module name: unimgr-cisco-xr-driver-impl yang module local name: unimgr-cisco-xr-driver
+* Generated by: org.opendaylight.controller.config.yangjmxgenerator.plugin.JMXGenerator
+* Generated at: Wed May 18 16:03:22 BST 2016
+*
+* Do not modify this file unless it is present under src/main directory
+*/
+package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.unimgr.cisco.xr.driver.impl.rev160518;
+public class UnimgrXRDriverModuleFactory extends org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.unimgr.cisco.xr.driver.impl.rev160518.AbstractUnimgrXRDriverModuleFactory {
+
+}
diff --git a/cisco-xr-driver/src/main/yang/unimgr-cisco-xr-driver-impl.yang b/cisco-xr-driver/src/main/yang/unimgr-cisco-xr-driver-impl.yang
new file mode 100755 (executable)
index 0000000..83e15f1
--- /dev/null
@@ -0,0 +1,50 @@
+/*
+ * Copyright (c) 2015 Cable Television Laboratories, Inc. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
+ */
+module unimgr-cisco-xr-driver-impl {
+    yang-version 1;
+    namespace "urn:opendaylight:params:xml:ns:yang:unimgr:cisco-xr-driver:impl";
+    prefix "unimgr-cisco-xr-driver-impl";
+
+    import config { prefix config; revision-date 2013-04-05; }
+    import opendaylight-md-sal-binding { prefix md-sal-binding; revision-date 2013-10-28;}
+
+    description
+        "Service definition for unimgr project";
+
+    revision "2016-05-18" {
+        description
+            "Updated revision.";
+    }
+
+    identity unimgr-cisco-xr-driver {
+        base config:module-type;
+        config:java-name-prefix UnimgrXRDriver;
+    }
+
+    augment "/config:modules/config:module/config:configuration" {
+        case unimgr-cisco-xr-driver {
+            when "/config:modules/config:module/config:type = 'unimgr-cisco-xr-driver'";
+            container broker {
+                uses config:service-ref {
+                    refine type {
+                        mandatory true;
+                        config:required-identity md-sal-binding:binding-broker-osgi-registry;
+                    }
+                }
+            }
+            container data-broker {
+                uses config:service-ref {
+                    refine type {
+                        mandatory false;
+                        config:required-identity md-sal-binding:binding-async-data-broker;
+                    }
+                }
+            }
+        }
+    }
+}
diff --git a/cisco-xrmodels/pom.xml b/cisco-xrmodels/pom.xml
new file mode 100644 (file)
index 0000000..dcc4d73
--- /dev/null
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (c) 2016 Cisco Systems, Inc. All rights reserved.
+
+This program and the accompanying materials are made available under the
+terms of the Eclipse Public License v1.0 which accompanies this distribution,
+and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <parent>
+    <groupId>org.opendaylight.mdsal</groupId>
+    <artifactId>binding-parent</artifactId>
+    <version>0.9.0-SNAPSHOT</version>
+    <relativePath />
+  </parent>
+
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>org.opendaylight.unimgr</groupId>
+  <artifactId>cisco-xrmodels</artifactId>
+  <version>0.1.0-SNAPSHOT</version>
+  <packaging>bundle</packaging>
+
+  <dependencies>
+    <dependency>
+      <groupId>org.opendaylight.mdsal.model</groupId>
+      <artifactId>ietf-inet-types-2013-07-15</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.mdsal.model</groupId>
+      <artifactId>ietf-yang-types-20130715</artifactId>
+    </dependency>
+  </dependencies>
+
+</project>
diff --git a/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/asr9k/policymgr/cfg/rev150518/IdleTimeoutBuilder.java b/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/asr9k/policymgr/cfg/rev150518/IdleTimeoutBuilder.java
new file mode 100644 (file)
index 0000000..6603963
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.asr9k.policymgr.cfg.rev150518;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class IdleTimeoutBuilder {
+
+    public static IdleTimeout getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/asr9k/policymgr/cfg/rev150518/PrecedenceBuilder.java b/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/asr9k/policymgr/cfg/rev150518/PrecedenceBuilder.java
new file mode 100644 (file)
index 0000000..d43389e
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.asr9k.policymgr.cfg.rev150518;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class PrecedenceBuilder {
+
+    public static Precedence getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrAnyBuilder.java b/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrAnyBuilder.java
new file mode 100644 (file)
index 0000000..83d4a4f
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2.eth.infra.datatypes.rev151109;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class VlanTagOrAnyBuilder {
+
+    public static VlanTagOrAny getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrCvpBuilder.java b/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrCvpBuilder.java
new file mode 100644 (file)
index 0000000..5aa9521
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2.eth.infra.datatypes.rev151109;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class VlanTagOrCvpBuilder {
+
+    public static VlanTagOrCvp getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrNativeBuilder.java b/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrNativeBuilder.java
new file mode 100644 (file)
index 0000000..38dd7d1
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2.eth.infra.datatypes.rev151109;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class VlanTagOrNativeBuilder {
+
+    public static VlanTagOrNative getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrNullBuilder.java b/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/l2/eth/infra/datatypes/rev151109/VlanTagOrNullBuilder.java
new file mode 100644 (file)
index 0000000..b2253ce
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.l2.eth.infra.datatypes.rev151109;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class VlanTagOrNullBuilder {
+
+    public static VlanTagOrNull getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/snmp/agent/cfg/rev151027/SnmpDscpValueBuilder.java b/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/snmp/agent/cfg/rev151027/SnmpDscpValueBuilder.java
new file mode 100644 (file)
index 0000000..3225be1
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.snmp.agent.cfg.rev151027;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class SnmpDscpValueBuilder {
+
+    public static SnmpDscpValue getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/snmp/agent/cfg/rev151027/SnmpPrecedenceValue1Builder.java b/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/ios/xr/snmp/agent/cfg/rev151027/SnmpPrecedenceValue1Builder.java
new file mode 100644 (file)
index 0000000..a45e260
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.ios.xr.snmp.agent.cfg.rev151027;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class SnmpPrecedenceValue1Builder {
+
+    public static SnmpPrecedenceValue1 getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/xr/types/rev150629/CharNumBuilder.java b/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/xr/types/rev150629/CharNumBuilder.java
new file mode 100644 (file)
index 0000000..e0ce56d
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.xr.types.rev150629;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class CharNumBuilder {
+
+    public static CharNum getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/xr/types/rev150629/TtyEscapeCharNumBuilder.java b/cisco-xrmodels/src/main/java/org/opendaylight/yang/gen/v1/http/cisco/com/ns/yang/cisco/xr/types/rev150629/TtyEscapeCharNumBuilder.java
new file mode 100644 (file)
index 0000000..f5a5e9f
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.http.cisco.com.ns.yang.cisco.xr.types.rev150629;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class TtyEscapeCharNumBuilder {
+
+    public static TtyEscapeCharNum getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-asr9k-policymgr-cfg@2015-05-18.yang b/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-asr9k-policymgr-cfg@2015-05-18.yang
new file mode 100644 (file)
index 0000000..3401aec
--- /dev/null
@@ -0,0 +1,1633 @@
+module Cisco-IOS-XR-asr9k-policymgr-cfg {
+
+  namespace 
+    "http://cisco.com/ns/yang/Cisco-IOS-XR-asr9k-policymgr-cfg";
+  
+  prefix "asr9k-policymgr-cfg";
+    
+  import ietf-inet-types { 
+    prefix inet;
+  }
+    
+  import ietf-yang-types { 
+    prefix yang;
+  }
+    
+  organization "Cisco Systems, Inc.";
+
+  contact
+    "Cisco Systems, Inc.
+     Customer Service
+
+     Postal: 170 West Tasman Drive
+     San Jose, CA 95134
+
+     Tel: +1 800 553-NETS
+
+     E-mail: cs-yang@cisco.com";
+
+  description 
+    "This module contains a collection of YANG definitions
+     for Cisco IOS-XR ASR9k policy manager configuration.
+
+     Copyright (c) 2013, 2015 by Cisco Systems, Inc.
+     All rights reserved.";
+
+  revision "2015-05-18" {
+    description
+      "IOS XR 5.3.2 revision.";
+  }
+
+  revision "2013-07-22" {
+    description
+      "Initial revision.";
+  }
+
+  typedef Class-map-type {
+    type enumeration {
+      enum qos {
+        value 1;
+        description "QoS Classmap.";
+      }
+      enum traffic {
+        value 3;
+        description "TRAFFIC Classmap.";
+      }
+      enum control {
+        value 4;
+        description "Control Subscriber Classmap.";
+      }
+    }
+    description "Policy manager class-map type.";
+  }
+
+  typedef Alarm-severity {
+    type string {
+      pattern "(informational)|(notification)|(warning)|(error)|"+
+              "(critical)|(alert)|(emergency)";
+    }
+    description "Alaram severity types.";
+  }
+
+  typedef Policy-map-type {
+    type enumeration {
+      enum qos {
+        value 1;
+        description "QoS Policymap";
+      }
+      enum pbr {
+        value 2;
+        description "PBR Policymap";
+      }
+      enum traffic {
+        value 3;
+        description "TRAFFIC Policymap";
+      }
+      enum subscriber-control {
+        value 4;
+        description "SUBSCRIBER-CONTROL Policymap";
+      }
+      enum redirect {
+        value 6;
+        description "REDIRECT Policy map";
+      }
+      enum flow-monitor {
+        value 7;
+        description "FLOWMONITOR Policy map";
+      }
+    }
+    description "Policy manager policy-map type.";
+  }
+
+  typedef Service-policy-type {
+    type string {
+      pattern "(PBR)|(QOS)|(REDIRECT)|(TRAFFIC)
+               |(pbr)|(qos)|(redirect)|(traffic)";
+    }
+    description "Policy manager service-policy type.";
+  }
+
+  typedef Pmap-class-map-type {
+    type enumeration {
+      enum qos {
+        value 1;
+        description "QoS Classmap.";
+      }
+      enum traffic {
+        value 2;
+        description "TRAFFIC Classmap.";
+      }
+      enum subscriber-control {
+        value 3;
+        description "Subscriber Control Classmap.";
+      }
+    }
+    description "Policy manager class-map type.";
+  }
+
+  typedef Bandwidth-units {
+    type string {
+      pattern "(bps)|(kbps)|(mbps)|(gbps)|(percent)|(per-million)|"+
+              "(per-thousand)";
+    }
+    description "Supported units for bandwidth.
+                 bps          - units in Bits/Sec
+                 kbps         - units in KiloBits/Sec
+                 mbps         - units in MegaBits/Sec
+                 gbps         - units in GigaBits/Sec
+                 percent      - units in Percentage
+                 per-million  - parts per-million bandwidth value
+                 per-thousand - Parts per-thousand bandwidth value";
+  }
+
+  typedef Bandwidth-remaining-units {
+    type string {
+      pattern "(percent)|(ratio)";
+    }
+    description "Supported units for bandwidth remaining.
+                 percent      - units in Percentage
+                 ratio        - units in Ratio";
+  }
+
+  typedef Rate-units {
+    type string {
+      pattern "(bps)|(kbps)|(mbps)|(gbps)|(pps)|(percent)";
+    }
+    description "Supported units for police rate or peak-rate.
+                 bps     - units in Bits/Sec
+                 kbps    - units in KiloBits/Sec
+                 mbps    - units in MegaBits/Sec
+                 gbps    - units in GigaBits/Sec
+                 pps     - units in Packets/Sec
+                 percent - units in Percentage";
+  }
+
+  typedef Cac-rate-units {
+    type string {
+      pattern "(bps)|(kbps)|(mbps)|(gbps)|(cellsps)";
+    }
+    description "Supported units for CAC rate or flow-rate.
+                 bps     - units in Bits/Sec
+                 kbps    - units in KiloBits/Sec
+                 mbps    - units in MegaBits/Sec
+                 gbps    - units in GigaBits/Sec
+                 cellsps - units in Cells/Sec";
+  }
+
+  typedef Queue-units {
+    type string {
+      pattern "(bytes)|(kbytes)|(mbytes)|(gbytes)|(us)|(ms)|"+
+              "(packets)|(cells)";
+    }
+    description "Supported units for queue.
+                 bytes   - units in Bytes
+                 kbytes  - units in KiloBytes
+                 mbytes  - units in MegaBytes
+                 gbytes  - units in Gigabytes
+                 us      - units in Microseconds
+                 ms      - units in Milliseconds
+                 packets - units in Packets
+                 cells   - units in Cells";
+  }
+  
+  typedef Threshold-units {
+    type string {
+      pattern "(bytes)|(kbytes)|(mbytes)|(gbytes)|(us)|(ms)|"+
+              "(packets)|(cells)";
+    }
+    description "Supported units for RED threshold.
+                 bytes   - units in Bytes
+                 kbytes  - units in KiloBytes
+                 mbytes  - units in MegaBytes
+                 gbytes  - units in GigaBytes
+                 us      - units in Microseconds
+                 ms      - units in Milliseconds
+                 packets - units in Packets
+                 cells   - units in Cells";
+  }
+
+  typedef Float-str {
+    type string {
+      pattern "[0-9]+(\.[0-9]+)?";
+    }
+    description "Floating point number string representation.";
+  }
+  
+  typedef Dscp {
+    type string {
+      pattern "([0-9]|[1-5][0-9]|6[0-3])|"+
+              "(af11)|(af12)|(af13)|(af21)|(af22)|(af23)|(af31)|"+
+              "(af32)|(af33)|(af41)|(af42)|(af43)|(ef)|(default)|"+
+              "(cs1)|(cs2)|(cs3)|(cs4)|(cs5)|(cs6)|(cs7)";
+    }
+    description "DSCP value string representation.
+                 Should be single value 0..63 or predefined string.";
+  }
+
+  typedef Dscp-range {
+    type string {
+      pattern "([0-9]|[1-5][0-9]|6[0-3])|"+
+              "(([0-9]|[1-5][0-9]|6[0-3])-"+
+              "([0-9]|[1-5][0-9]|6[0-3]))|"+
+              "(af11)|(af12)|(af13)|(af21)|(af22)|(af23)|(af31)|"+
+              "(af32)|(af33)|(af41)|(af42)|(af43)|(ef)|(default)|"+
+              "(cs1)|(cs2)|(cs3)|(cs4)|(cs5)|(cs6)|(cs7)";
+    }
+    description "DSCP value or range string representation.
+                 Should be single value 0..63 or predefined string 
+                 or range <min>-<max>.";
+  }
+  
+  typedef Num-range {
+    type string {
+      pattern "(\d+)|(\d+\-\d+)";
+    }
+    description "Numeric value or range string representation.
+                 Should be single value or range <min>-<max>.";
+  }
+  
+  typedef Protocol {
+    type string {
+      pattern 
+        "([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])|"+
+        "(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\-"+
+        "([1-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5]))|"+
+        "((ahp)|(dhcpv4)|(dhcpv6)|(eigrp)|(esp)|(gre)|(icmp)|"+
+        "(igmp)|(igrp)|(ipinip)|(ipv4)|(ipv6)|(ipv6icmp)|(mpls)|"+
+        "(nos)|(ospf)|(pcp)|(pim)|(ppp)|(sctp)|(tcp)|(udp))";
+    }
+    description "Numeric value or range or string representation.
+                 Should be single value or range 0..255.";
+  }
+  
+  typedef Ethertype {
+    type string {
+      pattern 
+        "((153[6-9]|15[4-9][0-9]|1[6-9][0-9][0-9]|[2-9][0-9][0-9][0-9])|"+
+        "([1-5][0-9][0-9][0-9][0-9]|6[0-4][0-9][0-9][0-9])|"+
+        "(65[0-4][0-9][0-9]|655[0-2][0-9]|6553[0-5]))|"+
+        "((arp)|(ipv4)|(ipv6))";
+    }
+    description "Numeric value or string representation.
+                 Should be single value 1536..65535 or predefined string.";
+  }
+
+  typedef Precedence {
+    type union {
+      type uint8 {
+        range "0..7";
+      }
+      type string {
+        pattern "(critical)|(flash)|(flash-override)|(immediate)|"+
+                "(internet)|(network)|(priority)|(routine)";
+      }
+    }
+    description "Precedence value.
+                 critical        Critical precedence (5)
+                 flash           Flash precedence (3)
+                 flash-override  Flash override precedence (4)
+                 immediate       Immediate precedence (2)
+                 internet        Internetwork control precedence (6)
+                 network         Network control precedence (7)
+                 priority        Priority precedence (1)
+                 routine         Routine precedence (0)";
+  }
+  
+  typedef Cos {
+    type uint8 {
+      range "0..7";
+    }
+    description "Cos value.";
+  }
+
+  typedef Idle-timeout-number {
+    type uint16 {
+      range "10..2550";
+    }
+    units "seconds";
+    description "String that idle-timeout can take.";
+  }
+  
+  typedef Idle-timeout-string {
+    type string {
+      pattern "(None)|(none)";
+    }
+    description "This flow does not expire.";
+  }
+  
+  typedef Idle-timeout {
+    type union {
+      type Idle-timeout-number;
+      type Idle-timeout-string;
+    }
+    description "Idle timeout.";
+  }
+  
+  typedef Event-type {
+    type enumeration {
+      enum account-logoff {
+        description "Account logoff event.";
+      }
+      enum account-logon {
+        description "Account logon event.";
+      }
+      enum authentication-failure {
+        description "Authentication failure event.";
+      }
+      enum authentication-no-response {
+        description "Authentication no response event.";
+      }
+      enum authorization-failure {
+        description "Authorization failure event.";
+      }
+      enum authorization-no-response {
+        description "Authorization no response event.";
+      }
+      enum credit-exhausted {
+        description "Credit exhaustion event.";
+      }
+      enum exception {
+        description "Exception event.";
+      }
+      enum idle-timeout {
+        description "Idle timeout event.";
+      }
+      enum quota-depleted {
+        description "Quota depletion event.";
+      }
+      enum service-start {
+        description "Service start event.";
+      }
+      enum service-stop {
+        description "Service stop event.";
+      }
+      enum session-activate {
+        description "Session activate event.";
+      }
+      enum session-start {
+        description "Session start event.";
+      }
+      enum session-stop {
+        description "Session stop event.";
+      }
+      enum timer-expiry {
+        description "Timer expiry event.";
+      }
+    }
+    description "Event type.";
+  }
+  
+  typedef Execution-strategy {
+    type enumeration {
+      enum do-all {
+        description "Do all actions.";
+      }
+      enum do-until-failure {
+        description "Do all actions until failure.";
+      }
+      enum do-until-success {
+        description "Do all actions until success.";
+      }
+    }
+    description "Executuion strategy.";
+  }
+  
+  typedef Authorize-identifier {
+    type enumeration {
+      enum circuit-id {
+        description "Authorize circuit ID.";
+      }
+      enum remote-id {
+        description "Authorize remote ID.";
+      }
+      enum source-address-ipv4 {
+        description "Authorize source IPv4 address.";
+      }
+      enum source-address-ipv6 {
+        description "Authorize source IPv6 address.";
+      }
+      enum source-address-mac {
+        description "Authorize source MAC address.";
+      }
+      enum username {
+        description "Authorize username.";
+      }
+    }
+    description "Authorize identifier.";
+  }
+  
+  grouping MATCH {
+    description "Supported 'match' or 'match-not' actions.";
+    leaf-list ipv4-dscp {
+      type Dscp-range;
+      max-elements 8;
+      description "Match IPv4 DSCP.";
+    }
+    leaf-list ipv6-dscp {
+      type Dscp-range;
+      max-elements 8;
+      description "Match IPv6 DSCP.";
+    }
+    leaf-list dscp {
+      type Dscp-range;
+      max-elements 8;
+      description "Match DSCP.";
+    }
+    leaf-list ipv4-precedence {
+      type Precedence;
+      max-elements 8;
+      description "Match IPv4 precedence.";
+    }
+    leaf-list ipv6-precedence {
+      type Precedence;
+      max-elements 8;
+      description "Match IPv6 precedence.";
+    }
+    leaf-list precedence {
+      type Precedence;
+      max-elements 8;
+      description "Match precedence.";
+    }
+    leaf-list qos-group {
+      type Num-range;
+      max-elements 8;
+      description "Match QoS group.
+                   Should be value 0..512 or range.";
+    }
+    leaf-list cos {
+      type Cos;
+      max-elements 8;
+      description "Match CoS.";
+    }
+    leaf-list inner-cos {
+      type Cos;
+      max-elements 8;
+      description "Match inner CoS.";
+    }
+    leaf-list protocol {
+      type Protocol;
+      max-elements 7;
+      description "Match protocol.";
+    }
+    leaf ipv4-acl {
+      type string {
+        length "1..64";
+      }
+      description "Match IPv4 ACL.";
+    }
+    leaf ipv6-acl {
+      type string {
+        length "1..64";
+      }
+      description "Match IPv6 ACL.";
+    }
+    leaf-list mpls-experimental-topmost {
+      type Cos;
+      max-elements 8;
+      description "Match MPLS experimental topmost label.";
+    }
+    leaf-list mpls-experimental-imposition {
+      type Cos;
+      max-elements 8;
+      description "Match MPLS experimental imposition label.";
+    }
+    leaf-list discard-class {
+      type Cos;
+      max-elements 8;
+      description "Match discard class.";
+    }
+    leaf-list ipv4-packet-length {
+      type Num-range;
+      max-elements 8;
+      description "Match IPv4 packet length.
+                   Should be value 0..65535 or range.";
+    }
+    leaf-list ipv6-packet-length {
+      type Num-range;
+      max-elements 8;
+      description "Match IPv6 packet length. 
+                   Should be value 0..65535 or range.";
+    }
+    leaf-list packet-length {
+      type Num-range;
+      max-elements 8;
+      description "Match packet length. 
+                   Should be value 0..65535 or range.";
+    }
+    leaf mpls-disposition-ipv4-access-list {
+      type string {
+        length "1..32";
+      }
+      description "Match MPLS Label Disposition IPv4 access list.";
+    }
+    leaf mpls-disposition-ipv6-access-list {
+      type string {
+        length "1..32";
+      }
+      description "Match MPLS Label Disposition IPv6 access list.";
+    }
+    leaf-list vlan {
+      type Num-range;
+      max-elements 8;
+      description "Match VLAN ID.";
+    }
+    leaf-list inner-vlan {
+      type Num-range;
+      max-elements 8;
+      description "Match inner VLAN ID.";
+    }
+    leaf-list flow-tag {
+      type Num-range;
+      max-elements 8;
+      description "Match flow-tag. Should be value 1..63 or range.";
+    }
+    leaf-list ethertype {
+      type Ethertype;
+      max-elements 8;
+      description "Match Ethertype.";
+    }
+    list destination-address-ipv4 {
+      key "address netmask";
+      max-elements 8;
+      description "Match destination IPv4 address.";
+      leaf address {
+        type inet:ipv4-address-no-zone;
+        description "IPv4 address.";
+      }
+      leaf netmask {
+        type inet:ipv4-address-no-zone;
+        description "IPv4 netmask.";
+      }
+    }
+    list destination-address-ipv6 {
+      key "address prefix-length";
+      max-elements 8;
+      description "Match destination IPv6 address.";
+      leaf address {
+        type inet:ipv6-address-no-zone;
+        description "IPv6 address.";
+      }
+      leaf prefix-length {
+        type uint8 {
+          range "0..128";
+        }
+        description "IPv6 prefix length.";
+      }
+    }
+    leaf-list destination-port {
+      type Num-range;
+      max-elements 8;
+      description "Match destination port. 
+                   Should be value 0..65535 or range.";
+    }
+    leaf-list fragment-type {
+      type string {
+        pattern "(first-fragment)|(is-fragment)|(last-fragment)";
+      }
+      max-elements 3;
+      description "Match fragment type for a packet.";
+    }
+    leaf-list frame-relay-dlci {
+      type Num-range;
+      max-elements 8;
+      description "Match frame-relay DLCI value. 
+                   Should be value 16..1007 or range.";
+    }
+    leaf fr-de {
+        type uint8 {
+          range "0..1";
+        }
+        description "Set FrameRelay DE bit.";
+    }
+    leaf-list icmpv4-code {
+      type Num-range;
+      max-elements 8;
+      description "Match IPv4 ICMP code. 
+                   Should be value 0..255 or range.";
+    }
+    leaf-list icmpv4-type {
+      type Num-range;
+      max-elements 8;
+      description "Match IPv4 ICMP type. 
+                   Should be value 0..255 or range.";
+    }
+    leaf-list icmpv6-code {
+      type Num-range;
+      max-elements 8;
+      description "Match IPv6 ICMP code. 
+                   Should be value 0..255 or range.";
+    }
+    leaf-list icmpv6-type {
+      type Num-range;
+      max-elements 8;
+      description "Match IPv6 ICMP type. 
+                   Should be value 0..255 or range.";
+    }
+    list source-address-ipv4 {
+      key "address netmask";
+      max-elements 8;
+      description "Match source IPv4 address.";
+      leaf address {
+        type inet:ipv4-address-no-zone;
+        description "IPv4 address.";
+      }
+      leaf netmask {
+        type inet:ipv4-address-no-zone;
+        description "IPv4 netmask.";
+      }
+    }
+    list source-address-ipv6 {
+      key "address prefix-length";
+      max-elements 8;
+      description "Match source IPv6 address.";
+      leaf address {
+        type inet:ipv6-address-no-zone;
+        description "IPv6 address.";
+      }
+      leaf prefix-length {
+        type uint8 {
+          range "0..128";
+        }
+        description "IPv6 prefix length.";
+      }
+    }
+    leaf-list source-port {
+      type Num-range;
+      max-elements 8;
+      description "Match source port. 
+                   Should be value 0..65535 or range.";
+    }
+    leaf tcp-flag {
+      type uint16 {
+        range "1..4095";
+      }
+      description "Match TCP flag.";
+    }
+    leaf authen-status {
+      type string {
+        pattern "(authenticated)|(unauthenticated)";
+      }
+      description "Match authentication status.";
+    }
+    list domain-name {
+      key "name format";
+      max-elements 8;
+      description "Match domain name.";
+      leaf name {
+        type string {
+          length "1..32";
+        }
+        description "Domain name or regular expression.";
+      }
+      leaf format {
+        type string {
+          length "1..32";
+        }
+        description "Domain-format name.";
+      }
+    }
+    leaf-list service-name {
+      type string {
+        length "1..32";
+      }
+      max-elements 8;
+      description "Match servicve name.";
+    }
+    leaf-list service-name-regex {
+      type string {
+        length "1..32";
+      }
+      max-elements 8;
+      description "Match servicve name regular expression.";
+    }
+    leaf-list timer {
+      type string {
+        length "1..32";
+      }
+      max-elements 8;
+      description "Match timer.";
+    }
+    leaf-list timer-regex {
+      type string {
+        length "1..32";
+      }
+      max-elements 8;
+      description "Match timer regular expression.";
+    }
+    leaf-list user-name {
+      type string {
+        length "1..32";
+      }
+      max-elements 8;
+      description "Match user name.";
+    }
+    leaf-list user-name-regex {
+      type string {
+        length "1..32";
+      }
+      max-elements 8;
+      description "Match user name regular expression.";
+    }
+  }
+  
+  grouping MATCH-MATCHNOT {
+    description "match or match-not containers.";
+    container match {
+      description "Match rules.";
+      uses MATCH;
+      leaf source-mac {
+        type yang:mac-address;
+        description "Match source MAC address.";
+      }
+      leaf destination-mac {
+        type yang:mac-address;
+        description "Match destination MAC address.";
+      }
+      leaf atm-clp {
+        type uint8 {
+          range "0..1";
+        }
+       description "Match ATM CLP bit.";
+      }
+      leaf atm-oam {
+        type empty;
+        description "Match ATM OAM.";
+      }
+      leaf cac-admit {
+        type empty;
+        description "Match CAC admitted.";
+      }
+      leaf cac-unadmit {
+        type empty;
+        description "Match CAC unadmitted.";
+      }
+      container flow {
+        description "Match flow.";
+        leaf-list flow-key {
+          type string {
+            pattern "(SourceIP)|(DestinationIP)|(5Tuple)";
+          }
+          max-elements 2;
+          description "Configure the flow-key parameters.";
+        }
+        container flow-cache {
+          description "Configure the flow-cache parameters";
+          leaf idle-timeout {
+            type Idle-timeout;
+            description "Maximum time of inactivity for a flow.";
+          }
+        }
+      }
+    }
+    container match-not {
+      description "Match not rules.";
+      uses MATCH;
+    }  
+  }
+  grouping CLASS-MAP-RULE {
+    description "Class-map rule";
+    leaf class-map-mode-match-any {
+      when "count(../class-map-mode-match-all) = 0" {
+          description "Class MUST have only one mode.";
+      }
+      type empty;
+      description "Match all match criteria";
+    }
+    leaf class-map-mode-match-all {
+      when "count(../class-map-mode-match-any) = 0" {
+          description "Class MUST have only one mode.";
+      }
+      type empty;
+      description "Match any match criteria.";
+    }
+    uses MATCH-MATCHNOT;
+    leaf description {
+      type string;
+      description "Description for this policy-map.";
+    }
+  }
+  
+  grouping POLICY-MARK {
+    description "Policy packet marking actions.";
+    leaf dscp {
+      type Dscp;
+      description 
+        "Marks a packet by setting the DSCP in the ToS byte.";
+    }
+    leaf qos-group {
+      type uint16 {
+        range "0..512";
+      }
+      description
+        "Sets the QoS group identifiers on IPv4 or MPLS packets.
+         The set qos-group is supported only on an ingress policy.";
+    }
+    leaf discard-class {
+      type uint8 {
+        range "0..7";
+      }
+      description
+        "Sets the discard class on IPv4 or MPLS packets.
+         The discard-class can be used only in service policies 
+         that are attached in the ingress policy.";
+    }
+    leaf forward-class {
+      type uint8 {
+        range "0..7";
+      }
+      description 
+        "Sets the discard class.";
+    }
+    leaf df {
+      type uint8 {
+        range "0..1";
+      }
+      description "Set DF bit.";
+    }
+    leaf cos {
+      type uint8 {
+        range "0..7";
+      }
+      description 
+        "Sets the specific IEEE 802.1Q Layer 2 CoS value of an
+         outgoing packet.
+         This command should be used by a router if a user wants
+         to mark a packet that is being sent to a switch. 
+         Switches can leverage Layer 2 header information, 
+         including a CoS value marking. Packets entering an 
+         interface cannot be set with a CoS value.";
+    }
+    leaf inner-cos {
+      type uint8 {
+        range "0..7";
+      }
+      description "Set inner cos.";
+    }
+    leaf precedence {
+      type Precedence;
+      description "Sets the precedence value in the IP header.";
+    }
+    leaf precedence-tunnel {
+      type Precedence;
+      description "Sets the precedence tunnel value for ipsec.";
+    }
+    leaf mpls-experimental-top-most {
+      type uint8 {
+        range "0..7";
+      }
+      description 
+        "Sets the experimental value of the MPLS packet top-most
+         labels.";
+    }
+    leaf mpls-experimental-imposition {
+      type uint8 {
+         range "0..7";
+      }
+      description
+        "Sets the experimental value of the MPLS packet 
+         imposition labels.
+         Imposition can be used only in service policies that 
+         are attached in the ingress policy";
+    }
+    leaf srp-priority {
+      type uint8 {
+        range "0..7";
+      }
+      description 
+        "Sets the spatial reuse protocol priority value of an 
+         outgoing packet.";
+    }
+    leaf fr-de {
+        type uint8 {
+          range "0..1";
+        }
+        description "Set FrameRelay DE bit.";
+    }
+  }
+  
+  grouping CAC-RATE-VALUE {
+    description "CAC rate value.";
+    leaf value {
+      type uint32 {
+        range "1..4294967295";
+      }
+      must "../units" {
+        description "units must be set.";
+      }
+      description "Rate value.";
+    }
+    leaf units {
+      type Cac-rate-units;
+      description "Rate units.";
+    }
+  }
+  
+  grouping POLICE-ACTION {
+    description "Police action.";
+    leaf Transmit {
+      type empty;
+      description "Police action transmit.";
+    }
+    leaf drop {
+      type empty;
+      description "Police action drop.";
+    }
+    container set {
+      description "Police action packet marking.";
+      uses POLICY-MARK;
+    }
+  }
+  
+  grouping POLICY-MAP-RULE {
+    description "Class-map rule.";
+    list event {
+      key "event-type";
+      description "Policy event.";
+      leaf event-type {
+        type Event-type;
+        description "Event type.";
+      }
+      leaf event-mode-match-all {
+        when "count(../event-modematch-first) = 0" {
+          description "Event MUST have only one mode.";
+        }
+        type empty;
+        description "Execute all the matched classes.";
+      }
+      leaf event-modematch-first {
+        when "count(../event-modematch-all) = 0" {
+          description "Event MUST have only one mode.";
+        }
+        type empty;
+        description "Execute only the first matched class.";
+      }
+      list class {
+        key "class-name class-type";
+        description "Class-map rule.";
+        leaf class-name {
+          type string {
+            pattern "[a-zA-Z0-9][a-zA-Z0-9\._@$%+#:=<>\-]{0,62}";
+          }
+          description "Name of class.";
+        }
+        leaf class-type {
+          type Pmap-class-map-type;
+          description "Type of class.";
+        }
+        leaf class-execution-strategy {
+          type Execution-strategy;
+          description "Class execution strategy.";
+        }
+        list action-rule {
+          key "action-sequence-number";
+          description "Action rule.";
+          leaf action-sequence-number {
+            type uint16 {
+              range "1..65535";
+            }
+            description "Sequence number for this action.";
+          }
+          container activate-dynamic-template {
+            presence "This container is present only if actions is
+                      related to dynamic templates.";
+            description "Activate dynamic templates.";
+            leaf name {
+              type string;
+              mandatory true;
+              description "Dynamic template name.";
+            }
+            leaf aaa-list {
+              type string;
+              description "Name of the AAA method list.";
+            }
+          }
+          container authenticate {
+            description "Authentication related configuration.";
+            leaf aaa-list {
+              type string;
+              description "Name of the AAA method list.";
+            }
+          }
+          container authorize {
+            must "format or identifier" {
+              description "format or identifier must be set.";
+            }
+            presence "This container is present only if actions is
+                      related to authorization.";
+            description "Authorize.";
+            leaf aaa-list {
+              type string;
+              mandatory true;
+              description "Name of the AAA method list.";
+            }
+            leaf format {
+              type string;
+              description "Specify an Authorize format name.";
+            }
+            leaf identifier {
+              type Authorize-identifier;
+              description "Specify an Authorize format name.";
+            }
+            leaf password {
+              type string;
+              mandatory true;
+              description "Specify a password to be used for AAA
+                           request.";
+            }
+          }
+          container deactivate-dynamic-template {
+            presence "This container is present only if actions is
+                      related to dynamic templates.";
+            description "Deactivate dynamic templates.";
+            leaf name {
+              type string;
+              mandatory true;
+              description "Dynamic template name.";
+            }
+            leaf aaa-list {
+              type string;
+              description "Name of the AAA method list.";
+            }
+          }
+          leaf disconnect {
+            type empty;
+            description "Disconnect session.";
+          }
+          leaf monitor {
+            type empty;
+            description "Monitor session.";
+          }
+          container set-timer {
+            presence "This container is present only if actions is
+                      related to timer.";
+            description "Set a timer to execute a rule on its 
+                         expiry";
+            leaf timer-name {
+              type string;
+              mandatory true;
+              description "Name of the timer.";
+            }
+            leaf timer-value {
+              type uint32;
+              units "minutes";
+              mandatory true;
+              description "Timer value in minutes.";
+            }
+          }
+          container stop-timer {
+            description "Disable timer before it expires.";
+            leaf timer-name {
+              type string;
+              description "Name of the timer.";
+            }
+          }
+        }
+      }
+    }
+    list policy-map-rule {
+      key "class-name class-type";
+      description "Class-map rule.";
+      leaf class-name {
+        type string {
+          pattern "[a-zA-Z0-9][a-zA-Z0-9\._@$%+#:=<>\-]{0,62}";
+        }
+        description "Name of class-map.";
+      }
+      leaf class-type {
+        type Pmap-class-map-type;
+        description "Type of class-map.";
+      }
+      container shape {
+        must "rate" {
+          description "rate container must be present.";
+        }
+        description "Policy action shape.";
+        container rate {
+          description "Rate configuration.";
+          leaf value {
+            type uint32;
+            must "../unit" {
+              description "unit must be set.";
+            }
+            description "Shape bandwidth value.";
+          }
+          leaf unit {
+            type Bandwidth-units;
+            description "Shape bandwidth units.";
+          }
+        }
+        container burst {
+          description "Burst size configuration.";
+          leaf value {
+            type uint32;
+            must "../units" {
+              description "units must be set.";
+            }
+            description "Burst size value.";
+          }
+          leaf units {
+            type Threshold-units;
+            description "Burst size units.";
+          }
+        }
+      }
+      container min-bandwidth {
+        description "Policy action minimum bandwidth queue.";
+        leaf value {
+          type uint32;
+          must "../unit" {
+            description "unit must be set.";
+          }
+          description "Minimum bandwidth value.";
+        }
+        leaf unit {
+          type Bandwidth-units;
+          description "Minimum bandwidth units.";
+        }
+      }
+      container bandwidth-remaining {
+        description "Policy action bandwidth remaining queue.";
+        leaf value {
+          type uint32;
+          must "../unit" {
+            description "unit must be set.";
+          }
+          description "Remaining bandwidth value.";
+        }
+        leaf unit {
+          type Bandwidth-remaining-units;
+          description "Remaining bandwidth units.";
+        }
+      }
+      container queue-limit {
+        description "Policy action queue limit.";
+        leaf value {
+          type uint32;
+          must "../unit" {
+            description "unit must be set.";
+          }
+          description "Remaining bandwidth value.";
+        }
+        leaf unit {
+          type Queue-units;
+          description "Remaining bandwidth units.";
+        }
+      }
+      leaf priority-level {
+        type uint8 {
+          range "1..7";
+        }
+        description "Priority level.";
+      }
+      leaf default-red {
+        type empty;
+        description "Default random early detection";
+      }
+      leaf ecn-red {
+        type empty;
+        description "ECN based random early detection";
+      }
+      list random-detect {
+        key "threshold-min-value threshold-min-units "+
+            "threshold-max-value threshold-max-units";
+        description "Random early detection.
+                     All RED profiles in a class must be based
+                     on the same field.";
+        leaf threshold-min-value {
+          type uint32;
+          description "Minimum RED threshold value.";
+        }
+        leaf threshold-min-units {
+          type Threshold-units;
+          description "Minimum RED threshold units.";
+        }
+        leaf threshold-max-value {
+          type uint32;
+          description "Maximum RED threshold value.";
+        }
+        leaf threshold-max-units {
+          type Threshold-units;
+          description "Maximum RED threshold units.";
+        }
+        leaf-list cos {
+          type Dscp-range;
+          max-elements 8;
+          description "WRED based on CoS.";
+        }
+        leaf-list discard-class {
+          type Cos;
+          max-elements 8;
+          description "WRED based on discard class.";
+        }
+        leaf-list dscp {
+          type Dscp-range;
+          max-elements 8;
+          description "WRED based on DSCP.";
+        }
+        leaf-list mpls-exp {
+          type Cos;
+          max-elements 8;
+          description "MPLS Experimental value based WRED.";
+        }
+        leaf-list precedence {
+          type Precedence;
+          max-elements 8;
+          description "WRED based on precedence.";
+        }
+        leaf dei {
+          type uint8 {
+            range "0..1";
+          }
+          description "DEI based WRED.";
+        }
+      }
+      container set {
+        description "Policy action packet marking.";
+        uses POLICY-MARK;
+      }
+      container police {
+        must "rate" {
+          description "rate container must be present.";
+        }
+        description "Configures traffic policing action.";
+        container rate {
+          description "Rate configuration.";
+          leaf value {
+            type uint32;
+            must "../units" {
+              description "units must be set.";
+            }
+            description "Rate value.";
+          }
+          leaf units {
+            type Rate-units;
+            description "Rate units.";
+          }
+        }
+        container peak-rate {
+          description "Peak rate configuration.";
+          leaf value {
+            type uint32;
+            must "../units" {
+              description "units must be set.";
+            }
+            description "Peak rate value.";
+          }
+          leaf units {
+            type Rate-units;
+            description "Peak rate units.";
+          }
+        }
+        container burst {
+          description "Burst configuration.";
+          leaf value {
+            type uint32;
+            must "../units" {
+              description "units must be set.";
+            }
+            description "Burst value.";
+          }
+          leaf units {
+            type Threshold-units;
+            description "Burst units.";
+          }
+        }
+        container peak-burst {
+          description "Peak burst configuration.";
+          leaf value {
+            type uint32;
+            must "../units" {
+              description "units must be set.";
+            }
+            description "Peak burst value.";
+          }
+          leaf units {
+            type Threshold-units;
+            description "Peak burst units.";
+          }
+        }
+        container conform-action {
+          description 
+            "Configures the action to take on packets that conform 
+             to the rate limit.";
+          uses POLICE-ACTION;
+        }
+        container exceed-action {
+          description 
+            "Configures the action to take on packets that exceed 
+             the rate limit.";
+          uses POLICE-ACTION;
+        }
+        container violate-action {
+          description
+            "Configures the action to take on packets that violate
+             the rate limit.";
+          uses POLICE-ACTION;
+        }
+      }
+      container service-policy {
+        description 
+          "Configure a child service policy.";
+        leaf policy-name {
+          type string {
+            pattern "[a-zA-Z0-9][a-zA-Z0-9\._@$%+#:=<>\-]{0,62}";
+          }
+          description "Name of service-policy.";
+        }
+        leaf type {
+          type Service-policy-type;
+          description "Type of service-policy.";
+        }
+      }
+      container cac-local {
+        description "Policy action CAC.";
+        container rate {
+          description "The rate allocated for all flows.";
+          uses CAC-RATE-VALUE;
+        }
+        container flow-rate {
+          description "The rate allocated per flow.";
+          uses CAC-RATE-VALUE;
+        }
+        leaf flow-idle-timeout {
+          type Idle-timeout;
+          description "The interval after which a flow is removed, 
+                       if there is no activity.
+                       If timeout is 0 this flow does not expire.";
+        }
+      }
+      container flow-params {
+        description "Policy flow monitoring action.";
+        leaf max-flow {
+          type uint16 {
+            range "0..4096";
+          }
+          description 
+            "Max simultaneous flows monitored per policy class";
+        }
+        leaf interval-duration {
+          type uint32;
+          units "seconds";
+          description "Monitored interval duration.";
+        }
+        leaf history {
+          type uint32;
+          description 
+            "Keep stats/metrics on box for so many intervals.";
+        }
+        leaf timeout {
+          type uint32;
+          units "seconds";
+          description "Declare a flow dead if no packets received in
+                       so much time";
+        }
+      }
+      container metrics-ipcbr {
+        description "Policy IP-CBR metric action.";
+        container rate {
+          description "Nominal per-flow data rate.";
+          leaf layer3 {
+            type uint32;
+            units "bps";
+            description "Nominal rate specified at the L3 (IP).";
+          }
+          leaf packet {
+            type uint32;
+            units "pps";
+            description "Nominal IP layer packet rate (in pps).";
+          }
+          leaf media {
+            type uint32 {
+              range "1..3000000000";
+            }
+            units "bps";
+            description 
+              "Nominal data rate of the media flow (ip payload).";
+          }
+        }
+        container media-packet {
+          description "Media-packet structure.";
+          leaf size {
+            type uint16;
+            units "bytes";
+            description "Nominal size of the media-packet.";
+          }
+          leaf count-in-layer3 {
+            type uint8 {
+              range "1..64";
+            }
+            units "packets";
+            description 
+              "Nominal number of media packets in an IP payload.";
+          }
+        }
+      }
+      container react {
+        description "Policy action react.";
+        leaf descrition {
+          type string;
+          description "String describing the react statement.";
+        }
+        container action {
+          description "Action on alert.";
+          leaf syslog {
+            type empty;
+            description "Syslog.";
+          }
+          leaf snmp {
+            type empty;
+            description "SNMP.";
+          }
+        }
+        container alarm {
+          description "Alaram settings.";
+          container type {
+            description "Alarm type.";
+            leaf discrete {
+              type empty;
+              description "Discrete alarm type.";
+            }
+            leaf group-count {
+              type uint16;
+              units "number of flows";
+              description "Number of flows to reach before 
+                           triggering alarm";
+            }
+            leaf group-percent {
+              type uint16;
+              units "percentage";
+              description "Percent to reach before triggering alarm";
+            }
+          }
+          leaf severity {
+            type Alarm-severity;
+            description "Severity of the alarm.";
+          }
+        }
+        container treshold {
+          description "Alarm threshold settings.";
+          container trigger-value {
+            description "Alarm trigger value settings.";
+            leaf greater-than {
+              type string;
+              description "Greater than";
+            }
+            leaf greater-than-equal {
+              type string;
+              description "Greater than equal";
+            }
+            leaf less-than {
+              type string;
+              description "Less than";
+            }
+            leaf less-than-equal {
+              type string;
+              description "Less than equal";
+            }
+            leaf range {
+              type string;
+              description "Range";
+            }
+          }
+          container trigger-type {
+            description "Alarm trigger type settings.";
+            leaf immediate {
+              type empty;
+              description "Immediate trigger.";
+            }
+            leaf average {
+              type uint32;
+              description "Trigger averaged over N intervals.";
+            }
+          }
+        }
+        leaf criterion-delay-factor {
+          type empty;
+          description "React criterion delay factor.";
+        }
+        leaf criterion-media-stop {
+          type empty;
+          description "React criterion media stop.";
+        }
+        leaf criterion-mrv {
+          type empty;
+          description "React criterion mrv.";
+        }
+        leaf criterion-flow-count {
+          type empty;
+          description "React criterion flow count.";
+        }
+        leaf criterion-packet-rate {
+          type empty;
+          description "React criterion packet rate.";
+        }
+      }
+      container pbr {
+        description "Policy action PBR.";
+        leaf http-redirect {
+          type string;
+          description "Policy action http redirect.
+                       Redirect to this url.";
+        }
+        leaf pbr-transmit {
+          type empty;
+          description "Policy action PBR transmit.";
+        }
+        leaf pbr-drop {
+          type empty;
+          description "Policy action PBR drop.";
+        }
+        container pbr-forward {
+          description "Policy action PBR forward.";
+          leaf default {
+            type empty;
+            description "Use system default routing table.";
+          }
+          container next-hop {
+            description "Use specific next-hop.
+                         Here we present 5 different combination 
+                         for the pbf next-hop.
+                          1. vrf with v6 address
+                          2. vrf with v4 address
+                          3. vrf 
+                          4. v4 address
+                          5. v6 address";
+            leaf vrf {
+              type string;
+              description "VRF name.";
+            }
+            leaf ipv4-address {
+              type inet:ipv4-address;
+              description "IPv4 address.";
+            }
+            leaf ipv6-address {
+              type inet:ipv6-address;
+              description "IPv6 address.";
+            }
+          }
+        }
+        container set {
+          description "PBR action packet marking.";
+          uses POLICY-MARK;
+        }
+      }
+      leaf service-fragment {
+        type string;
+        description "Policy action service fragment. 
+                     Service fragment name";
+      }
+      leaf fragment {
+        type string;
+        description "Policy action fragment. Fragment name";
+      }
+    }
+    leaf description {
+      type string;
+      description "Description for this policy-map.";
+    }
+  }
+  
+  container policy-manager {
+    description "Global Policy Manager configuration.";
+    
+    container class-maps {
+      description "Class-maps configuration.";
+      list class-map {
+        key "type name";
+        description "Class-map configuration.";
+        leaf type {
+          type Class-map-type;
+          description "Type of class-map.";  
+        }
+        leaf name {
+          type string {
+            pattern "[a-zA-Z0-9][a-zA-Z0-9\._@$%+#:=<>\-]{0,62}";
+          }
+          description "Name of class-map.";
+        }
+        
+        uses CLASS-MAP-RULE;
+      }
+    }
+    
+    container policy-maps {
+      description "Policy-maps configuration.";
+      list policy-map {
+        key "type name";
+        description "Policy-map configuration.";
+        leaf type {
+          type Policy-map-type;
+          description "Type of policy-map.";
+        }
+        leaf name {
+          type string {
+            pattern "[a-zA-Z0-9][a-zA-Z0-9\._@$%+#:=<>\-]{0,62}";
+          }
+          description "Name of policy-map.";
+        }
+        
+        uses POLICY-MAP-RULE;
+      }
+    }
+  }
+}
\ No newline at end of file
diff --git a/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-ifmgr-cfg@2015-07-30.yang b/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-ifmgr-cfg@2015-07-30.yang
new file mode 100644 (file)
index 0000000..82edcef
--- /dev/null
@@ -0,0 +1,325 @@
+module Cisco-IOS-XR-ifmgr-cfg {
+
+  /*** NAMESPACE / PREFIX DEFINITION ***/
+
+  namespace "http://cisco.com/ns/yang/Cisco-IOS-XR-ifmgr-cfg";
+
+
+  prefix "ifmgr-cfg";
+
+  /*** LINKAGE (IMPORTS / INCLUDES) ***/
+
+  import Cisco-IOS-XR-types { prefix "xr"; }
+
+  /*** META INFORMATION ***/
+
+  organization "Cisco Systems, Inc.";
+
+  contact
+    "Cisco Systems, Inc.
+     Customer Service
+
+     Postal: 170 West Tasman Drive
+     San Jose, CA 95134
+
+     Tel: +1 800 553-NETS
+
+     E-mail: cs-yang@cisco.com";
+
+  description 
+    "This module contains a collection of YANG definitions
+     for Cisco IOS-XR ifmgr package configuration.
+
+     This module contains definitions
+     for the following management objects:
+       global-interface-configuration: Global scoped configuration
+         for interfaces
+       interface-configurations: interface configurations
+
+     Copyright (c) 2013-2015 by Cisco Systems, Inc.
+     All rights reserved.";
+
+  revision "2015-07-30" {
+    description
+      "Descriptions updated.";
+  }
+
+  revision "2015-01-07" {
+    description
+      "IOS XR 5.3.1 revision.";
+  }
+
+  typedef Interface-mode-enum {
+    type enumeration {
+      enum default {
+        value 0;
+        description "Default Interface Mode";
+      }
+      enum point-to-point {
+        value 1;
+        description "Point-to-Point Interface Mode";
+      }
+      enum multipoint {
+        value 2;
+        description "Multipoint Interface Mode";
+      }
+      enum l2-transport {
+        value 3;
+        description "L2 Transport Interface Mode";
+      }
+    }
+    description "Interface mode enum";
+  }
+  typedef Interface-active {
+    type string {
+      pattern "(act)|(pre)";
+    }
+    description "act:The interface is active, pre:Preconfiguration";
+  }
+  typedef Secondary-admin-state-enum {
+    type enumeration {
+      enum maintenance {
+        value 1;
+        description "Maintenance Mode";
+      }
+    }
+    description "Secondary admin state enum";
+  }
+  typedef Link-status-enum {
+    type enumeration {
+      enum default {
+        value 0;
+        description
+          "Display link status messages for physical links";
+      }
+      enum disable {
+        value 1;
+        description "Disable link status messages";
+      }
+      enum software-interfaces {
+        value 2;
+        description
+          "Display link status messages for all interfaces";
+      }
+    }
+    description "Link status enum";
+  }
+
+  container global-interface-configuration {
+    xr:xr-xml-map "ifmgr_cfg:GlobalInterfaceConfiguration";
+    description "Global scoped configuration for interfaces";
+    leaf link-status {
+      xr:xr-xml-map "ifmgr_cfg:LinkStatus";
+      xr:xr-cli-map "link-status (disable)|(software-interfaces)|(p"+
+        "hysical)|(logical) ";
+      type Link-status-enum;
+      default "default";
+      description "Enable or disable link-status messages";
+    }
+  }
+
+  container interface-configurations {
+    xr:xr-xml-map "ifmgr_cfg:InterfaceConfigurationTable";
+    description "interface configurations";
+
+    list interface-configuration {
+      xr:xr-xml-map "ifmgr_cfg:InterfaceConfiguration";
+      key "active interface-name";
+      description "The configuration for an interface";
+
+      container dampening {
+        xr:xr-xml-map "ifmgr_cfg:Dampening";
+        description
+          "Whether this interface's state changes are
+          dampened or not";
+        leaf args {
+          xr:xr-xml-map "ifmgr_cfg:Args";
+          type enumeration {
+            enum default-values {
+              value 0;
+              description "Default values";
+            }
+            enum specify-half-life {
+              value 1;
+              description "Half Life Specified";
+            }
+            enum specify-all {
+              value 4;
+              description
+                "All Arguments except Restart Penalty
+                Specified";
+            }
+            enum specify-rp {
+              value 5;
+              description "All Arguments Specified";
+            }
+          }
+          description "Dampening Arguments";
+        }
+        leaf half-life {
+          xr:xr-xml-map "ifmgr_cfg:HalfLife";
+          when "../args = 'specify-half-life' or ../args ="+
+            " 'specify-all' or ../args = 'specify-rp'" {
+              description
+                "../Args = 1 or ../Args = 4 or ../Args = 5";
+          }
+          type uint32 {
+            range "1..45";
+          }
+          units "minute";
+          description "Decay half life (in minutes)";
+        }
+        leaf reuse-threshold {
+          xr:xr-xml-map "ifmgr_cfg:ReuseThreshold";
+          when "../args = 'specify-all' or ../args = 'specify-rp'" {
+            description "../Args = 4 or ../Args = 5";
+          }
+          type uint32 {
+            range "1..20000";
+          }
+          description "Reuse threshold";
+        }
+        leaf suppress-threshold {
+          xr:xr-xml-map "ifmgr_cfg:SuppressThreshold";
+          when "../args = 'specify-all' or ../args = 'specify-rp'" {
+            description "../Args = 4 or ../Args = 5";
+          }
+          type uint32 {
+            range "1..20000";
+          }
+          description "Suppress threshold";
+        }
+        leaf suppress-time {
+          xr:xr-xml-map "ifmgr_cfg:SuppressTime";
+          when "../args = 'specify-all' or ../args = 'specify-rp'" {
+            description "../Args = 4 or ../Args = 5";
+          }
+          type uint32 {
+            range "1..255";
+          }
+          units "minute";
+          description "Max suppress time (in minutes)";
+        }
+        leaf restart-penalty {
+          xr:xr-xml-map "ifmgr_cfg:RestartPenalty";
+          when "../args = 'specify-rp'" {
+            description "../Args = 5";
+          }
+          type uint32 {
+            range "0..20000";
+          }
+          description "Restart penalty";
+        }
+      }
+
+      container mtus {
+        xr:xr-xml-map "ifmgr_cfg:MTUConfiguration";
+        description "The MTU configuration for the interface";
+
+        list mtu {
+          xr:xr-xml-map "ifmgr_cfg:MTU";
+          xr:xr-cli-map "interface <interface> (point-to-point)|(l2"+
+            "transport) mtu <number> ";
+          key "owner";
+          description "The MTU for the interface";
+          leaf owner {
+            xr:xr-xml-map "ifmgr_cfg:Owner";
+            type xr:Cisco-ios-xr-string;
+            description
+              "The Owner of the interface - eg. for
+              'LoopbackX' main interface this is 'loopback'";
+          }
+          leaf mtu {
+            xr:xr-xml-map "ifmgr_cfg:MTU";
+            type uint32 {
+              range "64..65535";
+            }
+            mandatory true;
+            description "The MTU value";
+          }
+        }
+      }
+
+      container encapsulation {
+        xr:xr-xml-map "ifmgr_cfg:Encapsulation";
+        description "The encapsulation on the interface";
+        leaf encapsulation {
+          xr:xr-xml-map "ifmgr_cfg:Encapsulation";
+          type string;
+          description "The encapsulation - e.g. hdlc, ppp";
+        }
+        leaf capsulation-options {
+          xr:xr-xml-map "ifmgr_cfg:CapsulationOptions";
+          type int32;
+          description
+            "The options for this capsulation, usually '0'";
+        }
+      }
+      leaf shutdown {
+        xr:xr-xml-map "ifmgr_cfg:Shutdown";
+        xr:xr-cli-map "interface <interface> (point-to-point)|(l2tr"+
+          "ansport) shutdown ";
+        type empty;
+        description
+          "The existence of this configuration indicates
+          the interface is shut down";
+      }
+      leaf interface-virtual {
+        xr:xr-xml-map "ifmgr_cfg:InterfaceVirtual";
+        type empty;
+        description
+          "The mode in which an interface is running. The
+          existence of this object causes the creation of
+          the software virtual/subinterface.";
+      }
+      leaf secondary-admin-state {
+        xr:xr-xml-map "ifmgr_cfg:SecondaryAdminState";
+        type Secondary-admin-state-enum;
+        description "The secondary admin state of the interface";
+      }
+      leaf interface-mode-non-physical {
+        xr:xr-xml-map "ifmgr_cfg:InterfaceModeNonPhysical";
+        type Interface-mode-enum;
+        default "default";
+        description
+          "The mode in which an interface is running. The
+          existence of this object causes the creation of
+          the software subinterface.";
+      }
+      leaf bandwidth {
+        xr:xr-xml-map "ifmgr_cfg:Bandwidth";
+        xr:xr-cli-map "interface <interface> (point-to-point)|(l2tr"+
+          "ansport) bandwidth <number> ";
+        type int32;
+        units "kbit/s";
+        description "The bandwidth of the interface in kbps";
+      }
+      leaf link-status {
+        xr:xr-xml-map "ifmgr_cfg:LinkStatus";
+        xr:xr-cli-map "interface <interface> (point-to-point)|(l2tr"+
+          "ansport) logging events link-status ";
+        type empty;
+        description
+          "Enable interface and line-protocol state change
+          alarms";
+      }
+      leaf description {
+        xr:xr-xml-map "ifmgr_cfg:Description";
+        type string;
+        description "The description of this interface";
+      }
+      leaf active {
+        xr:xr-xml-map "ifmgr_cfg:Active";
+        type Interface-active;
+        description
+          "Whether the interface is active or
+          preconfigured";
+      }
+      leaf interface-name {
+        xr:xr-xml-map "ifmgr_cfg:InterfaceName";
+        type xr:Interface-name;
+        description "The name of the interface";
+      }
+    }
+  }
+}
\ No newline at end of file
diff --git a/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-ip-static-cfg@2015-09-10.yang b/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-ip-static-cfg@2015-09-10.yang
new file mode 100644 (file)
index 0000000..ad8c3cd
--- /dev/null
@@ -0,0 +1,448 @@
+module Cisco-IOS-XR-ip-static-cfg {
+
+  /*** NAMESPACE / PREFIX DEFINITION ***/
+
+  namespace "http://cisco.com/ns/yang/Cisco-IOS-XR-ip-static-cfg";
+
+
+  prefix "ip-static-cfg";
+
+  /*** LINKAGE (IMPORTS / INCLUDES) ***/
+
+  import ietf-inet-types { prefix "inet"; }
+
+  import Cisco-IOS-XR-types { prefix "xr"; }
+
+  /*** META INFORMATION ***/
+
+  organization "Cisco Systems, Inc.";
+
+  contact
+    "Cisco Systems, Inc.
+     Customer Service
+
+     Postal: 170 West Tasman Drive
+     San Jose, CA 95134
+
+     Tel: +1 800 553-NETS
+
+     E-mail: cs-yang@cisco.com";
+
+  description 
+    "This module contains a collection of YANG definitions
+     for Cisco IOS-XR ip-static package configuration.
+
+     This module contains definitions
+     for the following management objects:
+       router-static: This class represents router static
+         configuration
+
+     Copyright (c) 2013-2015 by Cisco Systems, Inc.
+     All rights reserved.";
+
+  revision "2015-09-10" {
+    description
+      "Descriptions updated.";
+  }
+
+  revision "2015-01-07" {
+    description
+      "IOS XR 5.3.1 revision.";
+  }
+
+
+  grouping VRF-ROUTE {
+    description "Common node of vrf-prefix, vrf-prefix-topology";
+
+    container vrf-route {
+      xr:xr-xml-map "ip_static_cfg:VRFRoute";
+      description "A connected or recursive  static route";
+
+      container vrf-next-hop-table {
+        xr:xr-xml-map "ip_static_cfg:VRFNextHopTable";
+        description
+          "The set of nexthop information configured for
+          this route";
+        uses VRF-NEXT-HOP;
+      }
+    }
+  }
+
+  grouping VRF-NEXT-HOP {
+    description
+      "Common node of vrf-next-hop-table,
+      segment-route-next-hop-table";
+
+    grouping VRF-NEXT-HOP-CONTENT {
+      description "VRF NEXT HOP CONTENT";
+      leaf bfd-fast-detect {
+        xr:xr-xml-map "ip_static_cfg:BFDFastDetect";
+        type boolean;
+        default "false";
+        description "If set, bfd is enabled";
+      }
+      leaf minimum-interval {
+        xr:xr-xml-map "ip_static_cfg:MinimumInterval";
+        type uint32 {
+          range "3..30000";
+        }
+        units "millisecond";
+        default "100";
+        description "BFD Hello interval in milliseconds";
+      }
+      leaf detect-multiplier {
+        xr:xr-xml-map "ip_static_cfg:DetectMultiplier";
+        type uint32 {
+          range "1..10";
+        }
+        default "3";
+        description "BFD Detect Multiplier";
+      }
+      leaf metric {
+        xr:xr-xml-map "ip_static_cfg:Metric";
+        type uint32 {
+          range "1..254";
+        }
+        default "1";
+        description "Distance metric for this path";
+      }
+      leaf tag {
+        xr:xr-xml-map "ip_static_cfg:Tag";
+        type uint32 {
+          range "1..4294967295";
+        }
+        description "Tag for this path";
+      }
+      leaf permanent {
+        xr:xr-xml-map "ip_static_cfg:Permanent";
+        type boolean;
+        default "false";
+        description "If set, path is permanent";
+      }
+      leaf vrf-lable {
+        xr:xr-xml-map "ip_static_cfg:VRFLable";
+        type uint32 {
+          range "0..4294967295";
+        }
+        default "0";
+        description "VRF LABEL";
+      }
+      leaf tunnel-id {
+        xr:xr-xml-map "ip_static_cfg:TunnelID";
+        type uint32 {
+          range "0..65535";
+        }
+        default "0";
+        description "Tunnel ID for this path";
+      }
+      leaf object-name {
+        xr:xr-xml-map "ip_static_cfg:ObjectName";
+        type xr:Cisco-ios-xr-string {
+          length "0..32";
+        }
+        description "Name of the object to track";
+      }
+      leaf description {
+        xr:xr-xml-map "ip_static_cfg:Description";
+        type string;
+        description "Short Description of Static Route";
+      }
+      leaf load-metric {
+        xr:xr-xml-map "ip_static_cfg:Load_Metric";
+        type uint32 {
+          range "1..16777214";
+        }
+        default "1";
+        description "UCMP load metric";
+      }
+    }
+
+    list vrf-next-hop-interface-name {
+      key "interface-name";
+      description
+        "A forwarding interface or Segement Routing mpls
+        path name and/or the address of a nexthop router
+        for this route (one of these must be specified)";
+      leaf interface-name {
+        xr:xr-xml-map "ip_static_cfg:InterfaceName";
+        type xr:Interface-name;
+        description "Forwarding interface";
+      }
+      uses VRF-NEXT-HOP-CONTENT;
+    }
+
+    list vrf-next-hop-interface-name-next-hop-address {
+      key "interface-name next-hop-address";
+      description
+        "A forwarding interface or Segement Routing mpls
+        path name and/or the address of a nexthop router
+        for this route (one of these must be specified)";
+      leaf interface-name {
+        xr:xr-xml-map "ip_static_cfg:InterfaceName";
+        type xr:Interface-name;
+        description "Forwarding interface";
+      }
+      leaf next-hop-address {
+        xr:xr-xml-map "ip_static_cfg:NextHopAddress";
+        type inet:ip-address-no-zone;
+        description "Next hop address";
+      }
+      uses VRF-NEXT-HOP-CONTENT;
+    }
+
+    list vrf-next-hop-next-hop-address {
+      key "next-hop-address";
+      description
+        "A forwarding interface or Segement Routing mpls
+        path name and/or the address of a nexthop router
+        for this route (one of these must be specified)";
+      leaf next-hop-address {
+        xr:xr-xml-map "ip_static_cfg:NextHopAddress";
+        type inet:ip-address-no-zone;
+        description "Next hop address";
+      }
+      uses VRF-NEXT-HOP-CONTENT;
+    }
+
+    list vrf-next-hop-next-hop-address-explicit-path-name {
+      key "next-hop-address explicit-path-name";
+      description
+        "A forwarding interface or Segement Routing mpls
+        path name and/or the address of a nexthop router
+        for this route (one of these must be specified)";
+      leaf next-hop-address {
+        xr:xr-xml-map "ip_static_cfg:NextHopAddress";
+        type inet:ip-address-no-zone;
+        description "Next hop address";
+      }
+      leaf explicit-path-name {
+        xr:xr-xml-map "ip_static_cfg:ExplicitPathName";
+        type xr:Cisco-ios-xr-string;
+        description "Segment Routing mpls path name";
+      }
+      uses VRF-NEXT-HOP-CONTENT;
+    }
+
+    list vrf-next-hop-explicit-path-name {
+      key "explicit-path-name";
+      description
+        "A forwarding interface or Segement Routing mpls
+        path name and/or the address of a nexthop router
+        for this route (one of these must be specified)";
+      leaf explicit-path-name {
+        xr:xr-xml-map "ip_static_cfg:ExplicitPathName";
+        type xr:Cisco-ios-xr-string;
+        description "Segment Routing mpls path name";
+      }
+      uses VRF-NEXT-HOP-CONTENT;
+    }
+  }
+
+  grouping VRF-SEG-ROUTE {
+    description "Common node of vrf-prefix, vrf-prefix-topology";
+
+    container vrf-seg-route {
+      xr:xr-xml-map "ip_static_cfg:VRFSegRoute";
+      description "A static segment route";
+
+      container segment-route-next-hop-table {
+        xr:xr-xml-map "ip_static_cfg:SegmentRouteNextHopTable";
+        description
+          "The set of nexthop information configured for
+          this route";
+        uses VRF-NEXT-HOP;
+      }
+    }
+  }
+
+  grouping TOPOLOGY-TABLE {
+    description "Common node of vrf-unicast, vrf-multicast";
+
+    container topologies {
+      xr:xr-xml-map "ip_static_cfg:TopologyTable";
+      description "Topology static configuration container";
+
+      list topology {
+        xr:xr-xml-map "ip_static_cfg:Topology";
+        key "topology-name";
+        description "Topology static configuration";
+        leaf topology-name {
+          xr:xr-xml-map "ip_static_cfg:TopologyName";
+          type xr:Cisco-ios-xr-string;
+          description "Topology name";
+        }
+        uses VRF-PREFIX-TOPOLOGY-TABLE;
+      }
+    }
+  }
+
+  grouping VRF-PREFIX-TABLE {
+    description "Common node of vrf-unicast, vrf-multicast";
+
+    container vrf-prefixes {
+      xr:xr-xml-map "ip_static_cfg:VRFPrefixTable";
+      description "The set of all Static Topologies for this AFI.";
+
+      list vrf-prefix {
+        xr:xr-xml-map "ip_static_cfg:VRFPrefix";
+        key "prefix prefix-length";
+        description "A static route";
+        leaf prefix {
+          xr:xr-xml-map "ip_static_cfg:Prefix";
+          type inet:ip-address-no-zone;
+          description "Destination prefix";
+        }
+        leaf prefix-length {
+          xr:xr-xml-map "ip_static_cfg:PrefixLength";
+          type uint32 {
+            range "0..128";
+          }
+          description "Destination prefix length";
+        }
+        uses VRF-ROUTE;
+        uses VRF-SEG-ROUTE;
+      }
+    }
+  }
+
+  grouping ADDRESS-FAMILY {
+    description "Common node of default-vrf, vrf";
+
+    container address-family {
+      xr:xr-xml-map "ip_static_cfg:AddressFamily";
+      description "Address family configuration";
+
+      container vrfipv4 {
+        xr:xr-xml-map "ip_static_cfg:VRFIPV4";
+        description "IPv4 static configuration";
+        uses VRF-UNICAST;
+        uses VRF-MULTICAST;
+      }
+
+      container vrfipv6 {
+        xr:xr-xml-map "ip_static_cfg:VRFIPV6";
+        description "IPv6 static configuration";
+        uses VRF-UNICAST;
+        uses VRF-MULTICAST;
+      }
+    }
+  }
+
+  grouping VRF-PREFIX-TOPOLOGY-TABLE {
+    description "Common node of default-topology, topology";
+
+    container vrf-prefix-topologies {
+      xr:xr-xml-map "ip_static_cfg:VRFPrefixTopologyTable";
+      description "The set of all Static Topologies for this AFI.";
+
+      list vrf-prefix-topology {
+        xr:xr-xml-map "ip_static_cfg:VRFPrefixTopology";
+        key "prefix prefix-length";
+        description "A static route";
+        leaf prefix {
+          xr:xr-xml-map "ip_static_cfg:Prefix";
+          type inet:ip-address-no-zone;
+          description "Destination prefix";
+        }
+        leaf prefix-length {
+          xr:xr-xml-map "ip_static_cfg:PrefixLength";
+          type uint32 {
+            range "0..128";
+          }
+          description "Destination prefix length";
+        }
+        uses VRF-ROUTE;
+        uses VRF-SEG-ROUTE;
+      }
+    }
+  }
+
+  grouping DEFAULT-TOPOLOGY {
+    description "Common node of vrf-unicast, vrf-multicast";
+
+    container default-topology {
+      xr:xr-xml-map "ip_static_cfg:DefaultTopology";
+      description "Default topology configuration";
+      uses VRF-PREFIX-TOPOLOGY-TABLE;
+    }
+  }
+
+  grouping VRF-UNICAST {
+    description "Common node of vrfipv4, vrfipv6";
+
+    container vrf-unicast {
+      xr:xr-xml-map "ip_static_cfg:VRFUnicast";
+      description "Unicast static configuration";
+      uses TOPOLOGY-TABLE;
+      uses VRF-PREFIX-TABLE;
+      uses DEFAULT-TOPOLOGY;
+    }
+  }
+
+  grouping VRF-MULTICAST {
+    description "Common node of vrfipv4, vrfipv6";
+
+    container vrf-multicast {
+      xr:xr-xml-map "ip_static_cfg:VRFMulticast";
+      description "Multicast static configuration";
+      uses TOPOLOGY-TABLE;
+      uses VRF-PREFIX-TABLE;
+      uses DEFAULT-TOPOLOGY;
+    }
+  }
+
+  container router-static {
+    xr:xr-xml-map "ip_static_cfg:RouterStatic";
+    description "This class represents router static configuration";
+
+    container vrfs {
+      xr:xr-xml-map "ip_static_cfg:VRFTable";
+      description "VRF static configuration container";
+
+      list vrf {
+        xr:xr-xml-map "ip_static_cfg:VRF";
+        key "vrf-name";
+        description "VRF static configuration";
+        leaf vrf-name {
+          xr:xr-xml-map "ip_static_cfg:VRFName";
+          type xr:Cisco-ios-xr-string;
+          description "VRF name";
+        }
+        uses ADDRESS-FAMILY;
+      }
+    }
+
+    container default-vrf {
+      xr:xr-xml-map "ip_static_cfg:DefaultVRF";
+      description "Default VRF configuration";
+      uses ADDRESS-FAMILY;
+    }
+
+    container maximum-routes {
+      xr:xr-xml-map "ip_static_cfg:MaximumRoutes";
+      description
+        "The maximum number of static routes that can be
+        configured.";
+      leaf ipv6-routes {
+        xr:xr-xml-map "ip_static_cfg:IPV6Routes";
+        type uint32 {
+          range "1..140000";
+        }
+        default "4000";
+        description
+          "The maximum number of static routes that can be
+          configured for IPv6 AFI.";
+      }
+      leaf ipv4-routes {
+        xr:xr-xml-map "ip_static_cfg:IPV4Routes";
+        type uint32 {
+          range "1..140000";
+        }
+        default "4000";
+        description
+          "The maximum number of static routes that can be
+          configured for IPv4 AFI.";
+      }
+    }
+  }
+}
\ No newline at end of file
diff --git a/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-l2-eth-infra-cfg@2015-11-09.yang b/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-l2-eth-infra-cfg@2015-11-09.yang
new file mode 100644 (file)
index 0000000..dea4db6
--- /dev/null
@@ -0,0 +1,844 @@
+module Cisco-IOS-XR-l2-eth-infra-cfg {
+
+  /*** NAMESPACE / PREFIX DEFINITION ***/
+
+  namespace "http://cisco.com/ns/yang/Cisco-IOS-XR-l2-eth-infra-cfg";
+
+
+  prefix "l2-eth-infra-cfg";
+
+  /*** LINKAGE (IMPORTS / INCLUDES) ***/
+
+  import ietf-yang-types { prefix "yang"; }
+
+  import Cisco-IOS-XR-types { prefix "xr"; }
+
+  import Cisco-IOS-XR-l2-eth-infra-datatypes { prefix "dt1"; }
+
+  import Cisco-IOS-XR-ifmgr-cfg { prefix "a1"; }
+
+  import Cisco-IOS-XR-l2vpn-cfg { prefix "a2"; }
+
+  /*** META INFORMATION ***/
+
+  organization "Cisco Systems, Inc.";
+
+  contact
+    "Cisco Systems, Inc.
+     Customer Service
+
+     Postal: 170 West Tasman Drive
+     San Jose, CA 95134
+
+     Tel: +1 800 553-NETS
+
+     E-mail: cs-yang@cisco.com";
+
+  description 
+    "This module contains a collection of YANG definitions
+     for Cisco IOS-XR l2-eth-infra package configuration.
+
+     This module contains definitions
+     for the following management objects:
+       ethernet-features: Ethernet Features Configuration
+
+     This YANG module augments the
+       Cisco-IOS-XR-ifmgr-cfg,
+       Cisco-IOS-XR-l2vpn-cfg
+     modules with configuration data.
+
+     Copyright (c) 2013-2015 by Cisco Systems, Inc.
+     All rights reserved.";
+
+  revision "2015-11-09" {
+    description
+      "IOS XR 6.0 revision.";
+  }
+
+  typedef L2-protocol-name {
+    type enumeration {
+      enum cdp {
+        value 0;
+        description "CDP";
+      }
+      enum stp {
+        value 1;
+        description "STP";
+      }
+      enum vtp {
+        value 2;
+        description "VTP";
+      }
+      enum pvst {
+        value 3;
+        description "PVST+";
+      }
+      enum cpsv {
+        value 4;
+        description "CDP, PVST+, STP, and VTP";
+      }
+    }
+    description "L2 protocol name";
+  }
+  typedef L2-protocol-mode {
+    type enumeration {
+      enum forward {
+        value 0;
+        description "Forward packets transparently";
+      }
+      enum drop {
+        value 1;
+        description "Drop the protocol's packets";
+      }
+      enum tunnel {
+        value 2;
+        description "Tunnel ingress frames, untunnel egress frames";
+      }
+      enum reverse-tunnel {
+        value 3;
+        description "Tunnel egress frames, untunnel ingress frames";
+      }
+    }
+    description "L2 protocol mode";
+  }
+  typedef Egress-filtering {
+    type enumeration {
+      enum egress-filtering-type-strict {
+        value 1;
+        description "Strict Egress Filtering";
+      }
+      enum egress-filtering-type-disable {
+        value 2;
+        description "Egress Filtering Disabled";
+      }
+      enum egress-filtering-type-default {
+        value 3;
+        description "Default Egress Filtering Behavior";
+      }
+    }
+    description "Egress filtering";
+  }
+  typedef Filtering {
+    type enumeration {
+      enum filtering-type-dot1q {
+        value 0;
+        description
+          "C-Vlan ingress frame filtering (Table 8-1 of
+          802.1ad standard)";
+      }
+      enum filtering-type-dot1ad {
+        value 1;
+        description
+          "S-Vlan ingress frame filtering (Table 8-2 of
+          802.1ad standard)";
+      }
+    }
+    description "Filtering";
+  }
+  typedef L2-protocol-mpls-exp-bits-value {
+    type uint32 {
+      range "0..7";
+    }
+    description "L2 protocol mpls exp bits value";
+  }
+
+  container ethernet-features {
+    xr:xr-xml-map "ether_gl_feature_cfg:EthernetFeatures";
+    description "Ethernet Features Configuration";
+
+    container egress-filtering {
+      xr:xr-xml-map "ether_gl_cfg:EgressFiltering";
+      description "Egress Filtering Configuration";
+      leaf egress-filtering-default-on {
+        xr:xr-xml-map "ether_gl_cfg:EgressFilteringDefaultOn";
+        type empty;
+        description "Whether Egress Filtering is on by default";
+      }
+    }
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration" {
+
+    container vlan-sub-configuration {
+      xr:xr-xml-map "vlan_interface_cfg:VLANSubConfiguration";
+      description "IEEE 802.1Q VLAN subinterface configuration";
+
+      container vlan-identifier {
+        xr:xr-xml-map "vlan_interface_cfg:VLANIdentifier";
+        presence "Indicates a vlan-identifier node is configured.";
+        description
+          "The VLAN tag stack associated with this
+          sub-interface.";
+        leaf vlan-type {
+          xr:xr-xml-map "vlan_interface_cfg:VlanType";
+          type dt1:Vlan;
+          mandatory true;
+          description
+            "Whether this sub-interface is dot1ad or dot1Q";
+        }
+        leaf first-tag {
+          xr:xr-xml-map "vlan_interface_cfg:FirstTag";
+          type dt1:Vlan-tag;
+          mandatory true;
+          description "First (outermost) VLAN tag value";
+        }
+        leaf second-tag {
+          xr:xr-xml-map "vlan_interface_cfg:SecondTag";
+          type dt1:Vlan-tag-or-null;
+          description
+            "Second VLAN tag value. The any value may only
+            be used for Layer 2 subinterfaces";
+        }
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-ifmgr-cfg'";
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration" {
+
+    container ethernet-service {
+      xr:xr-xml-map "vlan_interface_cfg:EthernetService";
+      description "Ethernet service configuration";
+
+      container local-traffic-default-encapsulation {
+        xr:xr-xml-map "vlan_interface_cfg:LocalTrafficDefaultEncaps"+
+          "ulation";
+        presence "Indicates a local-traffic-default-encapsulation"+
+          " node is configured.";
+        description
+          "The default encapsulation to be used for
+          locally-sourced packets";
+        leaf outer-tag-type {
+          xr:xr-xml-map "vlan_interface_cfg:OuterTagType";
+          type dt1:Vlan;
+          mandatory true;
+          description "Type of outer tag";
+        }
+        leaf outer-vlan-id {
+          xr:xr-xml-map "vlan_interface_cfg:OuterVLANId";
+          type dt1:Vlan-tag;
+          mandatory true;
+          description "VLAN id for outer tag";
+        }
+        leaf inner-vlan-id {
+          xr:xr-xml-map "vlan_interface_cfg:InnerVLANId";
+          type dt1:Vlan-tag;
+          description "Optional VLAN Id for inner Dot1Q tag";
+        }
+      }
+
+      container encapsulation {
+        xr:xr-xml-map "vlan_interface_cfg:Encapsulation";
+        presence "Indicates a encapsulation node is configured.";
+        description "The encapsulation of this Ethernet service";
+        leaf outer-tag-type {
+          xr:xr-xml-map "vlan_interface_cfg:OuterTagType";
+          type dt1:Match;
+          mandatory true;
+          description
+            "Whether to match all unmatched packets,
+            untagged packets or tagged packets, and if
+            matching tagged packets, the outer tag type to
+            match";
+        }
+        leaf outer-range1-low {
+          xr:xr-xml-map "vlan_interface_cfg:OuterRange1Low";
+          type dt1:Vlan-tag-or-any;
+          description
+            "Low value of first range for outer tag match";
+        }
+        leaf outer-range1-high {
+          xr:xr-xml-map "vlan_interface_cfg:OuterRange1High";
+          type dt1:Vlan-tag-or-native;
+          description
+            "High value of first range for outer tag match";
+        }
+        leaf inner-tag-type {
+          xr:xr-xml-map "vlan_interface_cfg:InnerTagType";
+          type dt1:Match;
+          description "Type of tag for inner match (if present)";
+        }
+        leaf inner-range1-low {
+          xr:xr-xml-map "vlan_interface_cfg:InnerRange1Low";
+          type dt1:Vlan-tag-or-any;
+          description
+            "Low value of first range for inner tag match";
+        }
+        leaf inner-range1-high {
+          xr:xr-xml-map "vlan_interface_cfg:InnerRange1High";
+          type dt1:Vlan-tag;
+          description
+            "High value of first range for inner tag match";
+        }
+        leaf additional-range1-low {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange1Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of first additional range for tag
+            match";
+        }
+        leaf additional-range1-high {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange1High";
+          type dt1:Vlan-tag;
+          description
+            "High value of first additional range for tag
+            match";
+        }
+        leaf additional-range2-low {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange2Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of second additional range for tag
+            match";
+        }
+        leaf additional-range2-high {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange2High";
+          type dt1:Vlan-tag;
+          description
+            "High value of second additional range for tag
+            match";
+        }
+        leaf additional-range3-low {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange3Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of third additional range for tag
+            match";
+        }
+        leaf additional-range3-high {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange3High";
+          type dt1:Vlan-tag;
+          description
+            "High value of third additional range for tag
+            match";
+        }
+        leaf additional-range4-low {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange4Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of forth additional range for tag
+            match";
+        }
+        leaf additional-range4-high {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange4High";
+          type dt1:Vlan-tag;
+          description
+            "High value of forth additional range for tag
+            match";
+        }
+        leaf additional-range5-low {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange5Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of fifth additional range for tag
+            match";
+        }
+        leaf additional-range5-high {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange5High";
+          type dt1:Vlan-tag;
+          description
+            "High value of fifth additional range for tag
+            match";
+        }
+        leaf additional-range6-low {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange6Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of sixth additional range for tag
+            match";
+        }
+        leaf additional-range6-high {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange6High";
+          type dt1:Vlan-tag;
+          description
+            "High value of sixth additional range for tag
+            match";
+        }
+        leaf additional-range7-low {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange7Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of seventh additional range for tag
+            match";
+        }
+        leaf additional-range7-high {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange7High";
+          type dt1:Vlan-tag;
+          description
+            "High value of seventh additional range for tag
+            match";
+        }
+        leaf additional-range8-low {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange8Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of eighth additional range for tag
+            match";
+        }
+        leaf additional-range8-high {
+          xr:xr-xml-map "vlan_interface_cfg:AdditionalRange8High";
+          type dt1:Vlan-tag;
+          description
+            "High value of eighth additional range for tag
+            match";
+        }
+        leaf outer-class-of-service {
+          xr:xr-xml-map "vlan_interface_cfg:OuterClassOfService";
+          type dt1:Class-of-service;
+          description
+            "Value to match against Class Of Service bits
+            for outer tag";
+        }
+        leaf inner-class-of-service {
+          xr:xr-xml-map "vlan_interface_cfg:InnerClassOfService";
+          type dt1:Class-of-service;
+          description
+            "Value to match against Class Of Service bits
+            for inner tag";
+        }
+        leaf payload-ethertype-match {
+          xr:xr-xml-map "vlan_interface_cfg:PayloadEthertypeMatch";
+          type dt1:Ethertype-match;
+          description "Which payload ethertype values to match";
+        }
+        leaf ingress-source-mac {
+          xr:xr-xml-map "vlan_interface_cfg:IngressSourceMAC";
+          type yang:mac-address;
+          description "Source MAC address to match on ingress";
+        }
+        leaf ingress-destination-mac {
+          xr:xr-xml-map "vlan_interface_cfg:IngressDestinationMAC";
+          type yang:mac-address;
+          description "Destination MAC address to match on egress";
+        }
+        leaf exact {
+          xr:xr-xml-map "vlan_interface_cfg:Exact";
+          type empty;
+          description
+            "Only match packets with no more tags than
+            explicitly matched";
+        }
+      }
+
+      container rewrite {
+        xr:xr-xml-map "vlan_interface_cfg:Rewrite";
+        presence "Indicates a rewrite node is configured.";
+        description
+          "The rewrite operation for the Ethernet service";
+        leaf rewrite-type {
+          xr:xr-xml-map "vlan_interface_cfg:RewriteType";
+          type dt1:Rewrite;
+          mandatory true;
+          description "The type of rewrite to perform";
+        }
+        leaf outer-tag-type {
+          xr:xr-xml-map "vlan_interface_cfg:OuterTagType";
+          type dt1:Match;
+          description "Type of outermost tag to be pushed";
+        }
+        leaf outer-tag-value {
+          xr:xr-xml-map "vlan_interface_cfg:OuterTagValue";
+          type dt1:Vlan-tag;
+          description "VLAN Id of outermost tag to be pushed";
+        }
+        leaf inner-tag-type {
+          xr:xr-xml-map "vlan_interface_cfg:InnerTagType";
+          type dt1:Match;
+          description "Type of innermost tag to be pushed";
+        }
+        leaf inner-tag-value {
+          xr:xr-xml-map "vlan_interface_cfg:InnerTagValue";
+          type dt1:Vlan-tag;
+          description "VLAN Id of innermost tag to be pushed";
+        }
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-ifmgr-cfg'";
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration" {
+
+    container ethernet-bng {
+      xr:xr-xml-map "eth_infra_bng_intf_cfg:EthernetBNG";
+      description "Ethernet Infra BNG specific configuration";
+
+      container ambiguous-encapsulation {
+        xr:xr-xml-map "eth_infra_bng_intf_cfg:AmbiguousEncapsulatio"+
+          "n";
+        presence "Indicates a ambiguous-encapsulation node is"+
+          " configured.";
+        description "L3 Ambiguous encapsulation";
+        leaf outer-tag-type {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:OuterTagType";
+          type dt1:Match;
+          mandatory true;
+          description
+            "Whether to match all unmatched packets,
+            untagged packets or tagged packets, and if
+            matching tagged packets, the outer tag type to
+            match";
+        }
+        leaf outer-range1-low {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:OuterRange1Low";
+          type dt1:Vlan-tag-or-any;
+          description
+            "Low value of first range for outer tag match";
+        }
+        leaf outer-range1-high {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:OuterRange1High";
+          type dt1:Vlan-tag-or-native;
+          description
+            "High value of first range for outer tag match";
+        }
+        leaf inner-tag-type {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:InnerTagType";
+          type dt1:Match;
+          description "Type of tag for inner match (if present)";
+        }
+        leaf inner-range1-low {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:InnerRange1Low";
+          type dt1:Vlan-tag-or-any;
+          description
+            "Low value of first range for inner tag match";
+        }
+        leaf inner-range1-high {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:InnerRange1High";
+          type dt1:Vlan-tag;
+          description
+            "High value of first range for inner tag match";
+        }
+        leaf additional-range1-low {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange1Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of first additional range for tag
+            match";
+        }
+        leaf additional-range1-high {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange1Hig"+
+            "h";
+          type dt1:Vlan-tag;
+          description
+            "High value of first additional range for tag
+            match";
+        }
+        leaf additional-range2-low {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange2Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of second additional range for tag
+            match";
+        }
+        leaf additional-range2-high {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange2Hig"+
+            "h";
+          type dt1:Vlan-tag;
+          description
+            "High value of second additional range for tag
+            match";
+        }
+        leaf additional-range3-low {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange3Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of third additional range for tag
+            match";
+        }
+        leaf additional-range3-high {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange3Hig"+
+            "h";
+          type dt1:Vlan-tag;
+          description
+            "High value of third additional range for tag
+            match";
+        }
+        leaf additional-range4-low {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange4Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of forth additional range for tag
+            match";
+        }
+        leaf additional-range4-high {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange4Hig"+
+            "h";
+          type dt1:Vlan-tag;
+          description
+            "High value of forth additional range for tag
+            match";
+        }
+        leaf additional-range5-low {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange5Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of fifth additional range for tag
+            match";
+        }
+        leaf additional-range5-high {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange5Hig"+
+            "h";
+          type dt1:Vlan-tag;
+          description
+            "High value of fifth additional range for tag
+            match";
+        }
+        leaf additional-range6-low {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange6Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of sixth additional range for tag
+            match";
+        }
+        leaf additional-range6-high {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange6Hig"+
+            "h";
+          type dt1:Vlan-tag;
+          description
+            "High value of sixth additional range for tag
+            match";
+        }
+        leaf additional-range7-low {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange7Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of seventh additional range for tag
+            match";
+        }
+        leaf additional-range7-high {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange7Hig"+
+            "h";
+          type dt1:Vlan-tag;
+          description
+            "High value of seventh additional range for tag
+            match";
+        }
+        leaf additional-range8-low {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange8Low";
+          type dt1:Vlan-tag-or-cvp;
+          description
+            "Low value of eighth additional range for tag
+            match";
+        }
+        leaf additional-range8-high {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:AdditionalRange8Hig"+
+            "h";
+          type dt1:Vlan-tag;
+          description
+            "High value of eighth additional range for tag
+            match";
+        }
+        leaf outer-class-of-service {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:OuterClassOfService";
+          type dt1:Class-of-service;
+          description
+            "Value to match against Class Of Service bits
+            for outer tag";
+        }
+        leaf inner-class-of-service {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:InnerClassOfService";
+          type dt1:Class-of-service;
+          description
+            "Value to match against Class Of Service bits
+            for inner tag";
+        }
+        leaf payload-ethertype-match {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:PayloadEthertypeMat"+
+            "ch";
+          type dt1:Ethertype-match;
+          description "Which payload ethertype values to match";
+        }
+        leaf ingress-source-mac {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:IngressSourceMAC";
+          type yang:mac-address;
+          description "Source MAC address to match on ingress";
+        }
+        leaf ingress-destination-mac {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:IngressDestinationM"+
+            "AC";
+          type yang:mac-address;
+          description "Destination MAC address to match on egress";
+        }
+        leaf exact {
+          xr:xr-xml-map "eth_infra_bng_intf_cfg:Exact";
+          type empty;
+          description
+            "Only match packets with no more tags than
+            explicitly matched";
+        }
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-ifmgr-cfg'";
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration" {
+
+    container mac-accounting {
+      xr:xr-xml-map "ether_mac_acc_cfg:MACAccounting";
+      description "MAC Accounting Configuration";
+      leaf ingress {
+        xr:xr-xml-map "ether_mac_acc_cfg:Ingress";
+        type empty;
+        description "Per MAC address accounting statistics";
+      }
+      leaf egress {
+        xr:xr-xml-map "ether_mac_acc_cfg:Egress";
+        type empty;
+        description "Per MAC address accounting statistics";
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-ifmgr-cfg'";
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration" {
+
+    container ethernet-features {
+      xr:xr-xml-map "ether_intf_feature_cfg:EthernetFeatures";
+      description "Ethernet Features Configuration";
+      leaf filtering {
+        xr:xr-xml-map "l2protocols_ether_interface_cfg:Filtering";
+        type Filtering;
+        description "Ingress Ethernet frame filtering";
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-ifmgr-cfg'";
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration" {
+
+    container vlan-trunk-configuration {
+      xr:xr-xml-map "vlan_interface_cfg:VLANTrunkConfiguration";
+      description "IEEE 802.1Q VLAN trunk interface configuration";
+
+      container native-vlan-identifier {
+        xr:xr-xml-map "vlan_interface_cfg:NativeVLANIdentifier";
+        presence "Indicates a native-vlan-identifier node is"+
+          " configured.";
+        description
+          "The Native VLAN identifier associated with this
+          trunk interface";
+        leaf vlan-type {
+          xr:xr-xml-map "vlan_interface_cfg:VlanType";
+          type dt1:Vlan;
+          mandatory true;
+          description "Whether this interface is dot1ad or dot1Q";
+        }
+        leaf vlan-identifier {
+          xr:xr-xml-map "vlan_interface_cfg:VLANIdentifier";
+          type dt1:Vlan-tag;
+          mandatory true;
+          description "VLAN identifier";
+        }
+      }
+      leaf tunneling-ethertype {
+        xr:xr-xml-map "vlan_interface_cfg:TunnelingEthertype";
+        type enumeration {
+          enum 0x9100 {
+            value 37120;
+            description "0x9100";
+          }
+          enum 0x9200 {
+            value 37376;
+            description "0x9200";
+          }
+        }
+        description
+          "The outer ethertype used in Q-in-Q frames. The
+          default value is 0x8100";
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-ifmgr-cfg'";
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration"+
+    "/a2:l2-transport" {
+
+    container l2-protocols {
+      xr:xr-xml-map "ether_l2pt_cfg:L2ProtocolTable";
+      description "Interface specific Layer 2 protocol handling";
+
+      list l2-protocol {
+        xr:xr-xml-map "ether_l2pt_cfg:L2Protocol";
+        key "l2-protocol-name";
+        description "Handling of a specific Layer 2 protocol";
+        leaf l2-protocol-name {
+          xr:xr-xml-map "ether_l2pt_cfg:L2ProtocolName";
+          type L2-protocol-name;
+          description "Protocol name";
+        }
+        leaf mode {
+          xr:xr-xml-map "ether_l2pt_cfg:Mode";
+          type L2-protocol-mode;
+          mandatory true;
+          description "How to handle the protocol's packets";
+        }
+        leaf mpls-exp-bits-value {
+          xr:xr-xml-map "ether_l2pt_cfg:MPLSExpBitsValue";
+          type L2-protocol-mpls-exp-bits-value;
+          description
+            "The value to set the MPLS Exp bits to within
+            the PW.This value may be specified if the mode
+            is forward or tunnel and must not be specified
+            if the mode is drop";
+        }
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-l2vpn-cfg'";
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration"+
+    "/a2:l2-transport" {
+    leaf propagate-remote-status {
+      xr:xr-xml-map "l2protocols_ether_interface_cfg:PropagateRemot"+
+        "eStatus";
+      type empty;
+      description
+        "Enable propagation of the remote
+        attachment-circuit link state to the
+        localattachment-circuit link state";
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-l2vpn-cfg'";
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration"+
+    "/a2:l2-transport" {
+
+    container l2-ethernet-features {
+      xr:xr-xml-map "ether_intf_feature_cfg:L2EthernetFeatures";
+      description "L2 Ethernet Features Configuration";
+      leaf egress-filtering {
+        xr:xr-xml-map "l2protocols_ether_interface_cfg:EgressFilter"+
+          "ing";
+        type Egress-filtering;
+        default "egress-filtering-type-default";
+        description "Egress Ethernet filtering";
+      }
+      leaf source-bypass-egress-filtering {
+        xr:xr-xml-map "l2protocols_ether_interface_cfg:SourceBypass"+
+          "EgressFiltering";
+        type empty;
+        description
+          "Mark all ingress packets to bypass any egress
+          VLAN filter";
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-l2vpn-cfg'";
+  }
+}
\ No newline at end of file
diff --git a/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-l2-eth-infra-datatypes@2015-11-09.yang b/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-l2-eth-infra-datatypes@2015-11-09.yang
new file mode 100644 (file)
index 0000000..3e9dd49
--- /dev/null
@@ -0,0 +1,204 @@
+module Cisco-IOS-XR-l2-eth-infra-datatypes {
+
+  /*** NAMESPACE / PREFIX DEFINITION ***/
+
+  namespace "http://cisco.com/ns/yang"+
+    "/Cisco-IOS-XR-l2-eth-infra-datatypes";
+
+
+  prefix "l2-eth-infra-datatypes";
+
+  /*** LINKAGE (IMPORTS / INCLUDES) ***/
+
+  /*** META INFORMATION ***/
+
+  organization "Cisco Systems, Inc.";
+
+  contact
+    "Cisco Systems, Inc.
+     Customer Service
+
+     Postal: 170 West Tasman Drive
+     San Jose, CA 95134
+
+     Tel: +1 800 553-NETS
+
+     E-mail: cs-yang@cisco.com";
+
+  description 
+    "This module contains a collection of generally useful
+     derived YANG data types.
+
+     Copyright (c) 2013-2015 by Cisco Systems, Inc.
+     All rights reserved.";
+
+  revision "2015-11-09" {
+    description
+      "IOS XR 6.0 revision.";
+  }
+
+  typedef Vlan-tag-or-cvp {
+    type union {
+      type enumeration {
+        enum native-with-cvlan-preservation {
+          value 65534;
+          description
+            "This is the Native VLAN and C-VLAN
+            preservation is enabled";
+        }
+      }
+      type uint32 {
+        range "1..65534";
+      }
+    }
+    description "Vlan tag or cvp";
+  }
+  typedef Class-of-service {
+    type uint32 {
+      range "0..7";
+    }
+    description "Class of service";
+  }
+  typedef Vlan {
+    type enumeration {
+      enum vlan-type-dot1ad {
+        value 1;
+        description "An 802.1ad VLAN";
+      }
+      enum vlan-type-dot1q {
+        value 2;
+        description "An 802.1q VLAN";
+      }
+    }
+    description "Vlan";
+  }
+  typedef Vlan-tag-or-native {
+    type union {
+      type enumeration {
+        enum native {
+          value 65535;
+          description "This is the Native VLAN";
+        }
+        enum native-with-cvlan-preservation {
+          value 65534;
+          description
+            "This is the Native VLAN and C-VLAN
+            preservation is enabled";
+        }
+      }
+      type uint32 {
+        range "1..65535";
+      }
+    }
+    description "Vlan tag or native";
+  }
+  typedef Vlan-tag-or-null {
+    type union {
+      type enumeration {
+        enum any {
+          value 0;
+          description "Match any inner VLAN tag value";
+        }
+      }
+      type uint32 {
+        range "0..4094";
+      }
+    }
+    description "Vlan tag or null";
+  }
+  typedef Rewrite {
+    type enumeration {
+      enum pop1 {
+        value 1;
+        description "Pop 1 tag";
+      }
+      enum pop2 {
+        value 2;
+        description "Pop 2 tags";
+      }
+      enum push1 {
+        value 3;
+        description "Push 1 tag";
+      }
+      enum push2 {
+        value 4;
+        description "Push 2 tags";
+      }
+      enum translate1to1 {
+        value 5;
+        description "Translate 1-to-1";
+      }
+      enum translate1to2 {
+        value 6;
+        description "Translate 1-to-2";
+      }
+      enum translate2to1 {
+        value 7;
+        description "Translate 2-to-1";
+      }
+      enum translate2to2 {
+        value 8;
+        description "Translate 2-to-2";
+      }
+    }
+    description "Rewrite";
+  }
+  typedef Match {
+    type enumeration {
+      enum match-default {
+        value 1;
+        description "All otherwise unmatched packets";
+      }
+      enum match-untagged {
+        value 2;
+        description "Untagged packets";
+      }
+      enum match-dot1q {
+        value 3;
+        description "Match Dot1Q tags";
+      }
+      enum match-dot1ad {
+        value 4;
+        description "Match Dot1ad tags";
+      }
+      enum match-dot1q-priority {
+        value 5;
+        description "Match Dot1Q priority-tagged packets";
+      }
+      enum match-dot1ad-priority {
+        value 6;
+        description "Match Dot1ad priority-tagged packets";
+      }
+    }
+    description "Match";
+  }
+  typedef Ethertype-match {
+    type enumeration {
+      enum ppp-over-ethernet {
+        value 34915;
+        description "PPP over Ethernet";
+      }
+    }
+    description "Ethertype match";
+  }
+  typedef Vlan-tag {
+    type uint32 {
+      range "1..4094";
+    }
+    description "Vlan tag";
+  }
+  typedef Vlan-tag-or-any {
+    type union {
+      type enumeration {
+        enum any {
+          value 4096;
+          description "Match any VLAN tag value";
+        }
+      }
+      type uint32 {
+        range "1..4096";
+      }
+    }
+    description "Vlan tag or any";
+  }
+}
\ No newline at end of file
diff --git a/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-l2vpn-cfg@2015-11-09.yang b/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-l2vpn-cfg@2015-11-09.yang
new file mode 100644 (file)
index 0000000..90eb2b3
--- /dev/null
@@ -0,0 +1,4892 @@
+module Cisco-IOS-XR-l2vpn-cfg {
+
+  /*** NAMESPACE / PREFIX DEFINITION ***/
+
+  namespace "http://cisco.com/ns/yang/Cisco-IOS-XR-l2vpn-cfg";
+
+
+  prefix "l2vpn-cfg";
+
+  /*** LINKAGE (IMPORTS / INCLUDES) ***/
+
+  import ietf-inet-types { prefix "inet"; }
+
+  import ietf-yang-types { prefix "yang"; }
+
+  import Cisco-IOS-XR-types { prefix "xr"; }
+
+  import Cisco-IOS-XR-ifmgr-cfg { prefix "a1"; }
+
+  import Cisco-IOS-XR-snmp-agent-cfg { prefix "a2"; }
+
+  /*** META INFORMATION ***/
+
+  organization "Cisco Systems, Inc.";
+
+  contact
+    "Cisco Systems, Inc.
+     Customer Service
+
+     Postal: 170 West Tasman Drive
+     San Jose, CA 95134
+
+     Tel: +1 800 553-NETS
+
+     E-mail: cs-yang@cisco.com";
+
+  description 
+    "This module contains a collection of YANG definitions
+     for Cisco IOS-XR l2vpn package configuration.
+
+     This module contains definitions
+     for the following management objects:
+       l2vpn: L2VPN configuration
+       generic-interface-lists: generic interface lists
+       evpn: evpn
+
+     This YANG module augments the
+       Cisco-IOS-XR-ifmgr-cfg,
+       Cisco-IOS-XR-snmp-agent-cfg
+     modules with configuration data.
+
+     Copyright (c) 2013-2015 by Cisco Systems, Inc.
+     All rights reserved.";
+
+  revision "2015-11-09" {
+    description
+      "IOS XR 6.0 revision.";
+  }
+
+  typedef Interworking {
+    type enumeration {
+      enum ethernet {
+        value 1;
+        description "Ethernet interworking";
+      }
+      enum ipv4 {
+        value 3;
+        description "IPv4 interworking";
+      }
+    }
+    description "Interworking";
+  }
+  typedef L2vpn-capability-mode {
+    type enumeration {
+      enum high-mode {
+        value 1;
+        description
+          "Compute global capability as the highest node
+          capability";
+      }
+      enum single-mode {
+        value 2;
+        description "Disable global capability re-computation";
+      }
+    }
+    description "L2vpn capability mode";
+  }
+  typedef Vpls-id-addr-index {
+    type uint32 {
+      range "0..32767";
+    }
+    description "Vpls id addr index";
+  }
+  typedef Tag-rewrite-range {
+    type uint32 {
+      range "1..4094";
+    }
+    description "Tag rewrite range";
+  }
+  typedef Evpnvpnid-range {
+    type uint32 {
+      range "1..65534";
+    }
+    description "Evpnvpnid range";
+  }
+  typedef Pseudowire-label-range {
+    type uint32 {
+      range "16..1048575";
+    }
+    description "Pseudowire label range";
+  }
+  typedef Bridge-domain-transport-mode {
+    type enumeration {
+      enum vlan-passthrough {
+        value 3;
+        description "Vlan tagged passthrough mode";
+      }
+    }
+    description "Bridge domain transport mode";
+  }
+  typedef Preferred-path {
+    type enumeration {
+      enum te-tunnel {
+        value 2;
+        description "TE Tunnel";
+      }
+      enum ip-tunnel {
+        value 3;
+        description "IP Tunnel";
+      }
+      enum tp-tunnel {
+        value 4;
+        description "TP Tunnel";
+      }
+    }
+    description "Preferred path";
+  }
+  typedef Rd-addr-index {
+    type uint32 {
+      range "0..65535";
+    }
+    description "Rd addr index";
+  }
+  typedef Vccv-verification {
+    type enumeration {
+      enum none {
+        value 0;
+        description "No connectivity verification over VCCV";
+      }
+      enum lsp-ping {
+        value 2;
+        description "LSP Ping over VCCV";
+      }
+    }
+    description "Vccv verification";
+  }
+  typedef L2vpn-mtu-range {
+    type uint32 {
+      range "64..65535";
+    }
+    description "L2vpn mtu range";
+  }
+  typedef Mac-withdraw-behavior {
+    type enumeration {
+      enum legacy {
+        value 1;
+        description "MAC Withdrawal sent on state-down (legacy)";
+      }
+      enum optimized {
+        value 2;
+        description "Optimized MAC Withdrawal";
+      }
+    }
+    description "Mac withdraw behavior";
+  }
+  typedef Port-down-flush {
+    type enumeration {
+      enum port-down-flush {
+        value 0;
+        description "MAC Port Down Flush";
+      }
+      enum enable-port-down-flush {
+        value 1;
+        description "Enable Port Down Flush";
+      }
+      enum disable-port-down-flush {
+        value 2;
+        description "Disable Port Down Flush";
+      }
+    }
+    description "Port down flush";
+  }
+  typedef Storm-control-pps-range {
+    type uint32 {
+      range "1..160000";
+    }
+    description "Storm control pps range";
+  }
+  typedef Type-of-service-mode {
+    type enumeration {
+      enum none {
+        value 0;
+        description "Do not reflect the type of service";
+      }
+      enum reflect {
+        value 1;
+        description "Reflect the type of service";
+      }
+    }
+    description "Type of service mode";
+  }
+  typedef Pseudowire-tag-range {
+    type uint32 {
+      range "1..4094";
+    }
+    description "Pseudowire tag range";
+  }
+  typedef Multicast-p2mp-signaling {
+    type string {
+      pattern "(BGP)";
+    }
+    description "BGP:BGP Signaling";
+  }
+  typedef Cedge-range {
+    type uint32 {
+      range "11..100";
+    }
+    description "Cedge range";
+  }
+  typedef Mpls-signaling-protocol {
+    type enumeration {
+      enum none {
+        value 1;
+        description "No signaling";
+      }
+      enum ldp {
+        value 4;
+        description "LDP";
+      }
+    }
+    description "Mpls signaling protocol";
+  }
+  typedef Erpaps {
+    type enumeration {
+      enum interface {
+        value 1;
+        description "ERP APS type interface";
+      }
+      enum bridge-domain {
+        value 2;
+        description "ERP APS type bridge domain";
+      }
+      enum xconnect {
+        value 3;
+        description "ERP APS type xconnect";
+      }
+      enum none {
+        value 4;
+        description "ERP APS type none";
+      }
+    }
+    description "Erpaps";
+  }
+  typedef Mac-secure-action {
+    type enumeration {
+      enum restrict {
+        value 1;
+        description "MAC Secure Action Restrict";
+      }
+      enum none {
+        value 2;
+        description "No Action";
+      }
+      enum shutdown {
+        value 3;
+        description "MAC Secure Action Shutdown";
+      }
+    }
+    description "Mac secure action";
+  }
+  typedef Erp-port {
+    type enumeration {
+      enum none {
+        value 1;
+        description "ERP port type none";
+      }
+      enum virtual {
+        value 2;
+        description "ERP port type virtual";
+      }
+      enum interface {
+        value 3;
+        description "ERP port type interface";
+      }
+    }
+    description "Erp port";
+  }
+  typedef Resync-threshold-range {
+    type uint32 {
+      range "5..65535";
+    }
+    description "Resync threshold range";
+  }
+  typedef Bgp-route-target-role {
+    type enumeration {
+      enum both {
+        value 0;
+        description "Both Import and export roles";
+      }
+      enum import {
+        value 1;
+        description "Import role";
+      }
+      enum export {
+        value 2;
+        description "Export role";
+      }
+    }
+    description "Bgp route target role";
+  }
+  typedef Backup-disable {
+    type enumeration {
+      enum never {
+        value 0;
+        description "Never";
+      }
+      enum delay {
+        value 1;
+        description "Delay seconds";
+      }
+    }
+    description "Backup disable";
+  }
+  typedef Time-to-live-range {
+    type uint32 {
+      range "1..255";
+    }
+    description "Time to live range";
+  }
+  typedef Multicast-p2mp-transport {
+    type string {
+      pattern "(RSVP_TE)";
+    }
+    description "RSVP_TE:RSVP-TE Transport";
+  }
+  typedef Transport-mode {
+    type enumeration {
+      enum ethernet {
+        value 1;
+        description "Ethernet port mode";
+      }
+      enum vlan {
+        value 2;
+        description "Vlan tagged mode";
+      }
+      enum vlan-passthrough {
+        value 3;
+        description "Vlan tagged passthrough mode";
+      }
+    }
+    description "Transport mode";
+  }
+  typedef Flow-label-tlv-code {
+    type enumeration {
+      enum 17 {
+        value 4;
+        description "Set Flow Label Legacy TLV code (DEPRECATED)";
+      }
+      enum disable {
+        value 8;
+        description "Disable Sending Flow Label Legacy TLV";
+      }
+    }
+    description "Flow label tlv code";
+  }
+  typedef Pseudowire-acid-range {
+    type uint32 {
+      range "1..4294967295";
+    }
+    description "Pseudowire acid range";
+  }
+  typedef Pseudowire-id-range {
+    type uint32 {
+      range "1..4294967295";
+    }
+    description "Pseudowire id range";
+  }
+  typedef Interface-profile {
+    type enumeration {
+      enum snoop {
+        value 1;
+        description "Set the snooping";
+      }
+      enum dhcp-protocol {
+        value 2;
+        description "disable DHCP protocol";
+      }
+    }
+    description "Interface profile";
+  }
+  typedef Rpl-role {
+    type enumeration {
+      enum owner {
+        value 1;
+        description "ERP RPL owner";
+      }
+      enum neighbor {
+        value 2;
+        description "ERP RPL neighbor";
+      }
+      enum next-neighbor {
+        value 3;
+        description "ERP RPL next neighbor";
+      }
+    }
+    description "Rpl role";
+  }
+  typedef Pw-switching-point-tlv {
+    type enumeration {
+      enum hide {
+        value 2;
+        description "Hide TLV";
+      }
+    }
+    description "Pw switching point tlv";
+  }
+  typedef Erpaps-level-range {
+    type uint32 {
+      range "0..7";
+    }
+    description "Erpaps level range";
+  }
+  typedef Storm-control {
+    type enumeration {
+      enum unicast {
+        value 1;
+        description "Unknown-unicast Storm Control";
+      }
+      enum multicast {
+        value 2;
+        description "Multicast Storm Control";
+      }
+      enum broadcast {
+        value 4;
+        description "Broadcast Storm Control";
+      }
+    }
+    description "Storm control";
+  }
+  typedef L2tp-session-id-range {
+    type uint32 {
+      range "1..65535";
+    }
+    description "L2tp session id range";
+  }
+  typedef Mac-learn {
+    type enumeration {
+      enum default-learning {
+        value 0;
+        description "Mac Learning";
+      }
+      enum enable-learning {
+        value 1;
+        description "Enable Learning";
+      }
+      enum disable-learning {
+        value 2;
+        description "Disable Learning";
+      }
+    }
+    description "Mac learn";
+  }
+  typedef L2tpv3-sequencing {
+    type enumeration {
+      enum off {
+        value 0;
+        description "Sequencing is off";
+      }
+      enum both {
+        value 4;
+        description "Sequencing on both transmit and receive side";
+      }
+    }
+    description "L2tpv3 sequencing";
+  }
+  typedef Veid-range {
+    type uint32 {
+      range "1..16384";
+    }
+    description "Veid range";
+  }
+  typedef Load-balance {
+    type enumeration {
+      enum source-dest-mac {
+        value 1;
+        description "Source and Destination MAC hashing";
+      }
+      enum source-dest-ip {
+        value 2;
+        description "Source and Destination IP hashing";
+      }
+      enum pseudowire-label {
+        value 4;
+        description "PW Label hashing";
+      }
+    }
+    description "Load balance";
+  }
+  typedef L2tp-signaling-protocol {
+    type enumeration {
+      enum none {
+        value 1;
+        description "No signaling";
+      }
+      enum l2tpv3 {
+        value 2;
+        description "L2TPv3";
+      }
+    }
+    description "L2tp signaling protocol";
+  }
+  typedef L2vpn-verification {
+    type enumeration {
+      enum enable {
+        value 1;
+        description "enable verification";
+      }
+      enum disable {
+        value 2;
+        description "disable verification";
+      }
+    }
+    description "L2vpn verification";
+  }
+  typedef Max-path-mtu-range {
+    type uint32 {
+      range "68..65535";
+    }
+    description "Max path mtu range";
+  }
+  typedef Interface-traffic-flood {
+    type enumeration {
+      enum traffic-flooding {
+        value 0;
+        description "Traffic flooding";
+      }
+      enum enable-flooding {
+        value 1;
+        description "Enable Flooding";
+      }
+      enum disable-flooding {
+        value 2;
+        description "Disable flooding";
+      }
+    }
+    description "Interface traffic flood";
+  }
+  typedef Pbbvid-range {
+    type uint32 {
+      range "1..4094";
+    }
+    description "Pbbvid range";
+  }
+  typedef L2tp-cookie-value-range {
+    type uint32 {
+      range "0..4294967295";
+    }
+    description "L2tp cookie value range";
+  }
+  typedef L2-encapsulation {
+    type enumeration {
+      enum vlan {
+        value 4;
+        description "Vlan tagged mode";
+      }
+      enum ethernet {
+        value 5;
+        description "Ethernet port mode";
+      }
+    }
+    description "L2 encapsulation";
+  }
+  typedef L2vpn-logging {
+    type enumeration {
+      enum enable {
+        value 1;
+        description "enable logging";
+      }
+      enum disable {
+        value 2;
+        description "disable logging";
+      }
+    }
+    description "L2vpn logging";
+  }
+  typedef Mac-aging-range {
+    type uint32 {
+      range "300..30000";
+    }
+    description "Mac aging range";
+  }
+  typedef Vpls-id-as-index {
+    type uint32 {
+      range "0..4294967295";
+    }
+    description "Vpls id as index";
+  }
+  typedef Pseudowire-gbl-id-range {
+    type uint32 {
+      range "1..4294967295";
+    }
+    description "Pseudowire gbl id range";
+  }
+  typedef Rdas-index {
+    type uint32 {
+      range "0..4294967295";
+    }
+    description "Rdas index";
+  }
+  typedef L2tp-cookie-size {
+    type enumeration {
+      enum zero {
+        value 0;
+        description "Cookie size is zero bytes";
+      }
+      enum four {
+        value 4;
+        description "Cookie size is four bytes";
+      }
+      enum eight {
+        value 8;
+        description "Cookie size is eight bytes";
+      }
+    }
+    description "L2tp cookie size";
+  }
+  typedef Mpls-sequencing {
+    type enumeration {
+      enum off {
+        value 0;
+        description "Sequencing is off";
+      }
+      enum transmit {
+        value 1;
+        description "Sequencing on transmit side";
+      }
+      enum receive {
+        value 2;
+        description "Sequencing on receive side";
+      }
+      enum both {
+        value 4;
+        description "Sequencing on both transmit and receive side";
+      }
+    }
+    description "Mpls sequencing";
+  }
+  typedef Erp-instance-range {
+    type uint32 {
+      range "1..2";
+    }
+    description "Erp instance range";
+  }
+  typedef Pw-redundancy-initial-delay-range {
+    type uint32 {
+      range "0..120";
+    }
+    description "Pw redundancy initial delay range";
+  }
+  typedef Vpls-id-as-range {
+    type uint32 {
+      range "1..65535";
+    }
+    description "Vpls id as range";
+  }
+  typedef Rdas-range {
+    type uint32 {
+      range "1..4294967295";
+    }
+    description "Rdas range";
+  }
+  typedef Bridge-bd-mtu-range {
+    type uint32 {
+      range "46..65535";
+    }
+    description "Bridge bd mtu range";
+  }
+  typedef Backup-disable-delay-range {
+    type uint32 {
+      range "0..180";
+    }
+    description "Backup disable delay range";
+  }
+  typedef Storm-control-kbps-range {
+    type uint32 {
+      range "64..1280000";
+    }
+    description "Storm control kbps range";
+  }
+  typedef Mac-limit-action {
+    type enumeration {
+      enum none {
+        value 0;
+        description "No action";
+      }
+      enum flood {
+        value 1;
+        description "Flood Mac Limit Action";
+      }
+      enum no-flood {
+        value 2;
+        description "NoFlood Mac Limit Action";
+      }
+      enum shutdown {
+        value 3;
+        description "Shutdown Mac Limit Action";
+      }
+    }
+    description "Mac limit action";
+  }
+  typedef Erp-port1 {
+    type enumeration {
+      enum port0 {
+        value 0;
+        description "ERP main port 0";
+      }
+      enum port1 {
+        value 1;
+        description "ERP main port 1";
+      }
+    }
+    description "Erp port1";
+  }
+  typedef Mac-notification {
+    type enumeration {
+      enum no-notif {
+        value 0;
+        description "No_Notification Trap";
+      }
+      enum syslog {
+        value 1;
+        description "syslog message";
+      }
+      enum trap {
+        value 2;
+        description "Snmp Trap";
+      }
+      enum syslog-snmp {
+        value 3;
+        description "Syslog_snmp Trap";
+      }
+    }
+    description "Mac notification";
+  }
+  typedef Control-word {
+    type enumeration {
+      enum enable {
+        value 1;
+        description "Enable control word";
+      }
+      enum disable {
+        value 2;
+        description "Disable control word";
+      }
+    }
+    description "Control word";
+  }
+  typedef Bgp-route-distinguisher {
+    type enumeration {
+      enum auto {
+        value 1;
+        description "RD automatically assigned";
+      }
+      enum two-byte-as {
+        value 2;
+        description "RD in 2 byte AS:nn format";
+      }
+      enum four-byte-as {
+        value 3;
+        description "RD in 4 byte AS:nn format";
+      }
+      enum ipv4-address {
+        value 4;
+        description "RD in IpV4address";
+      }
+    }
+    description "Bgp route distinguisher";
+  }
+  typedef Bgp-route-target-format {
+    type enumeration {
+      enum none {
+        value 0;
+        description "No route target";
+      }
+      enum two-byte-as {
+        value 1;
+        description "2 Byte AS:nn format";
+      }
+      enum four-byte-as {
+        value 2;
+        description "4 byte AS:nn format";
+      }
+      enum ipv4-address {
+        value 3;
+        description "IP:nn format";
+      }
+    }
+    description "Bgp route target format";
+  }
+  typedef Vedge-range {
+    type uint32 {
+      range "11..100";
+    }
+    description "Vedge range";
+  }
+  typedef Vpnid-range {
+    type uint32 {
+      range "1..4294967295";
+    }
+    description "Vpnid range";
+  }
+  typedef Ldp-vpls-id {
+    type enumeration {
+      enum two-byte-as {
+        value 10;
+        description "VPLS-ID in 2 byte AS:nn format";
+      }
+      enum ipv4-address {
+        value 266;
+        description "VPLS-ID in IPv4 IP:nn format";
+      }
+    }
+    description "Ldp vpls id";
+  }
+  typedef Ce-id-range {
+    type uint32 {
+      range "1..16384";
+    }
+    description "Ce id range";
+  }
+  typedef Mac-aging {
+    type enumeration {
+      enum absolute {
+        value 1;
+        description "Absolute aging type";
+      }
+      enum inactivity {
+        value 2;
+        description "Inactivity aging type";
+      }
+    }
+    description "Mac aging";
+  }
+  typedef Mac-limit-range {
+    type uint32 {
+      range "0..4294967295";
+    }
+    description "Mac limit range";
+  }
+  typedef Pbbisid-range {
+    type uint32 {
+      range "256..16777214";
+    }
+    description "Pbbisid range";
+  }
+  typedef Type-of-service-range {
+    type uint32 {
+      range "0..255";
+    }
+    description "Type of service range";
+  }
+  typedef Flow-label-load-balance {
+    type enumeration {
+      enum off {
+        value 0;
+        description "Flow Label load balance is off";
+      }
+      enum receive {
+        value 1;
+        description "Delete Flow Label on receive side";
+      }
+      enum transmit {
+        value 2;
+        description "Insert Flow Label on transmit side";
+      }
+      enum both {
+        value 3;
+        description
+          "Insert/Delete  Flow Label on transmit/receive
+          side";
+      }
+    }
+    description "Flow label load balance";
+  }
+
+  grouping STORM-CONTROL-UNIT {
+    description
+      "Common node of bd-storm-control,
+      bdac-storm-control-type, bdpw-storm-control-type";
+
+    container storm-control-unit {
+      xr:xr-xml-map "l2vpn_cfg:StormControlUnit";
+      description "Specify units for Storm Control Configuration";
+      leaf kbits-per-sec {
+        xr:xr-xml-map "l2vpn_cfg:KbitsPerSec";
+        type Storm-control-kbps-range;
+        units "kbit/s";
+        description
+          "Kilobits Per Second, PktsPerSec and KbitsPerSec
+          cannot be configured together";
+      }
+      leaf pkts-per-sec {
+        xr:xr-xml-map "l2vpn_cfg:PktsPerSec";
+        type Storm-control-pps-range;
+        units "packet/s";
+        description
+          "Packets Per Second, PktsPerSec and KbitsPerSec
+          cannot be configured together";
+      }
+    }
+  }
+
+  grouping EVPN-ROUTE-DISTINGUISHER {
+    description
+      "Common node of evpnbgp-auto-discovery,
+      evpnevibgp-auto-discovery, pw-routing-bgp";
+
+    container evpn-route-distinguisher {
+      xr:xr-xml-map "l2vpn_cfg:EVPNRouteDistinguisher";
+      description "Route Distinguisher";
+      leaf type {
+        xr:xr-xml-map "l2vpn_cfg:Type";
+        type Bgp-route-distinguisher;
+        description "Router Distinguisher Type";
+      }
+      leaf as {
+        xr:xr-xml-map "l2vpn_cfg:AS";
+        when "../type = 'two-byte-as' or ../type = 'four-byte-as'" {
+          description "../Type = TwoByteAS or ../Type = FourByteAS";
+        }
+        type Rdas-range;
+        description "Two byte or 4 byte AS number";
+      }
+      leaf as-index {
+        xr:xr-xml-map "l2vpn_cfg:ASIndex";
+        when "../type = 'two-byte-as' or ../type = 'four-byte-as'" {
+          description "../Type = TwoByteAS or ../Type = FourByteAS";
+        }
+        type Rdas-index;
+        description "AS:nn (hex or decimal format)";
+      }
+      leaf address {
+        xr:xr-xml-map "l2vpn_cfg:Address";
+        when "../type = 'ipv4-address'" {
+          description "../Type = IPV4Address";
+        }
+        type inet:ipv4-address-no-zone;
+        description "IPV4 address";
+      }
+      leaf addr-index {
+        xr:xr-xml-map "l2vpn_cfg:AddrIndex";
+        when "../type = 'ipv4-address'" {
+          description "../Type = IPV4Address";
+        }
+        type Rd-addr-index;
+        description "Addr index";
+      }
+    }
+  }
+
+  container l2vpn {
+    xr:xr-xml-map "l2vpn_cfg:L2VPN";
+    description "L2VPN configuration";
+
+    container pw-routing {
+      xr:xr-xml-map "l2vpn_cfg:PWRouting";
+      description "Pseudowire-routing attributes";
+
+      container pw-routing-bgp {
+        xr:xr-xml-map "l2vpn_cfg:PWRoutingBGP";
+        description
+          "Enable Autodiscovery BGP Pseudowire-routing BGP";
+        leaf enable {
+          xr:xr-xml-map "l2vpn_cfg:Enable";
+          type empty;
+          description "Enable Autodiscovery BGP";
+        }
+        uses EVPN-ROUTE-DISTINGUISHER;
+      }
+      leaf pw-routing-global-id {
+        xr:xr-xml-map "l2vpn_cfg:PWRoutingGlobalID";
+        xr:xr-cli-map "l2vpn pw-routing global-id <number> ";
+        type Pseudowire-gbl-id-range;
+        description "Pseudowire-routing Global ID";
+      }
+    }
+
+    container neighbor {
+      xr:xr-xml-map "l2vpn_cfg:Neighbor";
+      description "L2VPN neighbor submode";
+      leaf ldp-flap {
+        xr:xr-xml-map "l2vpn_cfg:LDPFlap";
+        xr:xr-cli-map "l2vpn neighbor all ldp flap ";
+        type empty;
+        description "Enable targetted LDP session flap action";
+      }
+    }
+
+    container database {
+      xr:xr-xml-map "l2vpn_cfg:Database";
+      description "L2VPN databases";
+
+      container g8032-rings {
+        xr:xr-xml-map "l2vpn_cfg:G8032RingTable";
+        description "List of G8032 Ring";
+
+        list g8032-ring {
+          xr:xr-xml-map "l2vpn_cfg:G8032Ring";
+          key "g8032-ring-name";
+          description "G8032 Ring";
+
+          container erp-port0s {
+            xr:xr-xml-map "l2vpn_cfg:ERPPort0Table";
+            description "Ethernet ring protection port0";
+
+            list erp-port0 {
+              xr:xr-xml-map "l2vpn_cfg:ERPPort0";
+              key "interface-name";
+              description "Configure ERP main port0";
+              leaf monitor {
+                xr:xr-xml-map "l2vpn_cfg:Monitor";
+                xr:xr-cli-map "l2vpn ethernet ring g8032 <string> p"+
+                  "ort0 interface <interface> monitor interface <in"+
+                  "terface> ";
+                type xr:Interface-name;
+                description
+                  "Ethernet ring protection port0 monitor";
+              }
+              leaf interface-name {
+                xr:xr-xml-map "l2vpn_cfg:InterfaceName";
+                type xr:Interface-name;
+                description "Port0 interface";
+              }
+            }
+          }
+
+          container erp-instances {
+            xr:xr-xml-map "l2vpn_cfg:ERPInstanceTable";
+            description "List of ethernet ring protection instance";
+
+            list erp-instance {
+              xr:xr-xml-map "l2vpn_cfg:ERPInstance";
+              key "erp-instance-id";
+              description "Ethernet ring protection instance";
+
+              container rpl {
+                xr:xr-xml-map "l2vpn_cfg:RPL";
+                description "Ring protection link";
+                leaf port {
+                  xr:xr-xml-map "l2vpn_cfg:Port";
+                  type Erp-port1;
+                  description "ERP main port number";
+                }
+                leaf role {
+                  xr:xr-xml-map "l2vpn_cfg:Role";
+                  type Rpl-role;
+                  description "RPL role";
+                }
+              }
+
+              container aps {
+                xr:xr-xml-map "l2vpn_cfg:APS";
+                description "Automatic protection switching";
+
+                container port1 {
+                  xr:xr-xml-map "l2vpn_cfg:Port1";
+                  description "APS channel for ERP port1";
+                  leaf aps-type {
+                    xr:xr-xml-map "l2vpn_cfg:APSType";
+                    type Erpaps;
+                    description "Port1 APS type";
+                  }
+                  leaf aps-channel {
+                    xr:xr-xml-map "l2vpn_cfg:APSChannel";
+                    type string;
+                    description
+                      "Port1 APS channel in the format of
+                      InterfaceName, BDName or XconnectName";
+                  }
+                }
+                leaf port0 {
+                  xr:xr-xml-map "l2vpn_cfg:Port0";
+                  xr:xr-cli-map "port0 interface <interface> ";
+                  type string;
+                  description
+                    "Port0 APS channel in the format of
+                    InterfaceName";
+                }
+                leaf enable {
+                  xr:xr-xml-map "l2vpn_cfg:Enable";
+                  type empty;
+                  description
+                    "Enable automatic protection switching";
+                }
+                leaf level {
+                  xr:xr-xml-map "l2vpn_cfg:Level";
+                  xr:xr-cli-map "level <number> ";
+                  type Erpaps-level-range;
+                  description
+                    "Automatic protection switching level";
+                }
+              }
+              leaf description {
+                xr:xr-xml-map "l2vpn_cfg:Description";
+                xr:xr-cli-map "description <string> ";
+                type string {
+                  length "0..32";
+                }
+                description
+                  "Ethernet ring protection instance
+                  description";
+              }
+              leaf inclusion-list {
+                xr:xr-xml-map "l2vpn_cfg:InclusionList";
+                xr:xr-cli-map "inclusion-list vlan-ids <string> ";
+                type string;
+                description
+                  "Associates a set of VLAN IDs with the G
+                  .8032 instance";
+              }
+              leaf profile {
+                xr:xr-xml-map "l2vpn_cfg:Profile";
+                xr:xr-cli-map "profile <string> ";
+                type string {
+                  length "0..32";
+                }
+                description
+                  "Ethernet ring protection instance profile";
+              }
+              leaf erp-instance-id {
+                xr:xr-xml-map "l2vpn_cfg:ERPInstanceID";
+                type Erp-instance-range;
+                description "ERP instance number";
+              }
+            }
+          }
+
+          container erp-port1s {
+            xr:xr-xml-map "l2vpn_cfg:ERPPort1Table";
+            description "Ethernet ring protection port0";
+
+            list erp-port1 {
+              xr:xr-xml-map "l2vpn_cfg:ERPPort1";
+              must "none or virtual-or-interface" {
+                description
+                  "None or Virtual-or-Interface must be
+                  present.";
+              }
+              key "erp-port-type";
+              description "Ethernet ring protection port1";
+
+              grouping ERP-PORT1-CONTENT {
+                description "ERP PORT1 CONTENT";
+                leaf monitor {
+                  type xr:Interface-name;
+                  description
+                    "Ethernet ring protection port1 monitor";
+                }
+              }
+
+              container none {
+                xr:xr-xml-map "l2vpn_cfg:Monitor";
+                when "../erp-port-type = 'none'" {
+                  description "../ERPPortType = None";
+                }
+                presence "Indicates that this node is configured.";
+                description "none";
+                uses ERP-PORT1-CONTENT;
+              }
+              leaf erp-port-type {
+                xr:xr-xml-map "l2vpn_cfg:ERPPortType";
+                type Erp-port;
+                description "Port1 type";
+              }
+
+              list virtual-or-interface {
+                xr:xr-xml-map "l2vpn_cfg:Monitor";
+                when "../erp-port-type = 'virtual' or"+
+                  " ../erp-port-type = 'interface'" {
+                    description
+                      "../ERPPortType = Virtual or .
+                      ./ERPPortType = Interface";
+                }
+                key "interface-name";
+                description "virtual or interface";
+                leaf interface-name {
+                  xr:xr-xml-map "l2vpn_cfg:InterfaceName";
+                  type xr:Interface-name;
+                  description "Port1 interface";
+                }
+                uses ERP-PORT1-CONTENT;
+              }
+            }
+          }
+          leaf open-ring {
+            xr:xr-xml-map "l2vpn_cfg:OpenRing";
+            xr:xr-cli-map "l2vpn ethernet ring g8032 <string> open-"+
+              "ring ";
+            type empty;
+            description "Specify the G.8032 instance as open ring";
+          }
+          leaf exclusion-list {
+            xr:xr-xml-map "l2vpn_cfg:ExclusionList";
+            xr:xr-cli-map "l2vpn ethernet ring g8032 <string> exclu"+
+              "sion-list vlan-ids <string> ";
+            type string;
+            description
+              "Vlan IDs in the format of a-b,c,d,e-f,g
+              ,untagged";
+          }
+          leaf erp-provider-bridge {
+            xr:xr-xml-map "l2vpn_cfg:ERPProviderBridge";
+            type empty;
+            description "Ethernet ring protection provider bridge";
+          }
+          leaf g8032-ring-name {
+            xr:xr-xml-map "l2vpn_cfg:G8032RingName";
+            type xr:Cisco-ios-xr-string {
+              length "0..32";
+            }
+            description "Name of the G8032 ring";
+          }
+        }
+      }
+
+      container xconnect-groups {
+        xr:xr-xml-map "l2vpn_cfg:XConnectGroupTable";
+        description "List of xconnect groups";
+
+        list xconnect-group {
+          xr:xr-xml-map "l2vpn_cfg:XConnectGroup";
+          key "name";
+          description "Xconnect group";
+
+          container p2p-xconnects {
+            xr:xr-xml-map "l2vpn_cfg:P2PXConnectTable";
+            description "List of point to point xconnects";
+
+            list p2p-xconnect {
+              xr:xr-xml-map "l2vpn_cfg:P2PXConnect";
+              key "name";
+              description "Point to point xconnect";
+
+              container backup-attachment-circuits {
+                xr:xr-xml-map "l2vpn_cfg:BackupAttachmentCircuitTab"+
+                  "le";
+                description "List of backup attachment circuits";
+
+                list backup-attachment-circuit {
+                  xr:xr-xml-map "l2vpn_cfg:BackupAttachmentCircuit";
+                  key "interface-name";
+                  description "Backup attachment circuit";
+                  leaf interface-name {
+                    xr:xr-xml-map "l2vpn_cfg:InterfaceName";
+                    type xr:Interface-name;
+                    description
+                      "Name of the attachment circuit interface";
+                  }
+                }
+              }
+
+              container pseudowire-evpns {
+                xr:xr-xml-map "l2vpn_cfg:PseudowireEvpnTable";
+                description "List of EVPN Services";
+
+                list pseudowire-evpn {
+                  xr:xr-xml-map "l2vpn_cfg:PseudowireEvpn";
+                  key "eviid remote-acid source-acid";
+                  description "EVPN P2P Service Configuration";
+                  leaf eviid {
+                    xr:xr-xml-map "l2vpn_cfg:EVIID";
+                    type Evpnvpnid-range;
+                    description "Ethernet VPN ID";
+                  }
+                  leaf remote-acid {
+                    xr:xr-xml-map "l2vpn_cfg:RemoteACID";
+                    type Pseudowire-acid-range;
+                    description "Remote AC ID";
+                  }
+                  leaf source-acid {
+                    xr:xr-xml-map "l2vpn_cfg:SourceACID";
+                    type Pseudowire-acid-range;
+                    description "Source AC ID";
+                  }
+                }
+              }
+
+              container pseudowires {
+                xr:xr-xml-map "l2vpn_cfg:PseudowireTable";
+                description "List of pseudowires";
+
+                list pseudowire {
+                  must "pseudowire-address or neighbor" {
+                    description
+                      "pseudowire-address or neighbor must be
+                      present.";
+                  }
+                  key "pseudowire-id";
+                  description "Pseudowire configuration";
+
+                  grouping PSEUDOWIRE-CONTENT {
+                    description "Content grouping.";
+
+                    container mpls-static-labels {
+                      xr:xr-xml-map "l2vpn_cfg:MPLSStaticLabels";
+                      description "MPLS static labels";
+                      leaf local-static-label {
+                        xr:xr-xml-map "l2vpn_cfg:LocalStaticLabel";
+                        type Pseudowire-label-range;
+                        description "Pseudowire local static label";
+                      }
+                      leaf remote-static-label {
+                        xr:xr-xml-map "l2vpn_cfg:RemoteStaticLabel";
+                        type Pseudowire-label-range;
+                        description
+                          "Pseudowire remote static label";
+                      }
+                    }
+
+                    container backup-pseudowires {
+                      xr:xr-xml-map "l2vpn_cfg:BackupPseudowireTabl"+
+                        "e";
+                      description "List of pseudowires";
+
+                      list backup-pseudowire {
+                        xr:xr-xml-map "l2vpn_cfg:BackupPseudowire";
+                        key "neighbor pseudowire-id";
+                        description
+                          "Backup pseudowire for the cross connect";
+
+                        container backup-mpls-static-labels {
+                          xr:xr-xml-map "l2vpn_cfg:BackupMPLSStatic"+
+                            "Labels";
+                          description "MPLS static labels";
+                          leaf local-static-label {
+                            xr:xr-xml-map "l2vpn_cfg:LocalStaticLab"+
+                              "el";
+                            type Pseudowire-label-range;
+                            description
+                              "Pseudowire local static label";
+                          }
+                          leaf remote-static-label {
+                            xr:xr-xml-map "l2vpn_cfg:RemoteStaticLa"+
+                              "bel";
+                            type Pseudowire-label-range;
+                            description
+                              "Pseudowire remote static label";
+                          }
+                        }
+                        leaf backup-pw-class {
+                          xr:xr-xml-map "l2vpn_cfg:BackupPWClass";
+                          type xr:Cisco-ios-xr-string {
+                            length "0..32";
+                          }
+                          description
+                            "PW class template name to use for the
+                            backup PW";
+                        }
+                        leaf neighbor {
+                          xr:xr-xml-map "l2vpn_cfg:Neighbor";
+                          type inet:ipv4-address-no-zone;
+                          description "Neighbor IP address";
+                        }
+                        leaf pseudowire-id {
+                          xr:xr-xml-map "l2vpn_cfg:PseudowireID";
+                          type Pseudowire-id-range;
+                          description "Pseudowire ID";
+                        }
+                      }
+                    }
+
+                    container l2tp-static-attributes {
+                      xr:xr-xml-map "l2vpn_cfg:L2TPStaticAttributes";
+                      description "L2TP Static Attributes";
+
+                      container l2tp-remote-cookie {
+                        xr:xr-xml-map "l2vpn_cfg:L2TPRemoteCookie";
+                        description "L2TP remote cookie";
+                        leaf size {
+                          xr:xr-xml-map "l2vpn_cfg:Size";
+                          type L2tp-cookie-size;
+                          description "Remote cookie size";
+                        }
+                        leaf lower-value {
+                          xr:xr-xml-map "l2vpn_cfg:LowerValue";
+                          type L2tp-cookie-value-range;
+                          description "Lower remote cookie value";
+                        }
+                        leaf higher-value {
+                          xr:xr-xml-map "l2vpn_cfg:HigherValue";
+                          type L2tp-cookie-value-range;
+                          description "Higher remote cookie value";
+                        }
+                      }
+
+                      container l2tp-secondary-local-cookie {
+                        xr:xr-xml-map "l2vpn_cfg:L2TPSecondaryLocal"+
+                          "Cookie";
+                        description "L2TP secondary local cookie";
+                        leaf size {
+                          xr:xr-xml-map "l2vpn_cfg:Size";
+                          type L2tp-cookie-size;
+                          description "Local cookie size";
+                        }
+                        leaf lower-value {
+                          xr:xr-xml-map "l2vpn_cfg:LowerValue";
+                          type L2tp-cookie-value-range;
+                          description "Lower local cookie value";
+                        }
+                        leaf higher-value {
+                          xr:xr-xml-map "l2vpn_cfg:HigherValue";
+                          type L2tp-cookie-value-range;
+                          description "Higher local cookie value";
+                        }
+                      }
+
+                      container l2tp-local-cookie {
+                        xr:xr-xml-map "l2vpn_cfg:L2TPLocalCookie";
+                        description "L2TP local cookie";
+                        leaf size {
+                          xr:xr-xml-map "l2vpn_cfg:Size";
+                          type L2tp-cookie-size;
+                          description "Local cookie size";
+                        }
+                        leaf lower-value {
+                          xr:xr-xml-map "l2vpn_cfg:LowerValue";
+                          type L2tp-cookie-value-range;
+                          description "Lower local cookie value";
+                        }
+                        leaf higher-value {
+                          xr:xr-xml-map "l2vpn_cfg:HigherValue";
+                          type L2tp-cookie-value-range;
+                          description "Higher local cookie value";
+                        }
+                      }
+                      leaf l2tp-remote-session-id {
+                        xr:xr-xml-map "l2vpn_cfg:L2TPRemoteSessionI"+
+                          "D";
+                        type L2tp-session-id-range;
+                        description "L2TP remote session ID";
+                      }
+                      leaf l2tp-local-session-id {
+                        xr:xr-xml-map "l2vpn_cfg:L2TPLocalSessionID";
+                        type L2tp-session-id-range;
+                        description "L2TP local session ID";
+                      }
+                    }
+
+                    container l2tp-static {
+                      xr:xr-xml-map "l2vpn_cfg:L2TPStatic";
+                      description
+                        "Pseudowire L2TPv3 static configuration";
+                      leaf enable {
+                        xr:xr-xml-map "l2vpn_cfg:Enable";
+                        type empty;
+                        description
+                          "Enable pseudowire L2TPv3 static
+                          configuration";
+                      }
+                    }
+                    leaf tag-impose {
+                      xr:xr-xml-map "l2vpn_cfg:TagImpose";
+                      type Pseudowire-tag-range;
+                      description "Tag Impose vlan tagged mode";
+                    }
+                    leaf class {
+                      xr:xr-xml-map "l2vpn_cfg:Class";
+                      type xr:Cisco-ios-xr-string {
+                        length "0..32";
+                      }
+                      description "Name of the pseudowire class";
+                    }
+                    leaf source-address {
+                      xr:xr-xml-map "l2vpn_cfg:SourceAddress";
+                      type inet:ip-address-no-zone;
+                      description
+                        "Value of the Pseudowire source address.
+                        Must be IPv6 only.";
+                    }
+                    leaf bandwidth {
+                      xr:xr-xml-map "l2vpn_cfg:Bandwidth";
+                      type uint32 {
+                        range "0..4294967295";
+                      }
+                      description "Pseudowire Bandwidth";
+                    }
+                  }
+                  leaf pseudowire-id {
+                    xr:xr-xml-map "l2vpn_cfg:PseudowireID";
+                    type Pseudowire-id-range;
+                    description "Pseudowire ID";
+                  }
+
+                  list neighbor {
+                    xr:xr-xml-map "l2vpn_cfg:Pseudowire";
+                    key "neighbor";
+                    description "keys: neighbor";
+                    leaf neighbor {
+                      xr:xr-xml-map "l2vpn_cfg:Neighbor";
+                      type inet:ipv4-address-no-zone;
+                      description "Pseudowire IPv4 address";
+                    }
+                    uses PSEUDOWIRE-CONTENT;
+                  }
+
+                  list pseudowire-address {
+                    xr:xr-xml-map "l2vpn_cfg:Pseudowire";
+                    key "pseudowire-address";
+                    description "keys: pseudowire-address";
+                    leaf pseudowire-address {
+                      xr:xr-xml-map "l2vpn_cfg:PseudowireAddress";
+                      type inet:ipv6-address-no-zone;
+                      description
+                        "Pseudowire IPv6 address. A pseudowire
+                        can have only one address: IPv4 or IPv6";
+                    }
+                    uses PSEUDOWIRE-CONTENT;
+                  }
+                }
+              }
+
+              container monitor-sessions {
+                xr:xr-xml-map "l2vpn_cfg:MonitorSessionTable";
+                description "List of Monitor session segments";
+
+                list monitor-session {
+                  xr:xr-xml-map "l2vpn_cfg:MonitorSession";
+                  key "name";
+                  description "Monitor session segment";
+                  leaf enable {
+                    xr:xr-xml-map "l2vpn_cfg:Enable";
+                    xr:xr-cli-map "l2vpn xconnect group <string> p2"+
+                      "p <string> monitor-session <string> ";
+                    type empty;
+                    description "Enable monitor session segment ";
+                  }
+                  leaf name {
+                    xr:xr-xml-map "l2vpn_cfg:Name";
+                    type xr:Cisco-ios-xr-string {
+                      length "0..64";
+                    }
+                    description "Name of the monitor session";
+                  }
+                }
+              }
+
+              container pseudowire-routeds {
+                xr:xr-xml-map "l2vpn_cfg:PseudowireRoutedTable";
+                description "List of pseudowire-routed";
+
+                list pseudowire-routed {
+                  xr:xr-xml-map "l2vpn_cfg:PseudowireRouted";
+                  key "global-id prefix acid sacid";
+                  description "Pseudowire configuration";
+                  leaf tag-impose {
+                    xr:xr-xml-map "l2vpn_cfg:TagImpose";
+                    xr:xr-cli-map "tag-impose [vlan <number>] ";
+                    type Pseudowire-tag-range;
+                    description "Tag Impose vlan tagged mode";
+                  }
+                  leaf class {
+                    xr:xr-xml-map "l2vpn_cfg:Class";
+                    xr:xr-cli-map "pw-class <string> ";
+                    type xr:Cisco-ios-xr-string {
+                      length "0..32";
+                    }
+                    description "Name of the pseudowire class";
+                  }
+                  leaf global-id {
+                    xr:xr-xml-map "l2vpn_cfg:GlobalID";
+                    type Pseudowire-gbl-id-range;
+                    description "Target Global ID";
+                  }
+                  leaf prefix {
+                    xr:xr-xml-map "l2vpn_cfg:Prefix";
+                    type inet:ipv4-address-no-zone;
+                    description "Target Prefix";
+                  }
+                  leaf acid {
+                    xr:xr-xml-map "l2vpn_cfg:ACID";
+                    type Pseudowire-acid-range;
+                    description "Target AC ID";
+                  }
+                  leaf sacid {
+                    xr:xr-xml-map "l2vpn_cfg:SACID";
+                    type Pseudowire-acid-range;
+                    description "Source AC ID";
+                  }
+                }
+              }
+
+              container attachment-circuits {
+                xr:xr-xml-map "l2vpn_cfg:AttachmentCircuitTable";
+                description "List of attachment circuits";
+
+                list attachment-circuit {
+                  xr:xr-xml-map "l2vpn_cfg:AttachmentCircuit";
+                  key "name";
+                  description "Attachment circuit interface";
+                  leaf enable {
+                    xr:xr-xml-map "l2vpn_cfg:Enable";
+                    xr:xr-cli-map "l2vpn xconnect group <string> p2"+
+                      "p <string> interface (<interface>)|(<interfa"+
+                      "ce>) ";
+                    type empty;
+                    description
+                      "Enable attachment circuit interface";
+                  }
+                  leaf name {
+                    xr:xr-xml-map "l2vpn_cfg:Name";
+                    type xr:Interface-name;
+                    description
+                      "Name of the attachment circuit interface";
+                  }
+                }
+              }
+              leaf p2p-description {
+                xr:xr-xml-map "l2vpn_cfg:P2PDescription";
+                xr:xr-cli-map "l2vpn xconnect group <string> p2p <s"+
+                  "tring> description <string> ";
+                type xr:Cisco-ios-xr-string {
+                  length "0..64";
+                }
+                description "cross connect description Name";
+              }
+              leaf interworking {
+                xr:xr-xml-map "l2vpn_cfg:Interworking";
+                xr:xr-cli-map "l2vpn xconnect group <string> p2p <s"+
+                  "tring> interworking (ipv4)|(ethernet) ";
+                type Interworking;
+                description "Interworking";
+              }
+              leaf name {
+                xr:xr-xml-map "l2vpn_cfg:Name";
+                type xr:Cisco-ios-xr-string {
+                  length "0..38";
+                }
+                description "Name of the point to point xconnect";
+              }
+            }
+          }
+
+          container mp2mp-xconnects {
+            xr:xr-xml-map "l2vpn_cfg:MP2MPXConnectTable";
+            description
+              "List of multi point to multi point xconnects";
+
+            list mp2mp-xconnect {
+              xr:xr-xml-map "l2vpn_cfg:MP2MPXConnect";
+              key "name";
+              description "Multi point to multi point xconnect";
+
+              container mp2mp-auto-discovery {
+                xr:xr-xml-map "l2vpn_cfg:MP2MPAutoDiscovery";
+                description "auto-discovery in this MP2MP";
+
+                container route-distinguisher {
+                  xr:xr-xml-map "l2vpn_cfg:RouteDistinguisher";
+                  description "Route Distinguisher";
+                  leaf type {
+                    xr:xr-xml-map "l2vpn_cfg:Type";
+                    type Bgp-route-distinguisher;
+                    description "Router distinguisher type";
+                  }
+                  leaf as {
+                    xr:xr-xml-map "l2vpn_cfg:AS";
+                    when "../type = 'two-byte-as' or ../type ="+
+                      " 'four-byte-as'" {
+                        description
+                          "../Type = TwoByteAS or ../Type =
+                          FourByteAS";
+                    }
+                    type Rdas-range;
+                    description "Two byte or 4 byte AS number";
+                  }
+                  leaf as-index {
+                    xr:xr-xml-map "l2vpn_cfg:ASIndex";
+                    when "../type = 'two-byte-as' or ../type ="+
+                      " 'four-byte-as'" {
+                        description
+                          "../Type = TwoByteAS or ../Type =
+                          FourByteAS";
+                    }
+                    type Rdas-index;
+                    description "AS:nn (hex or decimal format)";
+                  }
+                  leaf address {
+                    xr:xr-xml-map "l2vpn_cfg:Address";
+                    when "../type = 'ipv4-address'" {
+                      description "../Type = IPV4Address";
+                    }
+                    type inet:ipv4-address-no-zone;
+                    description "IPV4 address";
+                  }
+                  leaf addr-index {
+                    xr:xr-xml-map "l2vpn_cfg:AddrIndex";
+                    when "../type = 'ipv4-address'" {
+                      description "../Type = IPV4Address";
+                    }
+                    type Rd-addr-index;
+                    description "Addr index";
+                  }
+                }
+
+                container mp2mp-route-targets {
+                  xr:xr-xml-map "l2vpn_cfg:MP2MPRouteTargetTable";
+                  description "Route Target";
+
+                  list mp2mp-route-target {
+                    xr:xr-xml-map "l2vpn_cfg:MP2MPRouteTarget";
+                    must "two-byte-as-or-four-byte-as or"+
+                      " ipv4-address" {
+                      description
+                        "TwoByteAS-or-FourbyteAS or IPV4Address
+                        must be present.";
+                    }
+                    key "role format";
+                    description "Name of the Route Target";
+                    leaf role {
+                      xr:xr-xml-map "l2vpn_cfg:Role";
+                      type Bgp-route-target-role;
+                      description "Role of the router target type";
+                    }
+                    leaf format {
+                      xr:xr-xml-map "l2vpn_cfg:Format";
+                      type Bgp-route-target-format;
+                      description "Format of the route target";
+                    }
+
+                    list two-byte-as-or-four-byte-as {
+                      when "../format = 'two-byte-as' or"+
+                        " ../format = 'four-byte-as'" {
+                          description
+                            "../Format = TwoByteAS or ../Format =
+                            FourbyteAS";
+                      }
+                      key "as as-index";
+                      description "two byte as or four byte as";
+                      leaf as {
+                        xr:xr-xml-map "l2vpn_cfg:AS";
+                        type Rdas-range;
+                        description "Two byte or 4 byte AS number";
+                      }
+                      leaf as-index {
+                        xr:xr-xml-map "l2vpn_cfg:ASIndex";
+                        type Rdas-index;
+                        description "AS:nn (hex or decimal format)";
+                      }
+                    }
+
+                    list ipv4-address {
+                      when "../format = 'ipv4-address'" {
+                        description "../Format = IPV4Address";
+                      }
+                      key "address addr-index";
+                      description "ipv4 address";
+                      leaf address {
+                        xr:xr-xml-map "l2vpn_cfg:Address";
+                        type inet:ipv4-address-no-zone;
+                        description "IPV4 address";
+                      }
+                      leaf addr-index {
+                        xr:xr-xml-map "l2vpn_cfg:AddrIndex";
+                        type Rd-addr-index;
+                        description "Addr index";
+                      }
+                    }
+                  }
+                }
+
+                container mp2mp-signaling-protocol {
+                  xr:xr-xml-map "l2vpn_cfg:MP2MPSignalingProtocol";
+                  description "signaling protocol in this MP2MP";
+
+                  container flow-label-load-balance {
+                    xr:xr-xml-map "l2vpn_cfg:FlowLabelLoadBalance";
+                    description
+                      "Enable Flow Label based load balancing";
+                    leaf flow-label {
+                      xr:xr-xml-map "l2vpn_cfg:FlowLabel";
+                      type Flow-label-load-balance;
+                      description "Flow Label load balance type";
+                    }
+                    leaf static {
+                      xr:xr-xml-map "l2vpn_cfg:Static";
+                      type empty;
+                      description "Static Flow Label";
+                    }
+                  }
+
+                  container ceids {
+                    xr:xr-xml-map "l2vpn_cfg:CEIDTable";
+                    description
+                      "Local Customer Edge Identifier Table";
+
+                    list ceid {
+                      xr:xr-xml-map "l2vpn_cfg:CEID";
+                      key "ce-id";
+                      description "Local Customer Edge Identifier ";
+
+                      container remote-ceid-attachment-circuits {
+                        xr:xr-xml-map "l2vpn_cfg:RemoteCEIDAttachme"+
+                          "ntCircuitTable";
+                        description
+                          "AC And Remote Customer Edge Identifier
+                          Table";
+
+                        list remote-ceid-attachment-circuit {
+                          xr:xr-xml-map "l2vpn_cfg:RemoteCEIDAttach"+
+                            "mentCircuit";
+                          key "name remote-ce-id";
+                          description
+                            "AC And Remote Customer Edge Identifier";
+                          leaf name {
+                            xr:xr-xml-map "l2vpn_cfg:Name";
+                            type xr:Interface-name;
+                            description
+                              "The name of the Attachment Circuit";
+                          }
+                          leaf remote-ce-id {
+                            xr:xr-xml-map "l2vpn_cfg:RemoteCeId";
+                            type Ce-id-range;
+                            description
+                              "Remote Customer Edge Identifier";
+                          }
+                        }
+                      }
+                      leaf ce-id {
+                        xr:xr-xml-map "l2vpn_cfg:CEId";
+                        type Ce-id-range;
+                        description
+                          "Local Customer Edge Identifier";
+                      }
+                    }
+                  }
+                  leaf ce-range {
+                    xr:xr-xml-map "l2vpn_cfg:CERange";
+                    xr:xr-cli-map "ce-range <number> ";
+                    type Cedge-range;
+                    description "Local Customer Edge Identifier";
+                  }
+                  leaf enable {
+                    xr:xr-xml-map "l2vpn_cfg:Enable";
+                    type empty;
+                    description "Enable signaling protocol";
+                  }
+                }
+                leaf enable {
+                  xr:xr-xml-map "l2vpn_cfg:Enable";
+                  type empty;
+                  description "Enable auto-discovery";
+                }
+              }
+              leaf mp2mpmtu {
+                xr:xr-xml-map "l2vpn_cfg:MP2MPMTU";
+                xr:xr-cli-map "l2vpn xconnect group <string> mp2mp "+
+                  "<string> mtu <number> ";
+                type L2vpn-mtu-range;
+                units "byte";
+                description
+                  "Maximum transmission unit for this MP2MP
+                  VPWS instance";
+              }
+              leaf mp2mp-control-word {
+                xr:xr-xml-map "l2vpn_cfg:MP2MPControlWord";
+                xr:xr-cli-map "l2vpn xconnect group <string> mp2mp "+
+                  "<string> control-word disable ";
+                type empty;
+                description "Disable control word";
+              }
+              leaf mp2mpl2-encapsulation {
+                xr:xr-xml-map "l2vpn_cfg:MP2MPL2Encapsulation";
+                xr:xr-cli-map "l2vpn xconnect group <string> mp2mp "+
+                  "<string> l2-encapsulation <enum> ";
+                type L2-encapsulation;
+                description "Configure Layer 2 Encapsulation";
+              }
+              leaf mp2mp-interworking {
+                xr:xr-xml-map "l2vpn_cfg:MP2MPInterworking";
+                xr:xr-cli-map "l2vpn xconnect group <string> mp2mp "+
+                  "<string> interworking <enum> ";
+                type Interworking;
+                description "Interworking";
+              }
+              leaf mp2mp-shutdown {
+                xr:xr-xml-map "l2vpn_cfg:MP2MPShutdown";
+                xr:xr-cli-map "l2vpn xconnect group <string> mp2mp "+
+                  "<string> shutdown ";
+                type empty;
+                description "shutdown this MP2MP VPWS instance";
+              }
+              leaf mp2mpvpn-id {
+                xr:xr-xml-map "l2vpn_cfg:MP2MPVPNId";
+                xr:xr-cli-map "l2vpn xconnect group <string> mp2mp "+
+                  "<string> vpn-id <number> ";
+                type Vpnid-range;
+                description "VPN Identifier";
+              }
+              leaf name {
+                xr:xr-xml-map "l2vpn_cfg:Name";
+                type xr:Cisco-ios-xr-string {
+                  length "0..26";
+                }
+                description
+                  "Name of the multi point to multi point
+                  xconnect";
+              }
+            }
+          }
+          leaf name {
+            xr:xr-xml-map "l2vpn_cfg:Name";
+            type xr:Cisco-ios-xr-string {
+              length "0..32";
+            }
+            description "Name of the xconnect group";
+          }
+        }
+      }
+
+      container bridge-domain-groups {
+        xr:xr-xml-map "l2vpn_cfg:BridgeDomainGroupTable";
+        description "List of bridge  groups";
+
+        list bridge-domain-group {
+          xr:xr-xml-map "l2vpn_cfg:BridgeDomainGroup";
+          key "name";
+          description "Bridge group";
+
+          container bridge-domains {
+            xr:xr-xml-map "l2vpn_cfg:BridgeDomainTable";
+            description "List of Bridge Domain";
+
+            list bridge-domain {
+              xr:xr-xml-map "l2vpn_cfg:BridgeDomain";
+              key "name";
+              description "bridge domain";
+
+              container bd-storm-controls {
+                xr:xr-xml-map "l2vpn_cfg:BDStormControlTable";
+                description "Storm Control";
+
+                list bd-storm-control {
+                  xr:xr-xml-map "l2vpn_cfg:BDStormControl";
+                  key "sctype";
+                  description "Storm Control Type";
+                  leaf sctype {
+                    xr:xr-xml-map "l2vpn_cfg:SCType";
+                    type Storm-control;
+                    description "Storm Control Type";
+                  }
+                  uses STORM-CONTROL-UNIT;
+                }
+              }
+
+              container member-vnis {
+                xr:xr-xml-map "l2vpn_cfg:MemberVNITable";
+                description
+                  "Bridge Domain VxLAN Network Identifier
+                  Table";
+
+                list member-vni {
+                  xr:xr-xml-map "l2vpn_cfg:MemberVNI";
+                  key "vni";
+                  description
+                    "Bridge Domain Member VxLAN Network
+                    Identifier ";
+                  leaf vni {
+                    xr:xr-xml-map "l2vpn_cfg:VNI";
+                    type uint32 {
+                      range "1..16777215";
+                    }
+                    description "VxLAN Network Identifier number";
+                  }
+                }
+              }
+
+              container bridge-domain-mac {
+                xr:xr-xml-map "l2vpn_cfg:BridgeDomainMAC";
+                description "MAC configuration commands";
+
+                container bd-mac-limit {
+                  xr:xr-xml-map "l2vpn_cfg:BD_MACLimit";
+                  description "MAC-Limit configuration commands";
+                  leaf bd-mac-limit-action {
+                    xr:xr-xml-map "l2vpn_cfg:BD_MACLimitAction";
+                    xr:xr-cli-map "action (flood)|(no-flood)|(shutd"+
+                      "own) ";
+                    type Mac-limit-action;
+                    description
+                      "MAC address limit enforcement action";
+                  }
+                  leaf bd-mac-limit-notif {
+                    xr:xr-xml-map "l2vpn_cfg:BD_MACLimitNotif";
+                    xr:xr-cli-map "notification (trap)|(both)|(none"+
+                      ") ";
+                    type Mac-notification;
+                    description "Mac Address Limit Notification";
+                  }
+                  leaf bd-mac-limit-max {
+                    xr:xr-xml-map "l2vpn_cfg:BD_MACLimitMax";
+                    xr:xr-cli-map "maximum <number> ";
+                    type Mac-limit-range;
+                    description
+                      "Number of MAC addresses after which MAC
+                      limit action is taken";
+                  }
+                }
+
+                container bd-mac-filters {
+                  xr:xr-xml-map "l2vpn_cfg:BD_MACFilterTable";
+                  description "Filter Mac Address";
+
+                  list bd-mac-filter {
+                    xr:xr-xml-map "l2vpn_cfg:BD_MACFilter";
+                    key "address";
+                    description "Static MAC address";
+                    leaf drop {
+                      xr:xr-xml-map "l2vpn_cfg:Drop";
+                      xr:xr-cli-map "static-address <MAC address> d"+
+                        "rop ";
+                      type empty;
+                      description "MAC address for filtering";
+                    }
+                    leaf address {
+                      xr:xr-xml-map "l2vpn_cfg:Address";
+                      type yang:mac-address;
+                      description "Static MAC address";
+                    }
+                  }
+                }
+
+                container mac-secure {
+                  xr:xr-xml-map "l2vpn_cfg:MACSecure";
+                  description "MAC Secure";
+                  leaf logging {
+                    xr:xr-xml-map "l2vpn_cfg:Logging";
+                    xr:xr-cli-map "logging ";
+                    type empty;
+                    description "MAC Secure Logging";
+                  }
+                  leaf action {
+                    xr:xr-xml-map "l2vpn_cfg:Action";
+                    xr:xr-cli-map "action (none)|(shutdown) ";
+                    type Mac-secure-action;
+                    description "MAC secure enforcement action";
+                  }
+                  leaf enable {
+                    xr:xr-xml-map "l2vpn_cfg:Enable";
+                    type empty;
+                    description "Enable MAC Secure";
+                  }
+                }
+
+                container bd-mac-aging {
+                  xr:xr-xml-map "l2vpn_cfg:BD_MACAging";
+                  description "MAC-Aging configuration commands";
+                  leaf bd-mac-aging-type {
+                    xr:xr-xml-map "l2vpn_cfg:BD_MACAgingType";
+                    xr:xr-cli-map "aging type absolute ";
+                    type Mac-aging;
+                    description "MAC address aging type";
+                  }
+                  leaf bd-mac-aging-time {
+                    xr:xr-xml-map "l2vpn_cfg:BD_MACAgingTime";
+                    xr:xr-cli-map "aging time <number> ";
+                    type Mac-aging-range;
+                    description "Mac Aging Time";
+                  }
+                }
+                leaf bd-mac-withdraw-relay {
+                  xr:xr-xml-map "l2vpn_cfg:BD_MACWithdrawRelay";
+                  xr:xr-cli-map "withdraw relay ";
+                  type empty;
+                  description
+                    "Mac withdraw sent from access PW to access
+                    PW";
+                }
+                leaf bd-mac-withdraw-access-pw-disable {
+                  xr:xr-xml-map "l2vpn_cfg:BD_MACWithdrawAccessPWDi"+
+                    "sable";
+                  xr:xr-cli-map "withdraw access-pw disable ";
+                  type empty;
+                  description "MAC withdraw on Access PW";
+                }
+                leaf bd-mac-port-down-flush {
+                  xr:xr-xml-map "l2vpn_cfg:BD_MACPortDownFlush";
+                  xr:xr-cli-map "port-down flush [disable] ";
+                  type empty;
+                  description
+                    "Disable MAC Flush when Port goes Down";
+                }
+                leaf bd-mac-withdraw {
+                  xr:xr-xml-map "l2vpn_cfg:BD_MACWithdraw";
+                  xr:xr-cli-map "withdraw disable ";
+                  type empty;
+                  description "Disable Mac Withdraw";
+                }
+                leaf bd-mac-withdraw-behavior {
+                  xr:xr-xml-map "l2vpn_cfg:BD_MACWithdrawBehavior";
+                  xr:xr-cli-map "withdraw state-down ";
+                  type Mac-withdraw-behavior;
+                  description
+                    "MAC withdraw sent on bridge port down";
+                }
+                leaf bd-mac-learn {
+                  xr:xr-xml-map "l2vpn_cfg:BD_MACLearn";
+                  xr:xr-cli-map "learning [disable] ";
+                  type Mac-learn;
+                  description "Enable Mac Learning";
+                }
+              }
+
+              container nv-satellite {
+                xr:xr-xml-map "l2vpn_cfg:nVSatellite";
+                description "nV Satellite";
+                leaf offload-ipv4-multicast-enable {
+                  xr:xr-xml-map "l2vpn_cfg:OffloadIPv4MulticastEnab"+
+                    "le";
+                  xr:xr-cli-map "l2vpn bridge group <string> bridge"+
+                    "-domain <string> nv satellite offload ipv4 mul"+
+                    "ticast enable ";
+                  type empty;
+                  description
+                    "Enable IPv4 Multicast Offload to Satellite
+                    Nodes";
+                }
+                leaf enable {
+                  xr:xr-xml-map "l2vpn_cfg:Enable";
+                  type empty;
+                  description "Enable nV Satellite Settings";
+                }
+              }
+
+              container bridge-domain-pbb {
+                xr:xr-xml-map "l2vpn_cfg:BridgeDomainPBB";
+                description "Bridge Domain PBB";
+
+                container pbb-edges {
+                  xr:xr-xml-map "l2vpn_cfg:PBBEdgeTable";
+                  description "PBB Edge";
+
+                  list pbb-edge {
+                    xr:xr-xml-map "l2vpn_cfg:PBBEdge";
+                    key "isid core-bd-name";
+                    description
+                      "Configure BD as PBB Edge with ISID and
+                      associated PBB Core BD";
+
+                    container pbb-static-mac-mappings {
+                      xr:xr-xml-map "l2vpn_cfg:PBBStaticMACMappingT"+
+                        "able";
+                      description
+                        "PBB Static Mac Address Mapping Table";
+
+                      list pbb-static-mac-mapping {
+                        xr:xr-xml-map "l2vpn_cfg:PBBStaticMACMappin"+
+                          "g";
+                        key "address";
+                        description
+                          "PBB Static Mac Address Mapping
+                          Configuration";
+                        leaf address {
+                          xr:xr-xml-map "l2vpn_cfg:Address";
+                          type yang:mac-address;
+                          description "Static MAC address";
+                        }
+                        leaf bmac {
+                          xr:xr-xml-map "l2vpn_cfg:BMAC";
+                          type yang:mac-address;
+                          mandatory true;
+                          description "Backbone MAC address";
+                        }
+                      }
+                    }
+
+                    container pbb-edge-dhcp-profile {
+                      xr:xr-xml-map "l2vpn_cfg:PBBEdgeDHCPProfile";
+                      description "Attach a DHCP profile";
+                      leaf profile-id {
+                        xr:xr-xml-map "l2vpn_cfg:ProfileId";
+                        type Interface-profile;
+                        description "Set the snooping profile";
+                      }
+                      leaf dhcp-snooping-id {
+                        xr:xr-xml-map "l2vpn_cfg:DhcpSnoopingID";
+                        type string;
+                        description "Disable DHCP snooping";
+                      }
+                    }
+
+                    container pbb-edge-mac {
+                      xr:xr-xml-map "l2vpn_cfg:PBBEdgeMAC";
+                      description "MAC configuration commands";
+
+                      container pbb-edge-mac-limit {
+                        xr:xr-xml-map "l2vpn_cfg:PBBEdgeMACLimit";
+                        description
+                          "MAC-Limit configuration commands";
+                        leaf pbb-edge-mac-limit-action {
+                          xr:xr-xml-map "l2vpn_cfg:PBBEdgeMACLimitA"+
+                            "ction";
+                          xr:xr-cli-map "action (flood)|(no-flood)|"+
+                            "(shutdown)|(none) ";
+                          type Mac-limit-action;
+                          description
+                            "MAC address limit enforcement action";
+                        }
+                        leaf pbb-edge-mac-limit-max {
+                          xr:xr-xml-map "l2vpn_cfg:PBBEdgeMACLimitM"+
+                            "ax";
+                          xr:xr-cli-map "maximum <number> ";
+                          type Mac-limit-range;
+                          description
+                            "Number of MAC addresses after which
+                            MAC limit action is taken";
+                        }
+                        leaf pbb-edge-mac-limit-notif {
+                          xr:xr-xml-map "l2vpn_cfg:PBBEdgeMACLimitN"+
+                            "otif";
+                          xr:xr-cli-map "notification (trap)|(both)"+
+                            "|(none)|(syslog) ";
+                          type Mac-notification;
+                          description
+                            "MAC address limit notification action";
+                        }
+                      }
+
+                      container pbb-edge-mac-aging {
+                        xr:xr-xml-map "l2vpn_cfg:PBBEdgeMACAging";
+                        description
+                          "MAC-Aging configuration commands";
+                        leaf pbb-edge-mac-aging-type {
+                          xr:xr-xml-map "l2vpn_cfg:PBBEdgeMACAgingT"+
+                            "ype";
+                          xr:xr-cli-map "aging type (absolute)|(ina"+
+                            "ctivity) ";
+                          type Mac-aging;
+                          description "MAC address aging type";
+                        }
+                        leaf pbb-edge-mac-aging-time {
+                          xr:xr-xml-map "l2vpn_cfg:PBBEdgeMACAgingT"+
+                            "ime";
+                          xr:xr-cli-map "aging time <number> ";
+                          type Mac-aging-range;
+                          description "Mac Aging Time";
+                        }
+                      }
+
+                      container pbb-edge-mac-secure {
+                        xr:xr-xml-map "l2vpn_cfg:PBBEdgeMACSecure";
+                        description "MAC Secure";
+                        leaf logging {
+                          xr:xr-xml-map "l2vpn_cfg:Logging";
+                          xr:xr-cli-map "logging (disable) ";
+                          type L2vpn-logging;
+                          description "MAC Secure Logging";
+                        }
+                        leaf disable {
+                          xr:xr-xml-map "l2vpn_cfg:Disable";
+                          xr:xr-cli-map "disable ";
+                          type empty;
+                          description
+                            "Disable Virtual instance port MAC
+                            Secure";
+                        }
+                        leaf action {
+                          xr:xr-xml-map "l2vpn_cfg:Action";
+                          xr:xr-cli-map "action (none)|(shutdown)|("+
+                            "restrict) ";
+                          type Mac-secure-action;
+                          description
+                            "MAC secure enforcement action";
+                        }
+                        leaf enable {
+                          xr:xr-xml-map "l2vpn_cfg:Enable";
+                          type empty;
+                          description "Enable MAC Secure";
+                        }
+                        leaf accept-shutdown {
+                          xr:xr-xml-map "l2vpn_cfg:AcceptShutdown";
+                          xr:xr-cli-map "accept-shutdown ";
+                          type empty;
+                          description
+                            "Accept Virtual instance port to be
+                            shutdown on mac violation";
+                        }
+                      }
+                      leaf pbb-edge-mac-learning {
+                        xr:xr-xml-map "l2vpn_cfg:PBBEdgeMACLearning";
+                        xr:xr-cli-map "learning (disable) ";
+                        type Mac-learn;
+                        description "Enable Mac Learning";
+                      }
+                    }
+                    leaf pbb-edge-igmp-profile {
+                      xr:xr-xml-map "l2vpn_cfg:PBBEdgeIGMPProfile";
+                      xr:xr-cli-map "igmp snooping profile <string>"+
+                        " ";
+                      type xr:Cisco-ios-xr-string {
+                        length "0..32";
+                      }
+                      description "Attach a IGMP Snooping profile";
+                    }
+                    leaf unknown-unicast-bmac {
+                      xr:xr-xml-map "l2vpn_cfg:UnknownUnicastBMAC";
+                      type yang:mac-address;
+                      description
+                        "Configure Unknown Unicast BMAC address
+                        for PBB Edge Port";
+                    }
+                    leaf isid {
+                      xr:xr-xml-map "l2vpn_cfg:ISID";
+                      type Pbbisid-range;
+                      description "ISID";
+                    }
+                    leaf core-bd-name {
+                      xr:xr-xml-map "l2vpn_cfg:CoreBDName";
+                      type xr:Cisco-ios-xr-string {
+                        length "0..27";
+                      }
+                      description "Core BD Name";
+                    }
+                  }
+                }
+
+                container pbb-core {
+                  xr:xr-xml-map "l2vpn_cfg:PBBCore";
+                  description "PBB Core";
+
+                  container pbb-core-mac {
+                    xr:xr-xml-map "l2vpn_cfg:PBBCoreMAC";
+                    description "MAC configuration commands";
+
+                    container pbb-core-mac-aging {
+                      xr:xr-xml-map "l2vpn_cfg:PBBCoreMACAging";
+                      description
+                        "MAC-Aging configuration commands";
+                      leaf pbb-core-mac-aging-type {
+                        xr:xr-xml-map "l2vpn_cfg:PBBCoreMACAgingTyp"+
+                          "e";
+                        xr:xr-cli-map "aging type (absolute)|(inact"+
+                          "ivity) ";
+                        type Mac-aging;
+                        description "MAC address aging type";
+                      }
+                      leaf pbb-core-mac-aging-time {
+                        xr:xr-xml-map "l2vpn_cfg:PBBCoreMACAgingTim"+
+                          "e";
+                        xr:xr-cli-map "aging time <number> ";
+                        type Mac-aging-range;
+                        description "Mac Aging Time";
+                      }
+                    }
+
+                    container pbb-core-mac-limit {
+                      xr:xr-xml-map "l2vpn_cfg:PBBCoreMACLimit";
+                      description
+                        "MAC-Limit configuration commands";
+                      leaf pbb-core-mac-limit-max {
+                        xr:xr-xml-map "l2vpn_cfg:PBBCoreMACLimitMax";
+                        xr:xr-cli-map "maximum <number> ";
+                        type Mac-limit-range;
+                        description
+                          "Number of MAC addresses after which MAC
+                          limit action is taken";
+                      }
+                      leaf pbb-core-mac-limit-notif {
+                        xr:xr-xml-map "l2vpn_cfg:PBBCoreMACLimitNot"+
+                          "if";
+                        xr:xr-cli-map "notification (trap)|(both)|("+
+                          "none)|(syslog) ";
+                        type Mac-notification;
+                        description
+                          "MAC address limit notification action";
+                      }
+                      leaf pbb-core-mac-limit-action {
+                        xr:xr-xml-map "l2vpn_cfg:PBBCoreMACLimitAct"+
+                          "ion";
+                        xr:xr-cli-map "action (flood)|(no-flood)|(s"+
+                          "hutdown)|(none) ";
+                        type Mac-limit-action;
+                        description
+                          "MAC address limit enforcement action";
+                      }
+                    }
+                    leaf pbb-core-mac-learning {
+                      xr:xr-xml-map "l2vpn_cfg:PBBCoreMACLearning";
+                      xr:xr-cli-map "learning (disable) ";
+                      type Mac-learn;
+                      description "Enable Mac Learning";
+                    }
+                  }
+
+                  container pbb-core-dhcp-profile {
+                    xr:xr-xml-map "l2vpn_cfg:PBBCoreDHCPProfile";
+                    description "Attach a DHCP profile";
+                    leaf profile-id {
+                      xr:xr-xml-map "l2vpn_cfg:ProfileId";
+                      type Interface-profile;
+                      description "Set the snooping profile";
+                    }
+                    leaf dhcp-snooping-id {
+                      xr:xr-xml-map "l2vpn_cfg:DhcpSnoopingID";
+                      type string;
+                      description "Disable DHCP snooping";
+                    }
+                  }
+                  leaf pbb-core-mmrp-flood-optimization {
+                    xr:xr-xml-map "l2vpn_cfg:PBBCoreMMRPFloodOptimi"+
+                      "zation";
+                    xr:xr-cli-map "l2vpn bridge group <string> brid"+
+                      "ge-domain <string> pbb core mmrp-flood-optim"+
+                      "ization ";
+                    type empty;
+                    description
+                      "Enabling MMRP PBB-VPLS Flood Optimization";
+                  }
+                  leaf vlan-id {
+                    xr:xr-xml-map "l2vpn_cfg:VLAN_ID";
+                    xr:xr-cli-map "l2vpn bridge group <string> brid"+
+                      "ge-domain <string> pbb core rewrite ingress "+
+                      "tag push dot1ad <number> symmetric ";
+                    type Pbbvid-range;
+                    description "VLAN ID to push";
+                  }
+                  leaf pbb-core-igmp-profile {
+                    xr:xr-xml-map "l2vpn_cfg:PBBCoreIGMPProfile";
+                    type xr:Cisco-ios-xr-string {
+                      length "0..32";
+                    }
+                    description "Attach a IGMP Snooping profile";
+                  }
+                  leaf enable {
+                    xr:xr-xml-map "l2vpn_cfg:Enable";
+                    type empty;
+                    description
+                      "Enable Bridge Domain PBB Core
+                      Configuration";
+                  }
+                  leaf evpn-attribute {
+                    xr:xr-xml-map "l2vpn_cfg:EVPNAttribute";
+                    xr:xr-cli-map "l2vpn bridge group <string> brid"+
+                      "ge-domain <string> pbb core evpn evi <number"+
+                      "> ";
+                    type Evpnvpnid-range;
+                    description "Configure EVPN EVI";
+                  }
+                }
+              }
+
+              container bd-pseudowires {
+                xr:xr-xml-map "l2vpn_cfg:BDPseudowireTable";
+                description "List of pseudowires";
+
+                list bd-pseudowire {
+                  xr:xr-xml-map "l2vpn_cfg:BDPseudowire";
+                  key "neighbor pseudowire-id";
+                  description "Pseudowire configuration";
+
+                  container pseudowire-dai {
+                    xr:xr-xml-map "l2vpn_cfg:PseudowireDAI";
+                    description
+                      "Access Pseudowire Dynamic ARP Inspection";
+
+                    container pseudowire-dai-address-validation {
+                      xr:xr-xml-map "l2vpn_cfg:PseudowireDAIAddress"+
+                        "Validation";
+                      description "Address Validation";
+                      leaf ipv4-verification {
+                        xr:xr-xml-map "l2vpn_cfg:IPv4Verification";
+                        type L2vpn-verification;
+                        description "IPv4 Verification";
+                      }
+                      leaf destination-mac-verification {
+                        xr:xr-xml-map "l2vpn_cfg:DestinationMACVeri"+
+                          "fication";
+                        type L2vpn-verification;
+                        description "Destination MAC Verification";
+                      }
+                      leaf source-mac-verification {
+                        xr:xr-xml-map "l2vpn_cfg:SourceMACVerificat"+
+                          "ion";
+                        type L2vpn-verification;
+                        description "Source MAC Verification";
+                      }
+                    }
+                    leaf logging {
+                      xr:xr-xml-map "l2vpn_cfg:Logging";
+                      type L2vpn-logging;
+                      description "Logging Type";
+                    }
+                    leaf disable {
+                      xr:xr-xml-map "l2vpn_cfg:Disable";
+                      type empty;
+                      description "Disable Dynamic ARP Inspection";
+                    }
+                    leaf enable {
+                      xr:xr-xml-map "l2vpn_cfg:Enable";
+                      type empty;
+                      description
+                        "Enable Access Pseudowire Dynamic ARP
+                        Inspection";
+                    }
+                  }
+
+                  container bdpw-storm-control-types {
+                    xr:xr-xml-map "l2vpn_cfg:BDPWStormControlTable";
+                    description "Storm Control";
+
+                    list bdpw-storm-control-type {
+                      xr:xr-xml-map "l2vpn_cfg:BDPWStormControlType";
+                      key "sctype";
+                      description "Storm Control Type";
+                      leaf sctype {
+                        xr:xr-xml-map "l2vpn_cfg:SCType";
+                        type Storm-control;
+                        description "Storm Control Type";
+                      }
+                      uses STORM-CONTROL-UNIT;
+                    }
+                  }
+
+                  container pseudowire-profile {
+                    xr:xr-xml-map "l2vpn_cfg:PseudowireProfile";
+                    description "Attach a DHCP profile";
+                    leaf profile-id {
+                      xr:xr-xml-map "l2vpn_cfg:ProfileId";
+                      type Interface-profile;
+                      description "Set the snooping profile";
+                    }
+                    leaf dhcp-snooping-id {
+                      xr:xr-xml-map "l2vpn_cfg:DhcpSnoopingID";
+                      type string;
+                      description "Disable DHCP snooping";
+                    }
+                  }
+
+                  container bd-pw-static-mac-addresses {
+                    xr:xr-xml-map "l2vpn_cfg:BD_PWStaticMACAddressT"+
+                      "able";
+                    description "Static Mac Address Table";
+
+                    list bd-pw-static-mac-address {
+                      xr:xr-xml-map "l2vpn_cfg:BD_PWStaticMacAddres"+
+                        "s";
+                      key "address";
+                      description
+                        "Static Mac Address Configuration";
+                      leaf address {
+                        xr:xr-xml-map "l2vpn_cfg:Address";
+                        type yang:mac-address;
+                        description "Static MAC address";
+                      }
+                    }
+                  }
+
+                  container pseudowire-ip-source-guard {
+                    xr:xr-xml-map "l2vpn_cfg:PseudowireIPSourceGuar"+
+                      "d";
+                    description "IP Source Guard";
+                    leaf logging {
+                      xr:xr-xml-map "l2vpn_cfg:Logging";
+                      type L2vpn-logging;
+                      description "Logging Type";
+                    }
+                    leaf disable {
+                      xr:xr-xml-map "l2vpn_cfg:Disable";
+                      type empty;
+                      description "Disable Dynamic IP source guard";
+                    }
+                    leaf enable {
+                      xr:xr-xml-map "l2vpn_cfg:Enable";
+                      type empty;
+                      description "Enable IP Source Guard";
+                    }
+                  }
+
+                  container pseudowire-mac {
+                    xr:xr-xml-map "l2vpn_cfg:PseudowireMAC";
+                    description
+                      "Bridge-domain Pseudowire MAC
+                      configuration commands";
+
+                    container pseudowire-mac-secure {
+                      xr:xr-xml-map "l2vpn_cfg:PseudowireMACSecure";
+                      description "MAC Secure";
+                      leaf logging {
+                        xr:xr-xml-map "l2vpn_cfg:Logging";
+                        xr:xr-cli-map "logging (disable) ";
+                        type L2vpn-logging;
+                        description "MAC Secure Logging";
+                      }
+                      leaf disable {
+                        xr:xr-xml-map "l2vpn_cfg:Disable";
+                        xr:xr-cli-map "disable ";
+                        type empty;
+                        description
+                          "Disable L2 Pseudowire MAC Secure";
+                      }
+                      leaf action {
+                        xr:xr-xml-map "l2vpn_cfg:Action";
+                        xr:xr-cli-map "action (none)|(shutdown)|(re"+
+                          "strict) ";
+                        type Mac-secure-action;
+                        description "MAC secure enforcement action";
+                      }
+                      leaf enable {
+                        xr:xr-xml-map "l2vpn_cfg:Enable";
+                        type empty;
+                        description "Enable MAC Secure";
+                      }
+                    }
+
+                    container pseudowire-mac-aging {
+                      xr:xr-xml-map "l2vpn_cfg:PseudowireMACAging";
+                      description
+                        "MAC-Aging configuration commands";
+                      leaf pseudowire-mac-aging-type {
+                        xr:xr-xml-map "l2vpn_cfg:PseudowireMACAging"+
+                          "Type";
+                        xr:xr-cli-map "aging type (absolute)|(inact"+
+                          "ivity) ";
+                        type Mac-aging;
+                        description "MAC address aging type";
+                      }
+                      leaf pseudowire-mac-aging-time {
+                        xr:xr-xml-map "l2vpn_cfg:PseudowireMACAging"+
+                          "Time";
+                        xr:xr-cli-map "aging time <number> ";
+                        type Mac-aging-range;
+                        description "MAC Aging Time";
+                      }
+                    }
+
+                    container pseudowire-mac-limit {
+                      xr:xr-xml-map "l2vpn_cfg:PseudowireMACLimit";
+                      description
+                        "MAC-Limit configuration commands";
+                      leaf pseudowire-mac-limit-action {
+                        xr:xr-xml-map "l2vpn_cfg:PseudowireMACLimit"+
+                          "Action";
+                        xr:xr-cli-map "action (flood)|(no-flood)|(s"+
+                          "hutdown)|(none) ";
+                        type Mac-limit-action;
+                        description
+                          "Bridge Access Pseudowire MAC address
+                          limit enforcement action";
+                      }
+                      leaf pseudowire-mac-limit-notif {
+                        xr:xr-xml-map "l2vpn_cfg:PseudowireMACLimit"+
+                          "Notif";
+                        xr:xr-cli-map "notification (trap)|(both)|("+
+                          "none)|(syslog) ";
+                        type Mac-notification;
+                        description
+                          "MAC address limit notification action
+                          in a Bridge Access Pseudowire";
+                      }
+                      leaf pseudowire-mac-limit-max {
+                        xr:xr-xml-map "l2vpn_cfg:PseudowireMACLimit"+
+                          "Max";
+                        xr:xr-cli-map "maximum <number> ";
+                        type Mac-limit-range;
+                        description
+                          "Number of MAC addresses on a Bridge
+                          Access Pseudowire after which MAC limit
+                          action is taken";
+                      }
+                    }
+                    leaf pseudowire-mac-port-down-flush {
+                      xr:xr-xml-map "l2vpn_cfg:PseudowireMACPortDow"+
+                        "nFlush";
+                      xr:xr-cli-map "port-down flush (disable) ";
+                      type Port-down-flush;
+                      description
+                        "Enable/Disable MAC Flush When Port goes
+                        down";
+                    }
+                    leaf enable {
+                      xr:xr-xml-map "l2vpn_cfg:Enable";
+                      type empty;
+                      description
+                        "Bridge-domain Pseudowire MAC
+                        configuration mode";
+                    }
+                    leaf pseudowire-mac-learning {
+                      xr:xr-xml-map "l2vpn_cfg:PseudowireMACLearnin"+
+                        "g";
+                      xr:xr-cli-map "learning (disable) ";
+                      type Mac-learn;
+                      description "Enable MAC Learning";
+                    }
+                  }
+
+                  container bd-pw-split-horizon {
+                    xr:xr-xml-map "l2vpn_cfg:BD_PWSplitHorizon";
+                    description "Split Horizon";
+
+                    container bd-pw-split-horizon-group {
+                      xr:xr-xml-map "l2vpn_cfg:BD_PWSplitHorizonGro"+
+                        "up";
+                      description "Split Horizon Group";
+                      leaf enable {
+                        xr:xr-xml-map "l2vpn_cfg:Enable";
+                        xr:xr-cli-map "split-horizon group ";
+                        type empty;
+                        description "Enable split horizon group";
+                      }
+                    }
+                  }
+
+                  container bd-pw-mpls-static-labels {
+                    xr:xr-xml-map "l2vpn_cfg:BD_PW_MPLSStaticLabels";
+                    description "MPLS static labels";
+                    leaf local-static-label {
+                      xr:xr-xml-map "l2vpn_cfg:LocalStaticLabel";
+                      type Pseudowire-label-range;
+                      description "Pseudowire local static label";
+                    }
+                    leaf remote-static-label {
+                      xr:xr-xml-map "l2vpn_cfg:RemoteStaticLabel";
+                      type Pseudowire-label-range;
+                      description "Pseudowire remote static label";
+                    }
+                  }
+
+                  container bridge-domain-backup-pseudowires {
+                    xr:xr-xml-map "l2vpn_cfg:BridgeDomainBackupPseu"+
+                      "dowireTable";
+                    description "List of pseudowires";
+
+                    list bridge-domain-backup-pseudowire {
+                      xr:xr-xml-map "l2vpn_cfg:BridgeDomainBackupPs"+
+                        "eudowire";
+                      key "neighbor pseudowire-id";
+                      description "Backup pseudowire configuration";
+                      leaf bridge-domain-backup-pw-class {
+                        xr:xr-xml-map "l2vpn_cfg:BridgeDomainBackup"+
+                          "PWClass";
+                        xr:xr-cli-map "backup neighbor <IPv4 addres"+
+                          "s> pw-id <number> pw-class <string> ";
+                        type xr:Cisco-ios-xr-string {
+                          length "0..32";
+                        }
+                        description
+                          "PW class template name to use for this
+                          pseudowire";
+                      }
+                      leaf neighbor {
+                        xr:xr-xml-map "l2vpn_cfg:Neighbor";
+                        type inet:ipv4-address-no-zone;
+                        description "Neighbor IP address";
+                      }
+                      leaf pseudowire-id {
+                        xr:xr-xml-map "l2vpn_cfg:PseudowireID";
+                        type Pseudowire-id-range;
+                        description "Pseudowire ID";
+                      }
+                    }
+                  }
+                  leaf pseudowire-mld-snoop {
+                    xr:xr-xml-map "l2vpn_cfg:PseudowireMLDSnoop";
+                    xr:xr-cli-map "mld snooping profile <string> ";
+                    type xr:Cisco-ios-xr-string {
+                      length "0..32";
+                    }
+                    description "Attach a MLD Snooping profile";
+                  }
+                  leaf pseudowire-igmp-snoop {
+                    xr:xr-xml-map "l2vpn_cfg:PseudowireIGMPSnoop";
+                    xr:xr-cli-map "igmp snooping profile <string> ";
+                    type xr:Cisco-ios-xr-string {
+                      length "0..32";
+                    }
+                    description "Attach a IGMP Snooping profile";
+                  }
+                  leaf pseudowire-flooding {
+                    xr:xr-xml-map "l2vpn_cfg:PseudowireFlooding";
+                    xr:xr-cli-map "flooding (disable) ";
+                    type Interface-traffic-flood;
+                    description "Bridge-domain Pseudowire flooding";
+                  }
+                  leaf bd-pw-class {
+                    xr:xr-xml-map "l2vpn_cfg:BD_PWClass";
+                    xr:xr-cli-map "pw-class <string> ";
+                    type xr:Cisco-ios-xr-string {
+                      length "0..32";
+                    }
+                    description
+                      "PW class template name to use for this
+                      pseudowire";
+                  }
+                  leaf pseudowire-flooding-unknown-unicast {
+                    xr:xr-xml-map "l2vpn_cfg:PseudowireFloodingUnkn"+
+                      "ownUnicast";
+                    xr:xr-cli-map "flooding unknown-unicast (disabl"+
+                      "e) ";
+                    type Interface-traffic-flood;
+                    description
+                      "Bridge-domain Pseudowire flooding Unknown
+                      Unicast";
+                  }
+                  leaf neighbor {
+                    xr:xr-xml-map "l2vpn_cfg:Neighbor";
+                    type inet:ipv4-address-no-zone;
+                    description "Neighbor IP address";
+                  }
+                  leaf pseudowire-id {
+                    xr:xr-xml-map "l2vpn_cfg:PseudowireID";
+                    type Pseudowire-id-range;
+                    description "Pseudowire ID";
+                  }
+                }
+              }
+
+              container vfis {
+                xr:xr-xml-map "l2vpn_cfg:VFITable";
+                description
+                  "Specify the virtual forwarding interface
+                  name";
+
+                list vfi {
+                  xr:xr-xml-map "l2vpn_cfg:VFI";
+                  key "name";
+                  description
+                    "Name of the Virtual Forwarding Interface";
+
+                  container multicast-p2mp {
+                    xr:xr-xml-map "l2vpn_cfg:MulticastP2MP";
+                    description "Enable Multicast P2MP in this VFI";
+
+                    container transports {
+                      xr:xr-xml-map "l2vpn_cfg:TransportTable";
+                      description "Multicast P2MP Transport";
+
+                      list transport {
+                        xr:xr-xml-map "l2vpn_cfg:Transport";
+                        key "transport-name";
+                        description "Multicast P2MP Transport Type";
+                        leaf attribute-set-name {
+                          xr:xr-xml-map "l2vpn_cfg:AttributeSetName";
+                          type xr:Cisco-ios-xr-string {
+                            length "0..64";
+                          }
+                          description
+                            "Multicast P2MP TE Attribute Set Name";
+                        }
+                        leaf transport-name {
+                          xr:xr-xml-map "l2vpn_cfg:TransportName";
+                          type Multicast-p2mp-transport;
+                          description "Transport Type";
+                        }
+                      }
+                    }
+
+                    container signalings {
+                      xr:xr-xml-map "l2vpn_cfg:SignalingTable";
+                      description "Multicast P2MP Signaling Type";
+
+                      list signaling {
+                        xr:xr-xml-map "l2vpn_cfg:Signaling";
+                        key "signaling-name";
+                        description "Multicast P2MP Signaling Type";
+                        leaf signaling-name {
+                          xr:xr-xml-map "l2vpn_cfg:SignalingName";
+                          type Multicast-p2mp-signaling;
+                          description "Signaling Type";
+                        }
+                      }
+                    }
+                    leaf enable {
+                      xr:xr-xml-map "l2vpn_cfg:Enable";
+                      type empty;
+                      description "Enable Autodiscovery P2MP";
+                    }
+                  }
+
+                  container vfi-pseudowires {
+                    xr:xr-xml-map "l2vpn_cfg:VFIPseudowireTable";
+                    description "List of pseudowires";
+
+                    list vfi-pseudowire {
+                      xr:xr-xml-map "l2vpn_cfg:VFIPseudowire";
+                      key "neighbor pseudowire-id";
+                      description "Pseudowire configuration";
+
+                      container vfi-pw-dhcp-snoop {
+                        xr:xr-xml-map "l2vpn_cfg:VFI_PW_DHCPSnoop";
+                        description
+                          "Attach a DHCP Snooping profile";
+                        leaf profile-id {
+                          xr:xr-xml-map "l2vpn_cfg:ProfileId";
+                          type Interface-profile;
+                          description "Set the snooping profile";
+                        }
+                        leaf dhcp-snooping-id {
+                          xr:xr-xml-map "l2vpn_cfg:DhcpSnoopingID";
+                          type string;
+                          description "Disable DHCP snooping";
+                        }
+                      }
+
+                      container vfi-pw-mpls-static-labels {
+                        xr:xr-xml-map "l2vpn_cfg:VFI_PW_MPLSStaticL"+
+                          "abels";
+                        description "MPLS static labels";
+                        leaf local-static-label {
+                          xr:xr-xml-map "l2vpn_cfg:LocalStaticLabel";
+                          type Pseudowire-label-range;
+                          description
+                            "Pseudowire local static label";
+                        }
+                        leaf remote-static-label {
+                          xr:xr-xml-map "l2vpn_cfg:RemoteStaticLabe"+
+                            "l";
+                          type Pseudowire-label-range;
+                          description
+                            "Pseudowire remote static label";
+                        }
+                      }
+
+                      container pseudowire-static-mac-addresses {
+                        xr:xr-xml-map "l2vpn_cfg:PseudowireStaticMA"+
+                          "CAddressTable";
+                        description "Static Mac Address Table";
+
+                        list pseudowire-static-mac-address {
+                          xr:xr-xml-map "l2vpn_cfg:PseudowireStatic"+
+                            "MACAddress";
+                          key "address";
+                          description
+                            "Static Mac Address Configuration";
+                          leaf address {
+                            xr:xr-xml-map "l2vpn_cfg:Address";
+                            type yang:mac-address;
+                            description "Static MAC address";
+                          }
+                        }
+                      }
+                      leaf vfi-pw-class {
+                        xr:xr-xml-map "l2vpn_cfg:VFI_PWClass";
+                        xr:xr-cli-map "neighbor <IPv4 address> pw-i"+
+                          "d <number> pw-class <string> ";
+                        type xr:Cisco-ios-xr-string {
+                          length "0..32";
+                        }
+                        description
+                          "PW class template name to use for this
+                          pseudowire";
+                      }
+                      leaf vfi-pw-igmp-snoop {
+                        xr:xr-xml-map "l2vpn_cfg:VFI_PW_IGMPSnoop";
+                        xr:xr-cli-map "neighbor <IPv4 address> pw-i"+
+                          "d <number> igmp snooping profile <string"+
+                          "> ";
+                        type xr:Cisco-ios-xr-string {
+                          length "0..32";
+                        }
+                        description
+                          "Attach a IGMP Snooping profile";
+                      }
+                      leaf vfi-pw-mld-snoop {
+                        xr:xr-xml-map "l2vpn_cfg:VFI_PW_MLDSnoop";
+                        xr:xr-cli-map "neighbor <IPv4 address> pw-i"+
+                          "d <number> mld snooping profile <string>"+
+                          " ";
+                        type xr:Cisco-ios-xr-string {
+                          length "0..32";
+                        }
+                        description "Attach a MLD Snooping profile";
+                      }
+                      leaf neighbor {
+                        xr:xr-xml-map "l2vpn_cfg:Neighbor";
+                        type inet:ipv4-address-no-zone;
+                        description "Neighbor IP address";
+                      }
+                      leaf pseudowire-id {
+                        xr:xr-xml-map "l2vpn_cfg:PseudowireID";
+                        type Pseudowire-id-range;
+                        description "Pseudowire ID";
+                      }
+                    }
+                  }
+
+                  container bgp-auto-discovery {
+                    xr:xr-xml-map "l2vpn_cfg:BGPAutoDiscovery";
+                    description
+                      "Enable Autodiscovery BGP in this VFI";
+
+                    container ldp-signaling-protocol {
+                      xr:xr-xml-map "l2vpn_cfg:LDPSignalingProtocol";
+                      description
+                        "Signaling Protocol LDP in this VFI
+                        configuration";
+
+                      container vplsid {
+                        xr:xr-xml-map "l2vpn_cfg:VPLSID";
+                        description "VPLS ID";
+                        leaf type {
+                          xr:xr-xml-map "l2vpn_cfg:Type";
+                          type Ldp-vpls-id;
+                          description "VPLS-ID Type";
+                        }
+                        leaf as {
+                          xr:xr-xml-map "l2vpn_cfg:AS";
+                          when "../type = 'two-byte-as'" {
+                            description "../Type = TwoByteAS";
+                          }
+                          type Vpls-id-as-range;
+                          description "Two byte AS number";
+                        }
+                        leaf as-index {
+                          xr:xr-xml-map "l2vpn_cfg:ASIndex";
+                          when "../type = 'two-byte-as'" {
+                            description "../Type = TwoByteAS";
+                          }
+                          type Vpls-id-as-index;
+                          description "AS index";
+                        }
+                        leaf address {
+                          xr:xr-xml-map "l2vpn_cfg:Address";
+                          when "../type = 'ipv4-address'" {
+                            description "../Type = IPV4Address";
+                          }
+                          type inet:ipv4-address-no-zone;
+                          description "IPV4 address";
+                        }
+                        leaf address-index {
+                          xr:xr-xml-map "l2vpn_cfg:AddressIndex";
+                          when "../type = 'ipv4-address'" {
+                            description "../Type = IPV4Address";
+                          }
+                          type Vpls-id-addr-index;
+                          description "Address index";
+                        }
+                      }
+
+                      container flow-label-load-balance {
+                        xr:xr-xml-map "l2vpn_cfg:FlowLabelLoadBalan"+
+                          "ce";
+                        description
+                          "Enable Flow Label based load balancing";
+                        leaf flow-label {
+                          xr:xr-xml-map "l2vpn_cfg:FlowLabel";
+                          type Flow-label-load-balance;
+                          description
+                            "Flow Label load balance type";
+                        }
+                        leaf static {
+                          xr:xr-xml-map "l2vpn_cfg:Static";
+                          type empty;
+                          description "Static Flow Label";
+                        }
+                      }
+                      leaf enable {
+                        xr:xr-xml-map "l2vpn_cfg:Enable";
+                        type empty;
+                        description
+                          "Enable LDP as Signaling Protocol
+                          .Deletion of this object also causes
+                          deletion of all objects under
+                          LDPSignalingProtocol.";
+                      }
+                    }
+
+                    container route-distinguisher {
+                      xr:xr-xml-map "l2vpn_cfg:RouteDistinguisher";
+                      description "Route Distinguisher";
+                      leaf type {
+                        xr:xr-xml-map "l2vpn_cfg:Type";
+                        type Bgp-route-distinguisher;
+                        description "Router Distinguisher Type";
+                      }
+                      leaf as {
+                        xr:xr-xml-map "l2vpn_cfg:AS";
+                        when "../type = 'two-byte-as' or ../type"+
+                          " = 'four-byte-as'" {
+                            description
+                              "../Type = TwoByteAS or ../Type =
+                              FourByteAS";
+                        }
+                        type Rdas-range;
+                        description "Two byte or 4 byte AS number";
+                      }
+                      leaf as-index {
+                        xr:xr-xml-map "l2vpn_cfg:ASIndex";
+                        when "../type = 'two-byte-as' or ../type"+
+                          " = 'four-byte-as'" {
+                            description
+                              "../Type = TwoByteAS or ../Type =
+                              FourByteAS";
+                        }
+                        type Rdas-index;
+                        description "AS:nn (hex or decimal format)";
+                      }
+                      leaf address {
+                        xr:xr-xml-map "l2vpn_cfg:Address";
+                        when "../type = 'ipv4-address'" {
+                          description "../Type = IPV4Address";
+                        }
+                        type inet:ipv4-address-no-zone;
+                        description "IPV4 address";
+                      }
+                      leaf addr-index {
+                        xr:xr-xml-map "l2vpn_cfg:AddrIndex";
+                        when "../type = 'ipv4-address'" {
+                          description "../Type = IPV4Address";
+                        }
+                        type Rd-addr-index;
+                        description "Addr index";
+                      }
+                    }
+
+                    container bgp-signaling-protocol {
+                      xr:xr-xml-map "l2vpn_cfg:BGPSignalingProtocol";
+                      description
+                        "Enable Signaling Protocol BGP in this
+                        VFI";
+
+                      container flow-label-load-balance {
+                        xr:xr-xml-map "l2vpn_cfg:FlowLabelLoadBalan"+
+                          "ce";
+                        description
+                          "Enable Flow Label based load balancing";
+                        leaf flow-label {
+                          xr:xr-xml-map "l2vpn_cfg:FlowLabel";
+                          type Flow-label-load-balance;
+                          description
+                            "Flow Label load balance type";
+                        }
+                        leaf static {
+                          xr:xr-xml-map "l2vpn_cfg:Static";
+                          type empty;
+                          description "Static Flow Label";
+                        }
+                      }
+                      leaf ve-range {
+                        xr:xr-xml-map "l2vpn_cfg:VERange";
+                        xr:xr-cli-map "ve-range <number> ";
+                        type Vedge-range;
+                        description
+                          "Local Virtual Edge Block Configurable
+                          Range";
+                      }
+                      leaf veid {
+                        xr:xr-xml-map "l2vpn_cfg:VEID";
+                        xr:xr-cli-map "ve-id <number> ";
+                        type Veid-range;
+                        description "Local Virtual Edge Identifier";
+                      }
+                      leaf enable {
+                        xr:xr-xml-map "l2vpn_cfg:Enable";
+                        type empty;
+                        description
+                          "Enable BGP as Signaling Protocol";
+                      }
+                    }
+
+                    container route-targets {
+                      xr:xr-xml-map "l2vpn_cfg:RouteTargetTable";
+                      description "Route Target";
+
+                      list route-target {
+                        xr:xr-xml-map "l2vpn_cfg:RouteTarget";
+                        must "two-byte-as-or-four-byte-as or"+
+                          " ipv4-address" {
+                          description
+                            "TwoByteAS-or-FourbyteAS or IPV4Address
+                            must be present.";
+                        }
+                        key "role format";
+                        description "Name of the Route Target";
+                        leaf role {
+                          xr:xr-xml-map "l2vpn_cfg:Role";
+                          type Bgp-route-target-role;
+                          description
+                            "Role of the router target type";
+                        }
+                        leaf format {
+                          xr:xr-xml-map "l2vpn_cfg:Format";
+                          type Bgp-route-target-format;
+                          description "Format of the route target";
+                        }
+
+                        list two-byte-as-or-four-byte-as {
+                          when "../format = 'two-byte-as' or"+
+                            " ../format = 'four-byte-as'" {
+                              description
+                                "../Format = TwoByteAS or ../Format =
+                                FourbyteAS";
+                          }
+                          key "as as-index";
+                          description "two byte as or four byte as";
+                          leaf as {
+                            xr:xr-xml-map "l2vpn_cfg:AS";
+                            type Rdas-range;
+                            description
+                              "Two byte or 4 byte AS number";
+                          }
+                          leaf as-index {
+                            xr:xr-xml-map "l2vpn_cfg:ASIndex";
+                            type Rdas-index;
+                            description
+                              "AS:nn (hex or decimal format)";
+                          }
+                        }
+
+                        list ipv4-address {
+                          when "../format = 'ipv4-address'" {
+                            description "../Format = IPV4Address";
+                          }
+                          key "address addr-index";
+                          description "ipv4 address";
+                          leaf address {
+                            xr:xr-xml-map "l2vpn_cfg:Address";
+                            type inet:ipv4-address-no-zone;
+                            description "IPV4 address";
+                          }
+                          leaf addr-index {
+                            xr:xr-xml-map "l2vpn_cfg:AddrIndex";
+                            type Rd-addr-index;
+                            description "Addr index";
+                          }
+                        }
+                      }
+                    }
+                    leaf ad-control-word {
+                      xr:xr-xml-map "l2vpn_cfg:ADControlWord";
+                      xr:xr-cli-map "control-word ";
+                      type empty;
+                      description
+                        "Enable control-word for this VFI";
+                    }
+                    leaf enable {
+                      xr:xr-xml-map "l2vpn_cfg:Enable";
+                      type empty;
+                      description "Enable Autodiscovery BGP";
+                    }
+                  }
+                  leaf vfi-shutdown {
+                    xr:xr-xml-map "l2vpn_cfg:VFIShutdown";
+                    xr:xr-cli-map "shutdown ";
+                    type empty;
+                    description "Enabling Shutdown";
+                  }
+                  leaf vpnid {
+                    xr:xr-xml-map "l2vpn_cfg:VPNID";
+                    xr:xr-cli-map "vpn-id <number> ";
+                    type Vpnid-range;
+                    description "VPN Identifier";
+                  }
+                  leaf name {
+                    xr:xr-xml-map "l2vpn_cfg:Name";
+                    type xr:Cisco-ios-xr-string {
+                      length "0..32";
+                    }
+                    description
+                      "Name of the Virtual Forwarding Interface";
+                  }
+                }
+              }
+
+              container bd-attachment-circuits {
+                xr:xr-xml-map "l2vpn_cfg:BDAttachmentCircuitTable";
+                description "Attachment Circuit table";
+
+                list bd-attachment-circuit {
+                  xr:xr-xml-map "l2vpn_cfg:BDAttachmentCircuit";
+                  key "name";
+                  description "Name of the Attachment Circuit";
+
+                  container interface-ip-source-guard {
+                    xr:xr-xml-map "l2vpn_cfg:InterfaceIPSourceGuard";
+                    description "IP Source Guard";
+                    leaf logging {
+                      xr:xr-xml-map "l2vpn_cfg:Logging";
+                      xr:xr-cli-map "logging (disable) ";
+                      type L2vpn-logging;
+                      description "Logging Type";
+                    }
+                    leaf disable {
+                      xr:xr-xml-map "l2vpn_cfg:Disable";
+                      xr:xr-cli-map "disable ";
+                      type empty;
+                      description
+                        "Disable L2 Interface Dynamic IP source
+                        guard";
+                    }
+                    leaf enable {
+                      xr:xr-xml-map "l2vpn_cfg:Enable";
+                      type empty;
+                      description "Enable IP Source Guard";
+                    }
+                  }
+
+                  container interface-dai {
+                    xr:xr-xml-map "l2vpn_cfg:InterfaceDAI";
+                    description
+                      "L2 Interface Dynamic ARP Inspection";
+
+                    container interface-dai-address-validation {
+                      xr:xr-xml-map "l2vpn_cfg:InterfaceDAIAddressV"+
+                        "alidation";
+                      description "Address Validation";
+                      leaf ipv4-verification {
+                        xr:xr-xml-map "l2vpn_cfg:IPv4Verification";
+                        xr:xr-cli-map "ipv4 (disable) ";
+                        type L2vpn-verification;
+                        description "IPv4 Verification";
+                      }
+                      leaf destination-mac-verification {
+                        xr:xr-xml-map "l2vpn_cfg:DestinationMACVeri"+
+                          "fication";
+                        xr:xr-cli-map "dst-mac (disable) ";
+                        type L2vpn-verification;
+                        description "Destination MAC Verification";
+                      }
+                      leaf source-mac-verification {
+                        xr:xr-xml-map "l2vpn_cfg:SourceMACVerificat"+
+                          "ion";
+                        xr:xr-cli-map "src-mac (disable) ";
+                        type L2vpn-verification;
+                        description "Source MAC Verification";
+                      }
+                      leaf enable {
+                        xr:xr-xml-map "l2vpn_cfg:Enable";
+                        type empty;
+                        description "Enable Address Validation";
+                      }
+                    }
+                    leaf logging {
+                      xr:xr-xml-map "l2vpn_cfg:Logging";
+                      xr:xr-cli-map "logging (disable) ";
+                      type L2vpn-logging;
+                      description "Logging Type";
+                    }
+                    leaf disable {
+                      xr:xr-xml-map "l2vpn_cfg:Disable";
+                      xr:xr-cli-map "disable ";
+                      type empty;
+                      description
+                        "Disable L2 Interface Dynamic ARP
+                        Inspection";
+                    }
+                    leaf enable {
+                      xr:xr-xml-map "l2vpn_cfg:Enable";
+                      type empty;
+                      description
+                        "Enable L2 Interface Dynamic ARP
+                        Inspection";
+                    }
+                  }
+
+                  container interface-profile {
+                    xr:xr-xml-map "l2vpn_cfg:InterfaceProfile";
+                    description "Attach a DHCP profile";
+                    leaf profile-id {
+                      xr:xr-xml-map "l2vpn_cfg:ProfileId";
+                      type Interface-profile;
+                      description "Set the snooping profile";
+                    }
+                    leaf dhcp-snooping-id {
+                      xr:xr-xml-map "l2vpn_cfg:DhcpSnoopingID";
+                      type string;
+                      description "Disable DHCP snooping";
+                    }
+                  }
+
+                  container bdac-storm-control-types {
+                    xr:xr-xml-map "l2vpn_cfg:BDACStormControlTable";
+                    description "Storm Control";
+
+                    list bdac-storm-control-type {
+                      xr:xr-xml-map "l2vpn_cfg:BDACStormControlType";
+                      key "sctype";
+                      description "Storm Control Type";
+                      leaf sctype {
+                        xr:xr-xml-map "l2vpn_cfg:SCType";
+                        type Storm-control;
+                        description "Storm Control Type";
+                      }
+                      uses STORM-CONTROL-UNIT;
+                    }
+                  }
+
+                  container split-horizon {
+                    xr:xr-xml-map "l2vpn_cfg:SplitHorizon";
+                    description "Split Horizon";
+
+                    container split-horizon-group-id {
+                      xr:xr-xml-map "l2vpn_cfg:SplitHorizonGroupID";
+                      description "Split Horizon Group ID";
+                      leaf enable {
+                        xr:xr-xml-map "l2vpn_cfg:Enable";
+                        xr:xr-cli-map "split-horizon group ";
+                        type empty;
+                        description "Enable split horizon group";
+                      }
+                    }
+                  }
+
+                  container static-mac-addresses {
+                    xr:xr-xml-map "l2vpn_cfg:StaticMACAddressTable";
+                    description "Static Mac Address Table";
+
+                    list static-mac-address {
+                      xr:xr-xml-map "l2vpn_cfg:StaticMACAddress";
+                      key "address";
+                      description
+                        "Static Mac Address Configuration";
+                      leaf address {
+                        xr:xr-xml-map "l2vpn_cfg:Address";
+                        type yang:mac-address;
+                        description "Static MAC address";
+                      }
+                    }
+                  }
+
+                  container interface-mac {
+                    xr:xr-xml-map "l2vpn_cfg:InterfaceMAC";
+                    description "MAC configuration commands";
+
+                    container interface-mac-aging {
+                      xr:xr-xml-map "l2vpn_cfg:InterfaceMACAging";
+                      description
+                        "MAC-Aging configuration commands";
+                      leaf interface-mac-aging-time {
+                        xr:xr-xml-map "l2vpn_cfg:InterfaceMACAgingT"+
+                          "ime";
+                        xr:xr-cli-map "aging time <number> ";
+                        type Mac-aging-range;
+                        description "Mac Aging Time";
+                      }
+                      leaf interface-mac-aging-type {
+                        xr:xr-xml-map "l2vpn_cfg:InterfaceMACAgingT"+
+                          "ype";
+                        xr:xr-cli-map "aging type (absolute)|(inact"+
+                          "ivity) ";
+                        type Mac-aging;
+                        description "MAC address aging type";
+                      }
+                    }
+
+                    container interface-mac-secure {
+                      xr:xr-xml-map "l2vpn_cfg:InterfaceMACSecure";
+                      description "MAC Secure";
+                      leaf logging {
+                        xr:xr-xml-map "l2vpn_cfg:Logging";
+                        xr:xr-cli-map "logging (disable) ";
+                        type L2vpn-logging;
+                        description "MAC Secure Logging";
+                      }
+                      leaf disable {
+                        xr:xr-xml-map "l2vpn_cfg:Disable";
+                        xr:xr-cli-map "disable ";
+                        type empty;
+                        description
+                          "Disable L2 Interface MAC Secure";
+                      }
+                      leaf action {
+                        xr:xr-xml-map "l2vpn_cfg:Action";
+                        xr:xr-cli-map "action (none)|(shutdown)|(re"+
+                          "strict) ";
+                        type Mac-secure-action;
+                        description "MAC secure enforcement action";
+                      }
+                      leaf enable {
+                        xr:xr-xml-map "l2vpn_cfg:Enable";
+                        type empty;
+                        description "Enable MAC Secure";
+                      }
+                    }
+
+                    container interface-mac-limit {
+                      xr:xr-xml-map "l2vpn_cfg:InterfaceMACLimit";
+                      description
+                        "MAC-Limit configuration commands";
+                      leaf interface-mac-limit-max {
+                        xr:xr-xml-map "l2vpn_cfg:InterfaceMACLimitM"+
+                          "ax";
+                        xr:xr-cli-map "maximum <number> ";
+                        type Mac-limit-range;
+                        description
+                          "Number of MAC addresses on an Interface
+                          after which MAC limit action is taken";
+                      }
+                      leaf interface-mac-limit-notif {
+                        xr:xr-xml-map "l2vpn_cfg:InterfaceMACLimitN"+
+                          "otif";
+                        xr:xr-cli-map "notification (trap)|(both)|("+
+                          "none)|(syslog) ";
+                        type Mac-notification;
+                        description
+                          "MAC address limit notification action
+                          in a Interface";
+                      }
+                      leaf interface-mac-limit-action {
+                        xr:xr-xml-map "l2vpn_cfg:InterfaceMACLimitA"+
+                          "ction";
+                        xr:xr-cli-map "action (flood)|(no-flood)|(s"+
+                          "hutdown)|(none) ";
+                        type Mac-limit-action;
+                        description
+                          "Interface MAC address limit enforcement
+                          action";
+                      }
+                    }
+                    leaf interface-mac-port-down-flush {
+                      xr:xr-xml-map "l2vpn_cfg:InterfaceMACPortDown"+
+                        "Flush";
+                      xr:xr-cli-map "port-down flush (disable) ";
+                      type Port-down-flush;
+                      description
+                        "Enable/Disable MAC Flush When Port goes
+                        down";
+                    }
+                    leaf interface-mac-learning {
+                      xr:xr-xml-map "l2vpn_cfg:InterfaceMACLearning";
+                      xr:xr-cli-map "learning (disable) ";
+                      type Mac-learn;
+                      description "Enable Mac Learning";
+                    }
+                  }
+                  leaf interface-flooding {
+                    xr:xr-xml-map "l2vpn_cfg:InterfaceFlooding";
+                    xr:xr-cli-map "flooding (disable) ";
+                    type Interface-traffic-flood;
+                    description "Enable or Disable Flooding";
+                  }
+                  leaf interface-igmp-snoop {
+                    xr:xr-xml-map "l2vpn_cfg:InterfaceIGMPSnoop";
+                    xr:xr-cli-map "igmp snooping profile <string> ";
+                    type xr:Cisco-ios-xr-string {
+                      length "0..32";
+                    }
+                    description "Attach a IGMP Snooping profile";
+                  }
+                  leaf interface-flooding-unknown-unicast {
+                    xr:xr-xml-map "l2vpn_cfg:InterfaceFloodingUnkno"+
+                      "wnUnicast";
+                    xr:xr-cli-map "flooding unknown-unicast (disabl"+
+                      "e) ";
+                    type Interface-traffic-flood;
+                    description
+                      "Enable or Disable Unknown Unicast
+                      Flooding";
+                  }
+                  leaf interface-mld-snoop {
+                    xr:xr-xml-map "l2vpn_cfg:InterfaceMLDSnoop";
+                    xr:xr-cli-map "mld snooping profile <string> ";
+                    type xr:Cisco-ios-xr-string {
+                      length "0..32";
+                    }
+                    description "Attach a MLD Snooping profile";
+                  }
+                  leaf name {
+                    xr:xr-xml-map "l2vpn_cfg:Name";
+                    type xr:Interface-name;
+                    description
+                      "The name of the Attachment Circuit";
+                  }
+                }
+              }
+
+              container ip-source-guard {
+                xr:xr-xml-map "l2vpn_cfg:IPSourceGuard";
+                description "IP Source Guard";
+                leaf logging {
+                  xr:xr-xml-map "l2vpn_cfg:Logging";
+                  xr:xr-cli-map "logging ";
+                  type empty;
+                  description "Enable Logging";
+                }
+                leaf enable {
+                  xr:xr-xml-map "l2vpn_cfg:Enable";
+                  type empty;
+                  description "Enable IP Source Guard";
+                }
+              }
+
+              container dai {
+                xr:xr-xml-map "l2vpn_cfg:DAI";
+                description "Dynamic ARP Inspection";
+
+                container dai-address-validation {
+                  xr:xr-xml-map "l2vpn_cfg:DAIAddressValidation";
+                  description "Address Validation";
+                  leaf ipv4-verification {
+                    xr:xr-xml-map "l2vpn_cfg:IPv4Verification";
+                    xr:xr-cli-map "ipv4 ";
+                    type empty;
+                    description "Enable IPv4 Verification";
+                  }
+                  leaf destination-mac-verification {
+                    xr:xr-xml-map "l2vpn_cfg:DestinationMACVerifica"+
+                      "tion";
+                    xr:xr-cli-map "dst-mac ";
+                    type empty;
+                    description
+                      "Enable Destination MAC Verification";
+                  }
+                  leaf source-mac-verification {
+                    xr:xr-xml-map "l2vpn_cfg:SourceMACVerification";
+                    xr:xr-cli-map "src-mac ";
+                    type empty;
+                    description "Enable Source MAC Verification";
+                  }
+                  leaf enable {
+                    xr:xr-xml-map "l2vpn_cfg:Enable";
+                    type empty;
+                    description "Enable Address Validation";
+                  }
+                }
+                leaf logging {
+                  xr:xr-xml-map "l2vpn_cfg:Logging";
+                  xr:xr-cli-map "logging ";
+                  type empty;
+                  description "Enable Logging";
+                }
+                leaf enable {
+                  xr:xr-xml-map "l2vpn_cfg:Enable";
+                  type empty;
+                  description "Enable Dynamic ARP Inspection";
+                }
+              }
+
+              container routed-interfaces {
+                xr:xr-xml-map "l2vpn_cfg:RoutedInterfaceTable";
+                description "Bridge Domain Routed Interface Table";
+
+                list routed-interface {
+                  xr:xr-xml-map "l2vpn_cfg:RoutedInterface";
+                  key "interface-name";
+                  description "Bridge Domain Routed Interface";
+                  leaf interface-name {
+                    xr:xr-xml-map "l2vpn_cfg:InterfaceName";
+                    type xr:Interface-name;
+                    description "The name of the Routed Interface";
+                  }
+                }
+              }
+              leaf coupled-mode {
+                xr:xr-xml-map "l2vpn_cfg:CoupledMode";
+                xr:xr-cli-map "l2vpn bridge group <string> bridge-d"+
+                  "omain <string> coupled-mode ";
+                type empty;
+                description "Coupled-mode configuration";
+              }
+              leaf shutdown {
+                xr:xr-xml-map "l2vpn_cfg:Shutdown";
+                xr:xr-cli-map "l2vpn bridge group <string> bridge-d"+
+                  "omain <string> shutdown ";
+                type empty;
+                description "shutdown the Bridge Domain";
+              }
+              leaf flooding-unknown-unicast {
+                xr:xr-xml-map "l2vpn_cfg:FloodingUnknownUnicast";
+                xr:xr-cli-map "l2vpn bridge group <string> bridge-d"+
+                  "omain <string> flooding unknown-unicast [disable"+
+                  "] ";
+                type empty;
+                description "Disable Unknown Unicast flooding";
+              }
+              leaf igmp-snooping-disable {
+                xr:xr-xml-map "l2vpn_cfg:IGMPSnoopingDisable";
+                xr:xr-cli-map "l2vpn bridge group <string> bridge-d"+
+                  "omain <string> igmp snooping disable ";
+                type empty;
+                description "Disable IGMP Snooping";
+              }
+              leaf transport-mode {
+                xr:xr-xml-map "l2vpn_cfg:TransportMode";
+                xr:xr-cli-map "l2vpn bridge group <string> bridge-d"+
+                  "omain <string> transport-mode vlan passthrough ";
+                type Bridge-domain-transport-mode;
+                description "Bridge Domain Transport mode";
+              }
+              leaf mld-snooping {
+                xr:xr-xml-map "l2vpn_cfg:MLDSnooping";
+                xr:xr-cli-map "l2vpn bridge group <string> bridge-d"+
+                  "omain <string> mld snooping profile <string> ";
+                type xr:Cisco-ios-xr-string {
+                  length "0..32";
+                }
+                description "Attach MLD Snooping Profile Name";
+              }
+              leaf bridge-domain-mtu {
+                xr:xr-xml-map "l2vpn_cfg:BridgeDomainMTU";
+                xr:xr-cli-map "l2vpn bridge group <string> bridge-d"+
+                  "omain <string> mtu <number> ";
+                type Bridge-bd-mtu-range;
+                units "byte";
+                description
+                  "Maximum transmission unit for this Bridge
+                  Domain";
+              }
+              leaf dhcp {
+                xr:xr-xml-map "l2vpn_cfg:DHCP";
+                xr:xr-cli-map "l2vpn bridge group <string> bridge-d"+
+                  "omain <string> dhcp ipv4 snoop profile <string> ";
+                type string {
+                  length "0..32";
+                }
+                description "DHCPv4 Snooping profile name";
+              }
+              leaf igmp-snooping {
+                xr:xr-xml-map "l2vpn_cfg:IGMPSnooping";
+                xr:xr-cli-map "l2vpn bridge group <string> bridge-d"+
+                  "omain <string> igmp snooping profile <string> ";
+                type xr:Cisco-ios-xr-string {
+                  length "0..32";
+                }
+                description "Attach IGMP Snooping Profile Name";
+              }
+              leaf flooding {
+                xr:xr-xml-map "l2vpn_cfg:Flooding";
+                xr:xr-cli-map "l2vpn bridge group <string> bridge-d"+
+                  "omain <string> flooding [disable] ";
+                type empty;
+                description "Disable flooding";
+              }
+              leaf name {
+                xr:xr-xml-map "l2vpn_cfg:Name";
+                type xr:Cisco-ios-xr-string {
+                  length "0..27";
+                }
+                description "Name of the bridge domain";
+              }
+            }
+          }
+          leaf name {
+            xr:xr-xml-map "l2vpn_cfg:Name";
+            type xr:Cisco-ios-xr-string {
+              length "0..32";
+            }
+            description "Name of the Bridge group";
+          }
+        }
+      }
+
+      container pseudowire-classes {
+        xr:xr-xml-map "l2vpn_cfg:PseudowireClassTable";
+        description "List of pseudowire classes";
+
+        list pseudowire-class {
+          xr:xr-xml-map "l2vpn_cfg:PseudowireClass";
+          key "name";
+          description "Pseudowire class";
+
+          container l2tpv3-encapsulation {
+            xr:xr-xml-map "l2vpn_cfg:L2TPv3Encapsulation";
+            description "L2TPv3 encapsulation";
+
+            container sequencing {
+              xr:xr-xml-map "l2vpn_cfg:Sequencing";
+              description "Sequencing";
+              leaf sequencing {
+                xr:xr-xml-map "l2vpn_cfg:Sequencing";
+                type L2tpv3-sequencing;
+                default "off";
+                description "Sequencing";
+              }
+              leaf resync-threshold {
+                xr:xr-xml-map "l2vpn_cfg:ResyncThreshold";
+                type Resync-threshold-range;
+                default "5";
+                description "Out of sequence threshold";
+              }
+            }
+
+            container type-of-service {
+              xr:xr-xml-map "l2vpn_cfg:TypeOfService";
+              description "Type of service";
+              leaf type-of-service-value {
+                xr:xr-xml-map "l2vpn_cfg:TypeOfServiceValue";
+                type Type-of-service-range;
+                description "Type of service value";
+              }
+              leaf type-of-service-mode {
+                xr:xr-xml-map "l2vpn_cfg:TypeOfServiceMode";
+                type Type-of-service-mode;
+                description "Type of service mode";
+              }
+            }
+
+            container signaling-protocol {
+              xr:xr-xml-map "l2vpn_cfg:SignalingProtocol";
+              description "L2TPv3 signaling protocol";
+              leaf protocol {
+                xr:xr-xml-map "l2vpn_cfg:Protocol";
+                type L2tp-signaling-protocol;
+                default "l2tpv3";
+                description "L2TPv3 signaling protocol";
+              }
+              leaf l2tpv3-class-name {
+                xr:xr-xml-map "l2vpn_cfg:L2TPv3ClassName";
+                type xr:Cisco-ios-xr-string {
+                  length "0..32";
+                }
+                description "Name of the L2TPv3 class name";
+              }
+            }
+
+            container path-mtu {
+              xr:xr-xml-map "l2vpn_cfg:PathMTU";
+              description "Path maximum transmission unit";
+              leaf enable {
+                xr:xr-xml-map "l2vpn_cfg:Enable";
+                type empty;
+                description "Enable path MTU";
+              }
+              leaf max-path-mtu {
+                xr:xr-xml-map "l2vpn_cfg:MaxPathMTU";
+                type Max-path-mtu-range;
+                description
+                  "Maximum path maximum transmission unit";
+              }
+            }
+            leaf df-bit-set {
+              xr:xr-xml-map "l2vpn_cfg:DFBitSet";
+              xr:xr-cli-map "dfbit set ";
+              type empty;
+              description "Set the do not fragment bit to 1";
+            }
+            leaf cookie-size {
+              xr:xr-xml-map "l2vpn_cfg:CookieSize";
+              xr:xr-cli-map "cookie size (0)|(4)|(8) ";
+              type L2tp-cookie-size;
+              default "zero";
+              description "Cookie size";
+            }
+            leaf source-address {
+              xr:xr-xml-map "l2vpn_cfg:SourceAddress";
+              xr:xr-cli-map "ipv4 source <IPv4 address> ";
+              type inet:ipv4-address-no-zone;
+              description "Source IP address";
+            }
+            leaf transport-mode {
+              xr:xr-xml-map "l2vpn_cfg:TransportMode";
+              xr:xr-cli-map "transport-mode (ethernet)|(vlan) ";
+              type Transport-mode;
+              description "Transport mode";
+            }
+            leaf enable {
+              xr:xr-xml-map "l2vpn_cfg:Enable";
+              type empty;
+              description "Enable L2TPv3 encapsulation";
+            }
+            leaf time-to-live {
+              xr:xr-xml-map "l2vpn_cfg:TimeToLive";
+              xr:xr-cli-map "ttl <number> ";
+              type Time-to-live-range;
+              description "Time to live";
+            }
+          }
+
+          container backup-disable-delay {
+            xr:xr-xml-map "l2vpn_cfg:BackupDisableDelay";
+            description "Back Up Pseudowire class";
+            leaf type {
+              xr:xr-xml-map "l2vpn_cfg:Type";
+              type Backup-disable;
+              description "Delay or Never";
+            }
+            leaf disable-backup {
+              xr:xr-xml-map "l2vpn_cfg:DisableBackup";
+              when "../type = 'delay'" {
+                description "../Type = Delay";
+              }
+              type Backup-disable-delay-range;
+              description "Disable backup delay";
+            }
+          }
+
+          container mpls-encapsulation {
+            xr:xr-xml-map "l2vpn_cfg:MPLSEncapsulation";
+            description "MPLS encapsulation";
+
+            container sequencing {
+              xr:xr-xml-map "l2vpn_cfg:Sequencing";
+              description "Sequencing";
+              leaf sequencing {
+                xr:xr-xml-map "l2vpn_cfg:Sequencing";
+                type Mpls-sequencing;
+                default "off";
+                description "Sequencing";
+              }
+              leaf resync-threshold {
+                xr:xr-xml-map "l2vpn_cfg:ResyncThreshold";
+                type Resync-threshold-range;
+                default "5";
+                description "Out of sequence threshold";
+              }
+            }
+
+            container mpls-redundancy {
+              xr:xr-xml-map "l2vpn_cfg:MPLSRedundancy";
+              description
+                "Redundancy options for MPLS encapsulation";
+              leaf redundancy-one-way {
+                xr:xr-xml-map "l2vpn_cfg:RedundancyOneWay";
+                xr:xr-cli-map "one-way ";
+                type empty;
+                description
+                  "Force one-way PW redundancy behavior in
+                  Redundancy Group";
+              }
+              leaf redundancy-initial-delay {
+                xr:xr-xml-map "l2vpn_cfg:RedundancyInitialDelay";
+                xr:xr-cli-map "initial-delay <number> ";
+                type Pw-redundancy-initial-delay-range;
+                units "second";
+                description
+                  "Initial delay before activating the
+                  redundant PW, in seconds";
+              }
+            }
+
+            container preferred-path {
+              xr:xr-xml-map "l2vpn_cfg:PreferredPath";
+              description "Preferred path";
+              leaf type {
+                xr:xr-xml-map "l2vpn_cfg:Type";
+                type Preferred-path;
+                description "Preferred Path Type";
+              }
+              leaf interface-tunnel-number {
+                xr:xr-xml-map "l2vpn_cfg:InterfaceTunnelNumber";
+                type uint32 {
+                  range "0..65535";
+                }
+                description
+                  "Interface Tunnel number for preferred path";
+              }
+              leaf fallback-disable {
+                xr:xr-xml-map "l2vpn_cfg:FallbackDisable";
+                type empty;
+                description "Fallback disable";
+              }
+            }
+
+            container load-balance-group {
+              xr:xr-xml-map "l2vpn_cfg:LoadBalanceGroup";
+              description "Load Balancing";
+
+              container flow-label-load-balance {
+                xr:xr-xml-map "l2vpn_cfg:FlowLabelLoadBalance";
+                description
+                  "Enable Flow Label based load balancing";
+                leaf flow-label {
+                  xr:xr-xml-map "l2vpn_cfg:FlowLabel";
+                  type Flow-label-load-balance;
+                  description "Flow Label load balance type";
+                }
+                leaf static {
+                  xr:xr-xml-map "l2vpn_cfg:Static";
+                  type empty;
+                  description "Static Flow Label";
+                }
+              }
+              leaf flow-label-load-balance-code {
+                xr:xr-xml-map "l2vpn_cfg:FlowLabelLoadBalanceCode";
+                xr:xr-cli-map "flow-label code 17 (disable) ";
+                type Flow-label-tlv-code;
+                description "Enable Legacy Flow Label TLV code";
+              }
+              leaf pw-label-load-balance {
+                xr:xr-xml-map "l2vpn_cfg:PWLabelLoadBalance";
+                xr:xr-cli-map "pw-label ";
+                type Load-balance;
+                description "Enable PW Label based Load Balancing";
+              }
+            }
+            leaf pw-switching-tlv {
+              xr:xr-xml-map "l2vpn_cfg:PWSwitchingTlv";
+              xr:xr-cli-map "l2vpn pw-class <string> encapsulation "+
+                "mpls switching-tlv hide ";
+              type Pw-switching-point-tlv;
+              description "Pseudowire Switching Point Tlv";
+            }
+            leaf static-tag-rewrite {
+              xr:xr-xml-map "l2vpn_cfg:StaticTagRewrite";
+              xr:xr-cli-map "l2vpn pw-class <string> encapsulation "+
+                "mpls tag-rewrite [ingress [vlan <number>]] ";
+              type Tag-rewrite-range;
+              description "Static Tag rewrite";
+            }
+            leaf signaling-protocol {
+              xr:xr-xml-map "l2vpn_cfg:SignalingProtocol";
+              xr:xr-cli-map "l2vpn pw-class <string> encapsulation "+
+                "mpls protocol ldp ";
+              type Mpls-signaling-protocol;
+              default "ldp";
+              description "MPLS signaling protocol";
+            }
+            leaf vccv-type {
+              xr:xr-xml-map "l2vpn_cfg:VCCVType";
+              xr:xr-cli-map "l2vpn pw-class <string> encapsulation "+
+                "mpls vccv verification-type none ";
+              type Vccv-verification;
+              default "lsp-ping";
+              description "VCCV verification type";
+            }
+            leaf source-address {
+              xr:xr-xml-map "l2vpn_cfg:SourceAddress";
+              xr:xr-cli-map "l2vpn pw-class <string> encapsulation "+
+                "mpls ipv4 source <IPv4 address> ";
+              type inet:ipv4-address-no-zone;
+              description "Source IP address";
+            }
+            leaf transport-mode {
+              xr:xr-xml-map "l2vpn_cfg:TransportMode";
+              xr:xr-cli-map "l2vpn pw-class <string> encapsulation "+
+                "mpls transport-mode (ethernet)|(vlan (passthrough)"+
+                ") ";
+              type Transport-mode;
+              description "Transport mode";
+            }
+            leaf enable {
+              xr:xr-xml-map "l2vpn_cfg:Enable";
+              type empty;
+              description "Enable MPLS encapsulation";
+            }
+            leaf control-word {
+              xr:xr-xml-map "l2vpn_cfg:ControlWord";
+              xr:xr-cli-map "l2vpn pw-class <string> encapsulation "+
+                "mpls control-word disable ";
+              type Control-word;
+              description "Enable control word";
+            }
+          }
+          leaf mac-withdraw {
+            xr:xr-xml-map "l2vpn_cfg:MACWithdraw";
+            xr:xr-cli-map "l2vpn pw-class <string> mac-withdraw ";
+            type empty;
+            description "Enable backup MAC withdraw";
+          }
+          leaf enable {
+            xr:xr-xml-map "l2vpn_cfg:Enable";
+            type empty;
+            description "Enable pseudowire class";
+          }
+          leaf name {
+            xr:xr-xml-map "l2vpn_cfg:Name";
+            type xr:Cisco-ios-xr-string {
+              length "0..32";
+            }
+            description "Name of the pseudowire class";
+          }
+        }
+      }
+
+      container redundancy {
+        xr:xr-xml-map "l2vpn_cfg:Redundancy";
+        description "Redundancy groups";
+
+        container iccp-redundancy-groups {
+          xr:xr-xml-map "l2vpn_cfg:ICCPGroupTable";
+          description
+            "List of Inter-Chassis Communication Protocol
+            redundancy groups";
+
+          list iccp-redundancy-group {
+            xr:xr-xml-map "l2vpn_cfg:ICCPRedundancyGroup";
+            key "group-id";
+            description "ICCP Redundancy group";
+
+            container iccp-interfaces {
+              xr:xr-xml-map "l2vpn_cfg:ICCPInterfaceTable";
+              description "List of interfaces";
+
+              list iccp-interface {
+                xr:xr-xml-map "l2vpn_cfg:ICCPInterface";
+                key "interface-name";
+                description "Interface name";
+                leaf secondary-vlan-range {
+                  xr:xr-xml-map "l2vpn_cfg:SecondaryVLANRange";
+                  xr:xr-cli-map "l2vpn redundancy iccp group <numbe"+
+                    "r> interface <interface> secondary vlan <strin"+
+                    "g> ";
+                  type string;
+                  description
+                    "Secondary VLAN range, in the form of 1-3,5
+                    ,8-11";
+                }
+                leaf recovery-delay {
+                  xr:xr-xml-map "l2vpn_cfg:RecoveryDelay";
+                  xr:xr-cli-map "l2vpn redundancy iccp group <numbe"+
+                    "r> interface <interface> recovery delay <numbe"+
+                    "r> ";
+                  type uint32 {
+                    range "30..3600";
+                  }
+                  default "180";
+                  description "Failure clear recovery delay";
+                }
+                leaf primary-vlan-range {
+                  xr:xr-xml-map "l2vpn_cfg:PrimaryVLANRange";
+                  xr:xr-cli-map "l2vpn redundancy iccp group <numbe"+
+                    "r> interface <interface> primary vlan <string>"+
+                    " ";
+                  type string;
+                  description
+                    "Primary VLAN range, in the form of 1-3,5
+                    ,8-11";
+                }
+                leaf mac-flush-tcn {
+                  xr:xr-xml-map "l2vpn_cfg:MACFlushTCN";
+                  xr:xr-cli-map "l2vpn redundancy iccp group <numbe"+
+                    "r> interface <interface> mac-flush stp-tcn ";
+                  type empty;
+                  description "Enable STP-TCN MAC flushing";
+                }
+                leaf interface-name {
+                  xr:xr-xml-map "l2vpn_cfg:InterfaceName";
+                  type xr:Interface-name;
+                  description "Interface name";
+                }
+              }
+            }
+            leaf multi-homing-node-id {
+              xr:xr-xml-map "l2vpn_cfg:MultiHomingNodeID";
+              xr:xr-cli-map "l2vpn redundancy iccp group <number> m"+
+                "ulti-homing node-id <number> ";
+              type uint32 {
+                range "0..254";
+              }
+              description "ICCP-based service multi-homing node ID";
+            }
+            leaf group-id {
+              xr:xr-xml-map "l2vpn_cfg:GroupID";
+              type int32;
+              description "Group ID";
+            }
+          }
+        }
+        leaf enable {
+          xr:xr-xml-map "l2vpn_cfg:Enable";
+          type empty;
+          description "Enable redundancy groups";
+        }
+      }
+    }
+
+    container pbb {
+      xr:xr-xml-map "l2vpn_cfg:PBB";
+      description "L2VPN PBB Global";
+      leaf backbone-source-mac {
+        xr:xr-xml-map "l2vpn_cfg:BackboneSourceMAC";
+        type yang:mac-address;
+        description "Backbone Source MAC";
+      }
+    }
+
+    container auto-discovery {
+      xr:xr-xml-map "l2vpn_cfg:AutoDiscovery";
+      description "Global auto-discovery attributes";
+
+      container bgp-signaling {
+        xr:xr-xml-map "l2vpn_cfg:BGPSignaling";
+        description "Global bgp signaling attributes";
+        leaf mtu-mismatch-ignore {
+          xr:xr-xml-map "l2vpn_cfg:MTUMismatchIgnore";
+          xr:xr-cli-map "l2vpn autodiscovery bgp signaling-protocol"+
+            " bgp mtu mismatch ignore ";
+          type empty;
+          description
+            "Ignore MTU mismatch for auto-discovered
+            pseudowires";
+        }
+      }
+    }
+
+    container utility {
+      xr:xr-xml-map "l2vpn_cfg:Utility";
+      description "L2VPN utilities";
+
+      container logging {
+        xr:xr-xml-map "l2vpn_cfg:Logging";
+        description "L2VPN logging utility";
+        leaf bridge-domain-state-change {
+          xr:xr-xml-map "l2vpn_cfg:BridgeDomainStateChange";
+          xr:xr-cli-map "l2vpn logging bridge-domain [status] ";
+          type empty;
+          description "Enable Bridge Domain state change logging";
+        }
+        leaf pseudowire-state-change {
+          xr:xr-xml-map "l2vpn_cfg:PseudowireStateChange";
+          xr:xr-cli-map "l2vpn logging pseudowire [status] ";
+          type empty;
+          description "Enable pseudowire state change logging";
+        }
+        leaf vfi {
+          xr:xr-xml-map "l2vpn_cfg:VFI";
+          xr:xr-cli-map "l2vpn logging vfi [status] ";
+          type empty;
+          description "Enable VFI state change logging";
+        }
+        leaf nsr-state-change {
+          xr:xr-xml-map "l2vpn_cfg:NSRStateChange";
+          xr:xr-cli-map "l2vpn logging nsr ";
+          type empty;
+          description
+            "Enable Non Stop Routing state change logging";
+        }
+        leaf pwhe-replication-state-change {
+          xr:xr-xml-map "l2vpn_cfg:PWHEReplicationStateChange";
+          xr:xr-cli-map "l2vpn logging pwhe-replication disable ";
+          type empty;
+          description
+            "Enable PW-HE Replication state change logging";
+        }
+      }
+    }
+
+    container snmp {
+      xr:xr-xml-map "l2vpn_cfg:SNMP";
+      description "SNMP related configuration";
+
+      container mib {
+        xr:xr-xml-map "l2vpn_cfg:MIB";
+        description "MIB related configuration";
+
+        container mib-interface {
+          xr:xr-xml-map "l2vpn_cfg:MIBInterface";
+          description "Interface related configuration for MIB";
+
+          container format {
+            xr:xr-xml-map "l2vpn_cfg:Format";
+            description "MIB interface name output format";
+            leaf external-interface-format {
+              xr:xr-xml-map "l2vpn_cfg:ExternalInterfaceFormat";
+              xr:xr-cli-map "l2vpn snmp mib interface format extern"+
+                "al ";
+              type empty;
+              description
+                "Set MIB interface name output in slash
+                format (/)";
+            }
+          }
+        }
+
+        container mib-pseudowire {
+          xr:xr-xml-map "l2vpn_cfg:MIBPseudowire";
+          description "Pseudowire related configuration for MIB";
+          leaf statistics {
+            xr:xr-xml-map "l2vpn_cfg:Statistics";
+            xr:xr-cli-map "l2vpn snmp mib pseudowire statistics ";
+            type empty;
+            description
+              "Enable pseudowire statistics in MIB output";
+          }
+        }
+      }
+    }
+    leaf nsr {
+      xr:xr-xml-map "l2vpn_cfg:NSR";
+      xr:xr-cli-map "l2vpn nsr ";
+      type empty;
+      description "Enable Non-Stop Routing";
+    }
+    leaf mtu-mismatch-ignore {
+      xr:xr-xml-map "l2vpn_cfg:MTUMismatchIgnore";
+      xr:xr-cli-map "l2vpn ignore-mtu-mismatch ";
+      type empty;
+      description "Ignore MTU Mismatch for XCs";
+    }
+    leaf tcn-propagation {
+      xr:xr-xml-map "l2vpn_cfg:TCNPropagation";
+      xr:xr-cli-map "l2vpn tcn-propagation ";
+      type empty;
+      description "Topology change notification propagation";
+    }
+    leaf pwoam-refresh {
+      xr:xr-xml-map "l2vpn_cfg:PWOAMRefresh";
+      xr:xr-cli-map "l2vpn pw-oam refresh transmit <number> ";
+      type uint32 {
+        range "1..4095";
+      }
+      units "second";
+      description "Configure PW OAM refresh interval";
+    }
+    leaf load-balance {
+      xr:xr-xml-map "l2vpn_cfg:LoadBalance";
+      xr:xr-cli-map "l2vpn load-balancing [flow (src-dst-mac)|(src-"+
+        "dst-ip)] ";
+      type Load-balance;
+      description "Enable flow load balancing on l2vpn bridges";
+    }
+    leaf mspw-description {
+      xr:xr-xml-map "l2vpn_cfg:MSPWDescription";
+      xr:xr-cli-map "l2vpn description <string> ";
+      type xr:Cisco-ios-xr-string {
+        length "0..64";
+      }
+      description "MS-PW global description";
+    }
+    leaf pw-status-disable {
+      xr:xr-xml-map "l2vpn_cfg:PWStatusDisable";
+      xr:xr-cli-map "l2vpn pw-status disable ";
+      type empty;
+      description "Disable PW status";
+    }
+    leaf enable {
+      xr:xr-xml-map "l2vpn_cfg:Enable";
+      type empty;
+      description "Enable L2VPN feature";
+    }
+    leaf pw-grouping {
+      xr:xr-xml-map "l2vpn_cfg:PWGrouping";
+      xr:xr-cli-map "l2vpn pw-grouping ";
+      type empty;
+      description "Enable PW grouping";
+    }
+    leaf capability {
+      xr:xr-xml-map "l2vpn_cfg:Capability";
+      xr:xr-cli-map "l2vpn capability (single-mode)|(high-mode) ";
+      type L2vpn-capability-mode;
+      description "L2VPN Capability Mode";
+    }
+    leaf l2vpn-router-id {
+      xr:xr-xml-map "l2vpn_cfg:L2VPNRouterID";
+      xr:xr-cli-map "l2vpn router-id <IPv4 address> ";
+      type inet:ipv4-address-no-zone;
+      description "Global L2VPN Router ID";
+    }
+  }
+
+  container generic-interface-lists {
+    xr:xr-xml-map "iflist_cfg:GenericInterfaceListTable";
+    description "generic interface lists";
+
+    list generic-interface {
+      xr:xr-xml-map "iflist_cfg:GenericInterfaceList";
+      key "generic-interface-list-name";
+      description "Bridge group";
+
+      container interfaces {
+        xr:xr-xml-map "iflist_cfg:InterfaceTable";
+        description "Interface table";
+
+        list interface {
+          xr:xr-xml-map "iflist_cfg:Interface";
+          key "interface-name";
+          description "Interface";
+          leaf enable {
+            xr:xr-xml-map "iflist_cfg:Enable";
+            xr:xr-cli-map "generic-interface-list <string> interfac"+
+              "e (<interface>)|(<interface>) ";
+            type empty;
+            description "Enable interface";
+          }
+          leaf interface-name {
+            xr:xr-xml-map "iflist_cfg:InterfaceName";
+            type xr:Interface-name;
+            description "Name of the interface";
+          }
+        }
+      }
+      leaf enable {
+        xr:xr-xml-map "iflist_cfg:Enable";
+        type empty;
+        description "Enable interface list";
+      }
+      leaf generic-interface-list-name {
+        xr:xr-xml-map "iflist_cfg:GenericInterfaceListName";
+        type xr:Cisco-ios-xr-string {
+          length "0..32";
+        }
+        description "Name of the interface list";
+      }
+    }
+  }
+
+  container evpn {
+    xr:xr-xml-map "l2vpn_cfg:EVPN";
+    description "evpn";
+
+    container evpn-tables {
+      xr:xr-xml-map "l2vpn_cfg:EVPNTables";
+      description "EVPN submodes";
+
+      container evpn-timers {
+        xr:xr-xml-map "l2vpn_cfg:EVPNTimers";
+        description "Enter EVPN timers configuration submode";
+        leaf evpn-programming {
+          xr:xr-xml-map "l2vpn_cfg:EVPNProgramming";
+          type uint32 {
+            range "0..100000";
+          }
+          default "1500";
+          description "Global Programming timer";
+        }
+        leaf evpn-flush-again {
+          xr:xr-xml-map "l2vpn_cfg:EVPNFlushAgain";
+          type uint32 {
+            range "0..120";
+          }
+          default "60";
+          description "Global MAC Flush again timer";
+        }
+        leaf evpn-recovery {
+          xr:xr-xml-map "l2vpn_cfg:EVPNRecovery";
+          xr:xr-cli-map "recovery <number> ";
+          type uint32 {
+            range "20..3600";
+          }
+          default "30";
+          description "Global Recovery timer";
+        }
+        leaf enable {
+          xr:xr-xml-map "l2vpn_cfg:Enable";
+          type empty;
+          description "Enable EVPN timers";
+        }
+        leaf evpn-peering {
+          xr:xr-xml-map "l2vpn_cfg:EVPNPeering";
+          xr:xr-cli-map "peering <number> ";
+          type uint32 {
+            range "0..300";
+          }
+          default "3";
+          description "Global Peering timer";
+        }
+      }
+
+      container evpnevis {
+        xr:xr-xml-map "l2vpn_cfg:EVPNEVIMode";
+        description "Enter EVPN EVI configuration submode";
+
+        list evpnevi {
+          xr:xr-xml-map "l2vpn_cfg:EVPNEVI";
+          key "eviid";
+          description "Enter EVPN EVI configuration submode";
+
+          container evi-load-balancing {
+            xr:xr-xml-map "l2vpn_cfg:EVILoadBalancing";
+            description
+              "Enter EVI Loadbalancing configuration submode";
+            leaf evi-flow-label {
+              xr:xr-xml-map "l2vpn_cfg:EVIFlowLabel";
+              xr:xr-cli-map "flow-label static ";
+              type empty;
+              description "Enable Flow Label based load balancing";
+            }
+            leaf enable {
+              xr:xr-xml-map "l2vpn_cfg:Enable";
+              type empty;
+              description "Enable EVI Loadbalancing";
+            }
+          }
+
+          container evpnevibgp-auto-discovery {
+            xr:xr-xml-map "l2vpn_cfg:EVPNEVIBGPAutoDiscovery";
+            description "Enable Autodiscovery BGP in EVPN EVI";
+
+            container evpn-route-targets {
+              xr:xr-xml-map "l2vpn_cfg:EVPNRouteTargetTable";
+              description "Route Target";
+
+              list evpn-route-target {
+                xr:xr-xml-map "l2vpn_cfg:EVPNRouteTarget";
+                must "two-byte-as-or-four-byte-as or ipv4-address" {
+                  description
+                    "TwoByteAS-or-FourbyteAS or IPV4Address
+                    must be present.";
+                }
+                key "role format";
+                description "Name of the Route Target";
+                leaf role {
+                  xr:xr-xml-map "l2vpn_cfg:Role";
+                  type Bgp-route-target-role;
+                  description "Role of the router target type";
+                }
+                leaf format {
+                  xr:xr-xml-map "l2vpn_cfg:Format";
+                  type Bgp-route-target-format;
+                  description "Format of the route target";
+                }
+
+                list two-byte-as-or-four-byte-as {
+                  when "../format = 'two-byte-as' or ../format ="+
+                    " 'four-byte-as'" {
+                      description
+                        "../Format = TwoByteAS or ../Format =
+                        FourbyteAS";
+                  }
+                  key "as as-index";
+                  description "two byte as or four byte as";
+                  leaf as {
+                    xr:xr-xml-map "l2vpn_cfg:AS";
+                    type Rdas-range;
+                    description "Two byte or 4 byte AS number";
+                  }
+                  leaf as-index {
+                    xr:xr-xml-map "l2vpn_cfg:ASIndex";
+                    type Rdas-index;
+                    description "AS:nn (hex or decimal format)";
+                  }
+                }
+
+                list ipv4-address {
+                  when "../format = 'ipv4-address'" {
+                    description "../Format = IPV4Address";
+                  }
+                  key "address addr-index";
+                  description "ipv4 address";
+                  leaf address {
+                    xr:xr-xml-map "l2vpn_cfg:Address";
+                    type inet:ipv4-address-no-zone;
+                    description "IPV4 address";
+                  }
+                  leaf addr-index {
+                    xr:xr-xml-map "l2vpn_cfg:AddrIndex";
+                    type Rd-addr-index;
+                    description "Addr index";
+                  }
+                }
+              }
+            }
+            leaf enable {
+              xr:xr-xml-map "l2vpn_cfg:Enable";
+              type empty;
+              description "Enable Autodiscovery BGP";
+            }
+            uses EVPN-ROUTE-DISTINGUISHER;
+          }
+          leaf eviid {
+            xr:xr-xml-map "l2vpn_cfg:EVIID";
+            type Vpnid-range;
+            description "EVI ID";
+          }
+        }
+      }
+
+      container evpn-load-balancing {
+        xr:xr-xml-map "l2vpn_cfg:EVPNLoadBalancing";
+        description
+          "Enter EVPN Loadbalancing configuration submode";
+        leaf evpn-flow-label {
+          xr:xr-xml-map "l2vpn_cfg:EVPNFlowLabel";
+          xr:xr-cli-map "flow-label static ";
+          type empty;
+          description "Enable Flow Label based load balancing";
+        }
+        leaf enable {
+          xr:xr-xml-map "l2vpn_cfg:Enable";
+          type empty;
+          description "Enable EVPN Loadbalancing";
+        }
+      }
+
+      container evpnbgp-auto-discovery {
+        xr:xr-xml-map "l2vpn_cfg:EVPNBGPAutoDiscovery";
+        description "Enable Autodiscovery BGP in EVPN";
+        leaf enable {
+          xr:xr-xml-map "l2vpn_cfg:Enable";
+          type empty;
+          description "Enable Autodiscovery BGP";
+        }
+        uses EVPN-ROUTE-DISTINGUISHER;
+      }
+
+      container evpn-interfaces {
+        xr:xr-xml-map "l2vpn_cfg:EVPNInterfaceTable";
+        description "Attachment Circuit interfaces";
+
+        list evpn-interface {
+          xr:xr-xml-map "l2vpn_cfg:EVPNInterface";
+          key "interface-name";
+          description "Attachment circuit interface";
+
+          container evpnac-timers {
+            xr:xr-xml-map "l2vpn_cfg:EVPNACTimers";
+            description
+              "Enter Interface-specific timers configuration
+              submode";
+            leaf evpnac-flush-again {
+              xr:xr-xml-map "l2vpn_cfg:EVPNACFlushAgain";
+              type uint32 {
+                range "0..120";
+              }
+              default "60";
+              description
+                "Interface-specific MAC Flush again timer";
+            }
+            leaf enable {
+              xr:xr-xml-map "l2vpn_cfg:Enable";
+              type empty;
+              description "Enable Interface-specific timers";
+            }
+            leaf evpnac-recovery {
+              xr:xr-xml-map "l2vpn_cfg:EVPNACRecovery";
+              xr:xr-cli-map "recovery <number> ";
+              type uint32 {
+                range "20..3600";
+              }
+              default "30";
+              description "Interface-specific Recovery timer";
+            }
+          }
+
+          container ethernet-segment {
+            xr:xr-xml-map "l2vpn_cfg:EthernetSegment";
+            description
+              "Enter Ethernet Segment configuration submode";
+
+            container identifier-type0 {
+              xr:xr-xml-map "l2vpn_cfg:IdentifierType0";
+              description "Ethernet segment identifier (Type 0)";
+              leaf bytes1 {
+                xr:xr-xml-map "l2vpn_cfg:Bytes1";
+                type xr:Hex-integer;
+                description "Type 0's 1st Byte";
+              }
+              leaf bytes23 {
+                xr:xr-xml-map "l2vpn_cfg:Bytes23";
+                type xr:Hex-integer;
+                units "byte";
+                description "Type 0's 2nd and 3rd Bytes";
+              }
+              leaf bytes45 {
+                xr:xr-xml-map "l2vpn_cfg:Bytes45";
+                type xr:Hex-integer;
+                units "byte";
+                description "Type 0's 4th and 5th Bytes";
+              }
+              leaf bytes67 {
+                xr:xr-xml-map "l2vpn_cfg:Bytes67";
+                type xr:Hex-integer;
+                units "byte";
+                description "Type 0's 6th and 7th Bytes";
+              }
+              leaf bytes89 {
+                xr:xr-xml-map "l2vpn_cfg:Bytes89";
+                type xr:Hex-integer;
+                units "byte";
+                description "Type 0's 8th and 9th Bytes";
+              }
+            }
+
+            container manual-service-carving {
+              xr:xr-xml-map "l2vpn_cfg:ManualServiceCarving";
+              description
+                "Enter Manual service carving configuration
+                submode";
+
+              container service-list {
+                xr:xr-xml-map "l2vpn_cfg:ServiceList";
+                description
+                  "Manual service carving primary,secondary
+                  lists";
+                leaf primary {
+                  xr:xr-xml-map "l2vpn_cfg:Primary";
+                  type string {
+                    length "0..150";
+                  }
+                  description "Primary services list";
+                }
+                leaf secondary {
+                  xr:xr-xml-map "l2vpn_cfg:Secondary";
+                  type string {
+                    length "0..150";
+                  }
+                  description "Secondary services list";
+                }
+              }
+              leaf enable {
+                xr:xr-xml-map "l2vpn_cfg:Enable";
+                type empty;
+                description "Enable Manual service carving";
+              }
+            }
+            leaf force-single-homed {
+              xr:xr-xml-map "l2vpn_cfg:ForceSingleHomed";
+              xr:xr-cli-map "force single-homed ";
+              type empty;
+              description
+                "Force ethernet segment to remain
+                single-homed";
+            }
+            leaf load-balancing-per-service {
+              xr:xr-xml-map "l2vpn_cfg:LoadBalancingPerService";
+              xr:xr-cli-map "load-balancing-mode (per-service)|(sin"+
+                "gle-active) ";
+              type empty;
+              description "Enable per service load balancing mode";
+            }
+            leaf es-import-route-target {
+              xr:xr-xml-map "l2vpn_cfg:ESImportRouteTarget";
+              type yang:mac-address;
+              description "ES-Import Route Target";
+            }
+            leaf enable {
+              xr:xr-xml-map "l2vpn_cfg:Enable";
+              type empty;
+              description "Enable Ethernet Segment";
+            }
+            leaf backbone-source-mac {
+              xr:xr-xml-map "l2vpn_cfg:BackboneSourceMAC";
+              type yang:mac-address;
+              description "Backbone Source MAC";
+            }
+          }
+          leaf mac-flush {
+            xr:xr-xml-map "l2vpn_cfg:MACFlush";
+            xr:xr-cli-map "evpn interface (<interface>)|(<interface"+
+              ">) mac-flush mvrp ";
+            type empty;
+            description "Enable MVRP MAC Flush mode";
+          }
+          leaf interface-name {
+            xr:xr-xml-map "l2vpn_cfg:InterfaceName";
+            type xr:Interface-name;
+            description "Name of the attachment circuit interface";
+          }
+        }
+      }
+    }
+
+    container standard-version {
+      xr:xr-xml-map "l2vpn_cfg:StandardVersion";
+      description "Set Standard EVPN Version";
+      leaf draft-04 {
+        xr:xr-xml-map "l2vpn_cfg:Draft-04";
+        xr:xr-cli-map "evpn standard-version draft-04 ";
+        type empty;
+        description "Set IETF Draft version to 04";
+      }
+    }
+    leaf enable {
+      xr:xr-xml-map "l2vpn_cfg:Enable";
+      type empty;
+      description "Enable EVPN feature";
+    }
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration" {
+
+    container pseudowire-ether {
+      xr:xr-xml-map "l2vpn_pw_ether_cfg:PseudowireEther";
+      description "PW-Ether attributes";
+      leaf generic-interface-list {
+        xr:xr-xml-map "l2vpn_pw_ether_cfg:GenericInterfaceList";
+        type xr:Cisco-ios-xr-string {
+          length "0..32";
+        }
+        description "Name of the interface list";
+      }
+      leaf l2-overhead {
+        xr:xr-xml-map "l2vpn_pw_ether_cfg:L2Overhead";
+        type uint32 {
+          range "1..64";
+        }
+        description "PW Ether L2 overhead requirement";
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-ifmgr-cfg'";
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration" {
+
+    container pseudowire-iw {
+      xr:xr-xml-map "l2vpn_pw_iw_cfg:PseudowireIW";
+      description "PW-IW attributes";
+      leaf l2-overhead {
+        xr:xr-xml-map "l2vpn_pw_iw_cfg:L2Overhead";
+        type uint32 {
+          range "1..64";
+        }
+        units "byte";
+        description "L2 overhead size in bytes";
+      }
+      leaf generic-interface-list {
+        xr:xr-xml-map "l2vpn_pw_iw_cfg:GenericInterfaceList";
+        type xr:Cisco-ios-xr-string {
+          length "0..32";
+        }
+        description "Name of the interface list";
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-ifmgr-cfg'";
+  }
+
+  augment "/a1:interface-configurations/a1:interface-configuration" {
+
+    container l2-transport {
+      xr:xr-xml-map "l2vpn_ac_l2transport_cfg:L2Transport";
+      description
+        "Interface Layer 2 Transport service
+        configuration data";
+      leaf enabled {
+        xr:xr-xml-map "l2vpn_ac_l2transport_cfg:Enabled";
+        type empty;
+        description
+          "This object is only valid on physical
+          interfaces and it controls whether that
+          interface is a port mode Layer 2 attachment
+          circuit (note that for subinterfaces, the Layer
+          2 property is specified when the subinterface
+          is created).The object must be set before any
+          other L2Transport configuration is supplied for
+          the interface, and must be the last
+          per-interface configuration object to be
+          removed.";
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-ifmgr-cfg'";
+  }
+
+  augment "/a2:snmp/a2:notification" {
+
+    container vpls {
+      xr:xr-xml-map "vplsmib_cfg:VPLS";
+      description
+        "CISCO-IETF-VPLS-GENERIC-MIB notification
+        configuration";
+      leaf full-clear {
+        xr:xr-xml-map "vplsmib_cfg:FullClear";
+        type empty;
+        description "Enable cvplsFwdFullAlarmCleared notification";
+      }
+      leaf status {
+        xr:xr-xml-map "vplsmib_cfg:Status";
+        type empty;
+        description "Enable cvplsStatusChanged notification";
+      }
+      leaf enable {
+        xr:xr-xml-map "vplsmib_cfg:Enable";
+        type empty;
+        description
+          "Enable CISCO-IETF-VPLS-GENERIC-MIB
+          notifications";
+      }
+      leaf full-raise {
+        xr:xr-xml-map "vplsmib_cfg:FullRaise";
+        type empty;
+        description "Enable cvplsFwdFullAlarmRaised notification";
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-snmp-agent-cfg'";
+  }
+
+  augment "/a2:snmp/a2:notification" {
+
+    container l2vpn {
+      xr:xr-xml-map "pwmib_cfg:L2VPN";
+      description "CISCO-IETF-PW-MIB notification configuration";
+      leaf cisco {
+        xr:xr-xml-map "pwmib_cfg:Cisco";
+        type empty;
+        description "Enable Cisco format including extra varbinds";
+      }
+      leaf enable {
+        xr:xr-xml-map "pwmib_cfg:Enable";
+        type empty;
+        description "Enable CISCO-IETF-PW-MIB notifications";
+      }
+      leaf vc-down {
+        xr:xr-xml-map "pwmib_cfg:VCDown";
+        type empty;
+        description "Enable cpwVcDown notification";
+      }
+      leaf vc-up {
+        xr:xr-xml-map "pwmib_cfg:VCUp";
+        type empty;
+        description "Enable cpwVcUp notification";
+      }
+    }
+    description
+      "This augment extends the configuration data of
+      'Cisco-IOS-XR-snmp-agent-cfg'";
+  }
+}
\ No newline at end of file
diff --git a/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-snmp-agent-cfg@2015-10-27.yang b/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-snmp-agent-cfg@2015-10-27.yang
new file mode 100644 (file)
index 0000000..b6e0748
--- /dev/null
@@ -0,0 +1,2142 @@
+module Cisco-IOS-XR-snmp-agent-cfg {
+
+  /*** NAMESPACE / PREFIX DEFINITION ***/
+
+  namespace "http://cisco.com/ns/yang/Cisco-IOS-XR-snmp-agent-cfg";
+
+
+  prefix "snmp-agent-cfg";
+
+  /*** LINKAGE (IMPORTS / INCLUDES) ***/
+
+  import ietf-inet-types { prefix "inet"; }
+
+  import Cisco-IOS-XR-types { prefix "xr"; }
+
+  /*** META INFORMATION ***/
+
+  organization "Cisco Systems, Inc.";
+
+  contact
+    "Cisco Systems, Inc.
+     Customer Service
+
+     Postal: 170 West Tasman Drive
+     San Jose, CA 95134
+
+     Tel: +1 800 553-NETS
+
+     E-mail: cs-yang@cisco.com";
+
+  description 
+    "This module contains a collection of YANG definitions
+     for Cisco IOS-XR snmp-agent package configuration.
+
+     This module contains definitions
+     for the following management objects:
+       snmp: The heirarchy point for all the SNMP configurations
+       mib: mib
+
+     Copyright (c) 2013-2015 by Cisco Systems, Inc.
+     All rights reserved.";
+
+  revision "2015-10-27" {
+    description
+      "IOS XR 5.3.2 revision.";
+  }
+
+  revision "2015-01-07" {
+    description
+      "IOS XR 5.3.1 revision.";
+  }
+
+  typedef Snmp-tos {
+    type enumeration {
+      enum precedence {
+        value 0;
+        description "SNMP TOS type Precedence";
+      }
+      enum dscp {
+        value 1;
+        description "SNMP TOS type DSCP";
+      }
+    }
+    description "Snmp tos";
+  }
+  typedef Snmp-hash-algorithm {
+    type enumeration {
+      enum none {
+        value 0;
+        description "No authentication required";
+      }
+      enum md5 {
+        value 1;
+        description "Standard Message Digest algorithm";
+      }
+      enum sha {
+        value 2;
+        description "SHA algorithm";
+      }
+    }
+    description "Snmp hash algorithm";
+  }
+  typedef Snmp-priv-algorithm {
+    type enumeration {
+      enum none {
+        value 0;
+        description "No Privacy";
+      }
+      enum des {
+        value 1;
+        description "Des algorithm";
+      }
+      enum 3des {
+        value 2;
+        description "3des algorithm";
+      }
+      enum aes128 {
+        value 3;
+        description "aes128 algorithm";
+      }
+      enum aes192 {
+        value 4;
+        description "aes192 algorithm";
+      }
+      enum aes256 {
+        value 5;
+        description "aes256 algorithm";
+      }
+    }
+    description "Snmp priv algorithm";
+  }
+  typedef Snmp-owner-access {
+    type enumeration {
+      enum sdr-owner {
+        value 0;
+        description "Secure Domain Router Owner permissions";
+      }
+      enum system-owner {
+        value 1;
+        description "System owner permissions";
+      }
+    }
+    description "Snmp owner access";
+  }
+  typedef Snmp-bulkstat-schema {
+    type enumeration {
+      enum exact-interface {
+        value 1;
+        description "Exact Interface";
+      }
+      enum exact-oid {
+        value 2;
+        description "Exact OID";
+      }
+      enum wild-interface {
+        value 3;
+        description "Wild Interface";
+      }
+      enum wild-oid {
+        value 4;
+        description "Wild OID";
+      }
+      enum range-oid {
+        value 5;
+        description "Range of OID";
+      }
+      enum repeat-oid {
+        value 6;
+        description "Repeated the instance";
+      }
+    }
+    description "Snmp bulkstat schema";
+  }
+  typedef Snmpacl {
+    type enumeration {
+      enum ipv4 {
+        value 1;
+        description "Ipv4 Access-list";
+      }
+      enum ipv6 {
+        value 2;
+        description "Ipv6 Access-list";
+      }
+    }
+    description "Snmpacl";
+  }
+  typedef Snmp-dscp-value {
+    type union {
+      type enumeration {
+        enum default {
+          value 0;
+          description "Applicable to DSCP: bits 000000";
+        }
+        enum af11 {
+          value 10;
+          description "Applicable to DSCP: bits 001010";
+        }
+        enum af12 {
+          value 12;
+          description "Applicable to DSCP: bits 001100";
+        }
+        enum af13 {
+          value 14;
+          description "Applicable to DSCP: bits 001110";
+        }
+        enum af21 {
+          value 18;
+          description "Applicable to DSCP: bits 010010";
+        }
+        enum af22 {
+          value 20;
+          description "Applicable to DSCP: bits 010100";
+        }
+        enum af23 {
+          value 22;
+          description "Applicable to DSCP: bits 010110";
+        }
+        enum af31 {
+          value 26;
+          description "Applicable to DSCP: bits 011010";
+        }
+        enum af32 {
+          value 28;
+          description "Applicable to DSCP: bits 011100";
+        }
+        enum af33 {
+          value 30;
+          description "Applicable to DSCP: bits 011110";
+        }
+        enum af41 {
+          value 34;
+          description "Applicable to DSCP: bits 100010";
+        }
+        enum af42 {
+          value 36;
+          description "Applicable to DSCP: bits 100100";
+        }
+        enum af43 {
+          value 38;
+          description "Applicable to DSCP: bits 100110";
+        }
+        enum ef {
+          value 46;
+          description "Applicable to DSCP: bits 101110";
+        }
+        enum cs1 {
+          value 8;
+          description "Applicable to DSCP: bits 001000";
+        }
+        enum cs2 {
+          value 16;
+          description "Applicable to DSCP: bits 010000";
+        }
+        enum cs3 {
+          value 24;
+          description "Applicable to DSCP: bits 011000";
+        }
+        enum cs4 {
+          value 32;
+          description "Applicable to DSCP: bits 100000";
+        }
+        enum cs5 {
+          value 40;
+          description "Applicable to DSCP: bits 101000";
+        }
+        enum cs6 {
+          value 48;
+          description "Applicable to DSCP: bits 110000";
+        }
+        enum cs7 {
+          value 56;
+          description "Applicable to DSCP: bits 111000";
+        }
+      }
+      type uint32 {
+        range "0..63";
+      }
+    }
+    description "Snmp dscp value";
+  }
+  typedef Snmp-precedence-value1 {
+    type union {
+      type enumeration {
+        enum routine {
+          value 0;
+          description "Applicable to Precedence: value 0";
+        }
+        enum priority {
+          value 1;
+          description "Applicable to Precedence: value 1";
+        }
+        enum immediate {
+          value 2;
+          description "Applicable to Precedence: value 2";
+        }
+        enum flash {
+          value 3;
+          description "Applicable to Precedence: value 3";
+        }
+        enum flash-override {
+          value 4;
+          description "Applicable to Precedence: value 4";
+        }
+        enum critical {
+          value 5;
+          description "Applicable to Precedence: value 5";
+        }
+        enum internet {
+          value 6;
+          description "Applicable to Precedence: value 6";
+        }
+        enum network {
+          value 7;
+          description "Applicable to Precedence: value 7";
+        }
+      }
+      type uint32 {
+        range "0..7";
+      }
+    }
+    description "Snmp precedence value1";
+  }
+  typedef Snmp-security-model {
+    type enumeration {
+      enum no-authentication {
+        value 0;
+        description "No Authentication required";
+      }
+      enum authentication {
+        value 1;
+        description
+          "Authentication password alone required for
+          access";
+      }
+      enum privacy {
+        value 2;
+        description
+          "Authentication and privacy password required
+          for access";
+      }
+    }
+    description "Snmp security model";
+  }
+  typedef Snmp-mib-view-inclusion {
+    type enumeration {
+      enum included {
+        value 1;
+        description "MIB View to be included";
+      }
+      enum excluded {
+        value 2;
+        description "MIB View to be excluded";
+      }
+    }
+    description "Snmp mib view inclusion";
+  }
+  typedef Snmp-bulkstat-file-format {
+    type enumeration {
+      enum schema-ascii {
+        value 1;
+        description "Tranfer file in schema Ascii format";
+      }
+      enum bulk-ascii {
+        value 2;
+        description "Tranfer file in Bulk Ascii format";
+      }
+      enum bulk-binary {
+        value 3;
+        description "Tranfer file in Bulk binary format";
+      }
+    }
+    description "Snmp bulkstat file format";
+  }
+  typedef Snmp-access-level {
+    type enumeration {
+      enum read-only {
+        value 0;
+        description "Read Only Access for a community string";
+      }
+      enum read-write {
+        value 1;
+        description "Read Write Access for a community string";
+      }
+    }
+    description "Snmp access level";
+  }
+  typedef Snmp-context {
+    type enumeration {
+      enum vrf {
+        value 1;
+        description "VRF feature";
+      }
+      enum bridge {
+        value 4;
+        description "BRIDGE feature";
+      }
+      enum ospf {
+        value 5;
+        description "OSPF feature";
+      }
+      enum ospfv3 {
+        value 6;
+        description "OSPFv3 feature";
+      }
+    }
+    description "Snmp context";
+  }
+  typedef Group-snmp-version {
+    type enumeration {
+      enum v1 {
+        value 0;
+        description "SNMP version 1";
+      }
+      enum v2c {
+        value 1;
+        description "SNMP version 2";
+      }
+      enum v3 {
+        value 2;
+        description "SNMP version 3";
+      }
+    }
+    description "Group snmp version";
+  }
+  typedef User-snmp-version {
+    type enumeration {
+      enum v1 {
+        value 1;
+        description "SNMP version 1";
+      }
+      enum v2c {
+        value 2;
+        description "SNMP version 2";
+      }
+      enum v3 {
+        value 3;
+        description "SNMP version 3";
+      }
+    }
+    description "User snmp version";
+  }
+
+  grouping APPLIED-TO {
+    description "Common node of rule, rule-set";
+
+    container applied-to {
+      xr:xr-xml-map "snmp_corr_cfg:AppliedTo";
+      description "Applied to the Rule or Ruleset";
+
+      container hosts {
+        xr:xr-xml-map "snmp_corr_cfg:HostTable";
+        description "Table of configured hosts to apply rules to";
+
+        list host {
+          xr:xr-xml-map "snmp_corr_cfg:Host";
+          key "ip-address port";
+          description "A destination host";
+          leaf ip-address {
+            xr:xr-xml-map "snmp_corr_cfg:IPAddress";
+            type inet:ip-address-no-zone;
+            description "IP address";
+          }
+          leaf port {
+            xr:xr-xml-map "snmp_corr_cfg:Port";
+            type xr:Cisco-ios-xr-port-number;
+            description "Port (specify 162 for default)";
+          }
+        }
+      }
+      leaf all {
+        xr:xr-xml-map "snmp_corr_cfg:All";
+        type empty;
+        description "Apply to all of the device";
+      }
+    }
+  }
+
+  grouping CONTEXT-TABLE {
+    description "Common node of snmp, vrf";
+
+    container contexts {
+      xr:xr-xml-map "snmp_cfg:ContextTable";
+      description "List of Context Names";
+
+      list context {
+        xr:xr-xml-map "snmp_cfg:Context";
+        xr:xr-cli-map "vrf <string> context <string> ";
+        xr:xr-cli-map "context <string> ";
+        key "context-name";
+        description "Context Name";
+        leaf context-name {
+          xr:xr-xml-map "snmp_cfg:ContextName";
+          type xr:Cisco-ios-xr-string;
+          description "Context Name";
+        }
+      }
+    }
+  }
+
+  grouping VAR-BIND-TABLE {
+    description "Common node of root-cause, non-root-cause";
+
+    container var-binds {
+      xr:xr-xml-map "snmp_corr_cfg:VarBindTable";
+      description "Varbinds to match";
+
+      list var-bind {
+        xr:xr-xml-map "snmp_corr_cfg:VarBind";
+        key "oid";
+        description "Varbind match conditions";
+
+        container match {
+          xr:xr-xml-map "snmp_corr_cfg:Match";
+          description "VarBind match conditions";
+          leaf value {
+            xr:xr-xml-map "snmp_corr_cfg:Value";
+            type string;
+            description "Regular Expression to match value";
+          }
+          leaf index {
+            xr:xr-xml-map "snmp_corr_cfg:Index";
+            type string;
+            description "Regular Expression to match index";
+          }
+        }
+        leaf oid {
+          xr:xr-xml-map "snmp_corr_cfg:OID";
+          type string;
+          description "OID of varbind (dotted decimal)";
+        }
+      }
+    }
+  }
+
+  grouping TRAP-HOST-TABLE {
+    description "Common node of snmp, vrf";
+
+    container trap-hosts {
+      xr:xr-xml-map "snmp_cfg:TrapHostTable";
+      description "Specify hosts to receive SNMP notifications";
+
+      list trap-host {
+        xr:xr-xml-map "snmp_cfg:TrapHost";
+        key "ip-address";
+        description "Specify hosts to receive SNMP notifications";
+
+        container encrypted-user-communities {
+          xr:xr-xml-map "snmp_cfg:EncryptedUserCommunityTable";
+          description
+            "Container class for defining Clear/encrypt
+            communities for a trap host";
+
+          list encrypted-user-community {
+            xr:xr-xml-map "snmp_cfg:EncryptedUserCommunity";
+            key "community-name";
+            description
+              "Clear/Encrypt Community name associated with
+              a trap host";
+            leaf community-name {
+              xr:xr-xml-map "snmp_cfg:CommunityName";
+              type xr:Cisco-ios-xr-string;
+              description
+                "SNMPv1/v2c community string or SNMPv3 user";
+            }
+            leaf port {
+              xr:xr-xml-map "snmp_cfg:Port";
+              type xr:Cisco-ios-xr-port-number;
+              description "UDP port number";
+            }
+            leaf version {
+              xr:xr-xml-map "snmp_cfg:Version";
+              type string;
+              mandatory true;
+              description "SNMP Version to be used v1/v2c/v3";
+            }
+            leaf security-level {
+              xr:xr-xml-map "snmp_cfg:SecurityLevel";
+              type Snmp-security-model;
+              description
+                "Security level to be used noauth/auth/priv";
+            }
+            leaf basic-trap-types {
+              xr:xr-xml-map "snmp_cfg:BasicTrapTypes";
+              type int32;
+              mandatory true;
+              description
+                "Number to signify the feature traps that
+                needs to be setBasicTrapTypes is used for
+                all traps except copy-completeSet this value
+                to an integer corresponding to the trapBGP
+                8192, CONFIG 4096,SYSLOG 131072,SNMP_TRAP
+                1COPY_COMPLETE_TRAP 64To provide a
+                combination of trap Add the respective
+                numbersValue must be set to 0 for all traps";
+            }
+            leaf advanced-trap-types1 {
+              xr:xr-xml-map "snmp_cfg:AdvancedTrapTypes1";
+              type int32;
+              mandatory true;
+              description
+                "Number to signify the feature traps that
+                needs to be setUse this for providing
+                copy-complete trapValue must be set to 0 if
+                not used";
+            }
+            leaf advanced-trap-types2 {
+              xr:xr-xml-map "snmp_cfg:AdvancedTrapTypes2";
+              type int32;
+              mandatory true;
+              description
+                "Number to signify the feature traps that
+                needs to be setvalue should always to set as
+                0";
+            }
+          }
+        }
+
+        container inform-host {
+          xr:xr-xml-map "snmp_cfg:InformHost";
+          description
+            "Container class for defining notification type
+            for a Inform host";
+
+          container inform-user-communities {
+            xr:xr-xml-map "snmp_cfg:InformUserCommunityTable";
+            description
+              "Container class for defining communities for
+              a inform host";
+
+            list inform-user-community {
+              xr:xr-xml-map "snmp_cfg:InformUserCommunity";
+              key "community-name";
+              description
+                "Unencrpted Community name associated with a
+                inform host";
+              leaf community-name {
+                xr:xr-xml-map "snmp_cfg:CommunityName";
+                type xr:Cisco-ios-xr-string {
+                  length "0..128";
+                }
+                description
+                  "SNMPv2c community string or SNMPv3 user";
+              }
+              leaf port {
+                xr:xr-xml-map "snmp_cfg:Port";
+                type xr:Cisco-ios-xr-port-number;
+                description "UDP port number";
+              }
+              leaf version {
+                xr:xr-xml-map "snmp_cfg:Version";
+                type string;
+                mandatory true;
+                description "SNMP Version to be used v2c/v3";
+              }
+              leaf security-level {
+                xr:xr-xml-map "snmp_cfg:SecurityLevel";
+                type Snmp-security-model;
+                description
+                  "Security level to be used noauth/auth/priv";
+              }
+              leaf basic-trap-types {
+                xr:xr-xml-map "snmp_cfg:BasicTrapTypes";
+                type int32;
+                mandatory true;
+                description
+                  "Number to signify the feature traps that
+                  needs to be setBasicTrapTypes is used for
+                  all traps except copy-completeSet this
+                  value to an integer corresponding to the
+                  trapBGP 8192, CONFIG 4096,SYSLOG 131072
+                  ,SNMP_TRAP 1COPY_COMPLETE_TRAP 64To provide
+                  a combination of trap Add the respective
+                  numbersValue must be set to 0 for all traps";
+              }
+              leaf advanced-trap-types1 {
+                xr:xr-xml-map "snmp_cfg:AdvancedTrapTypes1";
+                type int32;
+                mandatory true;
+                description
+                  "Number to signify the feature traps that
+                  needs to be setUse this for providing
+                  copy-complete trapValue must be set to 0 if
+                  not used";
+              }
+              leaf advanced-trap-types2 {
+                xr:xr-xml-map "snmp_cfg:AdvancedTrapTypes2";
+                type int32;
+                mandatory true;
+                description
+                  "Number to signify the feature traps that
+                  needs to be setvalue should always to set
+                  as 0";
+              }
+            }
+          }
+
+          container inform-encrypted-user-communities {
+            xr:xr-xml-map "snmp_cfg:InformEncryptedUserCommunityTab"+
+              "le";
+            description
+              "Container class for defining Clear/encrypt
+              communities for a inform host";
+
+            list inform-encrypted-user-community {
+              xr:xr-xml-map "snmp_cfg:InformEncryptedUserCommunity";
+              key "community-name";
+              description
+                "Clear/Encrypt Community name associated with
+                a inform host";
+              leaf community-name {
+                xr:xr-xml-map "snmp_cfg:CommunityName";
+                type xr:Cisco-ios-xr-string;
+                description
+                  "SNMPv2c community string or SNMPv3 user";
+              }
+              leaf port {
+                xr:xr-xml-map "snmp_cfg:Port";
+                type xr:Cisco-ios-xr-port-number;
+                description "UDP port number";
+              }
+              leaf version {
+                xr:xr-xml-map "snmp_cfg:Version";
+                type string;
+                mandatory true;
+                description "SNMP Version to be used v2c/v3";
+              }
+              leaf security-level {
+                xr:xr-xml-map "snmp_cfg:SecurityLevel";
+                type Snmp-security-model;
+                description
+                  "Security level to be used noauth/auth/priv";
+              }
+              leaf basic-trap-types {
+                xr:xr-xml-map "snmp_cfg:BasicTrapTypes";
+                type int32;
+                mandatory true;
+                description
+                  "Number to signify the feature traps that
+                  needs to be setBasicTrapTypes is used for
+                  all traps except copy-completeSet this
+                  value to an integer corresponding to the
+                  trapBGP 8192, CONFIG 4096,SYSLOG 131072
+                  ,SNMP_TRAP 1COPY_COMPLETE_TRAP 64To provide
+                  a combination of trap Add the respective
+                  numbersValue must be set to 0 for all traps";
+              }
+              leaf advanced-trap-types1 {
+                xr:xr-xml-map "snmp_cfg:AdvancedTrapTypes1";
+                type int32;
+                mandatory true;
+                description
+                  "Number to signify the feature traps that
+                  needs to be setUse this for providing
+                  copy-complete trapValue must be set to 0 if
+                  not used";
+              }
+              leaf advanced-trap-types2 {
+                xr:xr-xml-map "snmp_cfg:AdvancedTrapTypes2";
+                type int32;
+                mandatory true;
+                description
+                  "Number to signify the feature traps that
+                  needs to be setvalue should always to set
+                  as 0";
+              }
+            }
+          }
+        }
+
+        container default-user-communities {
+          xr:xr-xml-map "snmp_cfg:DefaultUserCommunityTable";
+          description
+            "Container class for defining communities for a
+            trap host";
+
+          list default-user-community {
+            xr:xr-xml-map "snmp_cfg:DefaultUserCommunity";
+            key "community-name";
+            description
+              "Unencrpted Community name associated with a
+              trap host";
+            leaf community-name {
+              xr:xr-xml-map "snmp_cfg:CommunityName";
+              type xr:Cisco-ios-xr-string {
+                length "0..128";
+              }
+              description
+                "SNMPv1/v2c community string or SNMPv3 user";
+            }
+            leaf port {
+              xr:xr-xml-map "snmp_cfg:Port";
+              type xr:Cisco-ios-xr-port-number;
+              description "UDP port number";
+            }
+            leaf version {
+              xr:xr-xml-map "snmp_cfg:Version";
+              type string;
+              mandatory true;
+              description "SNMP Version to be used v1/v2c/v3";
+            }
+            leaf security-level {
+              xr:xr-xml-map "snmp_cfg:SecurityLevel";
+              type Snmp-security-model;
+              description
+                "Security level to be used noauth/auth/priv";
+            }
+            leaf basic-trap-types {
+              xr:xr-xml-map "snmp_cfg:BasicTrapTypes";
+              type int32;
+              mandatory true;
+              description
+                "Number to signify the feature traps that
+                needs to be setBasicTrapTypes is used for
+                all traps except copy-completeSet this value
+                to an integer corresponding to the trapBGP
+                8192, CONFIG 4096,SYSLOG 131072,SNMP_TRAP
+                1COPY_COMPLETE_TRAP 64To provide a
+                combination of trap Add the respective
+                numbersValue must be set to 0 for all traps";
+            }
+            leaf advanced-trap-types1 {
+              xr:xr-xml-map "snmp_cfg:AdvancedTrapTypes1";
+              type int32;
+              mandatory true;
+              description
+                "Number to signify the feature traps that
+                needs to be setUse this for providing
+                copy-complete trapValue must be set to 0 if
+                not used";
+            }
+            leaf advanced-trap-types2 {
+              xr:xr-xml-map "snmp_cfg:AdvancedTrapTypes2";
+              type int32;
+              mandatory true;
+              description
+                "Number to signify the feature traps that
+                needs to be setvalue should always to set as
+                0";
+            }
+          }
+        }
+        leaf ip-address {
+          xr:xr-xml-map "snmp_cfg:IPAddress";
+          type inet:ip-address-no-zone;
+          description "IP address of SNMP notification host";
+        }
+      }
+    }
+  }
+
+  grouping CONTEXT-MAPPING-TABLE {
+    description "Common node of snmp, vrf";
+
+    container context-mappings {
+      xr:xr-xml-map "snmp_cfg:ContextMappingTable";
+      description "List of context names";
+
+      list context-mapping {
+        xr:xr-xml-map "snmp_cfg:ContextMapping";
+        xr:xr-cli-map "context mapping <string> [feature <enum> (in"+
+          "stance <string>)|(vrf <string>)|(topology <string>)] ";
+        key "context-mapping-name";
+        description "Context mapping name";
+        leaf context-mapping-name {
+          xr:xr-xml-map "snmp_cfg:ContextMappingName";
+          type xr:Cisco-ios-xr-string;
+          description "Context mapping name";
+        }
+        leaf context {
+          xr:xr-xml-map "snmp_cfg:Context";
+          type Snmp-context;
+          description "SNMP context feature type";
+        }
+        leaf instance-name {
+          xr:xr-xml-map "snmp_cfg:InstanceName";
+          type string;
+          description "OSPF protocol instance";
+        }
+        leaf vrf-name {
+          xr:xr-xml-map "snmp_cfg:VRFName";
+          type string;
+          description "VRF name associated with the context";
+        }
+        leaf topology-name {
+          xr:xr-xml-map "snmp_cfg:TopologyName";
+          type string;
+          description "Topology name associated with the context";
+        }
+      }
+    }
+  }
+
+  container snmp {
+    xr:xr-xml-map "snmp_cfg:SNMP";
+    description
+      "The heirarchy point for all the SNMP
+      configurations";
+
+    container encrypted-community-maps {
+      xr:xr-xml-map "snmp_cfg:EncryptedCommunityMapTable";
+      description
+        "Container class to hold clear/encrypted
+        communitie maps";
+
+      list encrypted-community-map {
+        xr:xr-xml-map "snmp_cfg:EncryptedCommunityMap";
+        key "community-name";
+        description "Clear/encrypted SNMP community map";
+        leaf community-name {
+          xr:xr-xml-map "snmp_cfg:CommunityName";
+          type xr:Cisco-ios-xr-string;
+          description "SNMP community map";
+        }
+        leaf context {
+          xr:xr-xml-map "snmp_cfg:Context";
+          type string;
+          description "SNMP Context Name ";
+        }
+        leaf security {
+          xr:xr-xml-map "snmp_cfg:Security";
+          type string;
+          description "SNMP Security Name ";
+        }
+        leaf target-list {
+          xr:xr-xml-map "snmp_cfg:TargetList";
+          type string;
+          description "target list name ";
+        }
+      }
+    }
+
+    container views {
+      xr:xr-xml-map "snmp_cfg:ViewTable";
+      description "Class to configure a SNMPv2 MIB view";
+
+      list view {
+        xr:xr-xml-map "snmp_cfg:View";
+        xr:xr-cli-map "view <string> <string> (included)|(excluded)"+
+          " ";
+        key "view-name family";
+        description "Name of the view";
+        leaf view-name {
+          xr:xr-xml-map "snmp_cfg:ViewName";
+          type xr:Cisco-ios-xr-string;
+          description "Name of the view";
+        }
+        leaf family {
+          xr:xr-xml-map "snmp_cfg:Family";
+          type string;
+          description "MIB view family name";
+        }
+        leaf view-inclusion {
+          xr:xr-xml-map "snmp_cfg:ViewInclusion";
+          type Snmp-mib-view-inclusion;
+          mandatory true;
+          description "MIB view to be included or excluded";
+        }
+      }
+    }
+
+    container logging {
+      xr:xr-xml-map "snmp_cfg:Logging";
+      description "SNMP logging";
+
+      container threshold {
+        xr:xr-xml-map "snmp_cfg:Threshold";
+        description "SNMP logging threshold";
+        leaf oid-processing {
+          xr:xr-xml-map "snmp_cfg:OIDProcessing";
+          xr:xr-cli-map "logging threshold oid-processing <number> ";
+          type uint32 {
+            range "0..20000";
+          }
+          default "500";
+          description "SNMP logging threshold for OID processing";
+        }
+        leaf pdu-processing {
+          xr:xr-xml-map "snmp_cfg:PDUProcessing";
+          xr:xr-cli-map "logging threshold pdu-processing <number> ";
+          type uint32 {
+            range "0..20000";
+          }
+          default "20000";
+          description "SNMP logging threshold for PDU processing";
+        }
+      }
+    }
+
+    container administration {
+      xr:xr-xml-map "snmp_cfg:Administration";
+      description "Container class for SNMP administration";
+
+      container default-communities {
+        xr:xr-xml-map "snmp_cfg:DefaultCommunityTable";
+        description
+          "Container class to hold unencrpted communities";
+
+        list default-community {
+          xr:xr-xml-map "snmp_cfg:DefaultCommunity";
+          key "community-name";
+          description
+            "Unencrpted SNMP community string and access
+            priviledges";
+          leaf community-name {
+            xr:xr-xml-map "snmp_cfg:CommunityName";
+            type string {
+              length "0..128";
+            }
+            description "SNMP community string";
+          }
+          leaf priviledge {
+            xr:xr-xml-map "snmp_cfg:Priviledge";
+            type Snmp-access-level;
+            description "Read/Write Access";
+          }
+          leaf view-name {
+            xr:xr-xml-map "snmp_cfg:ViewName";
+            type string;
+            description
+              "MIB view to which the community has access";
+          }
+          leaf v4acl-type {
+            xr:xr-xml-map "snmp_cfg:V4ACLType";
+            type Snmpacl;
+            description "Access-list type";
+          }
+          leaf v4-access-list {
+            xr:xr-xml-map "snmp_cfg:V4AccessList";
+            type string;
+            description "Ipv4 Access-list name";
+          }
+          leaf v6acl-type {
+            xr:xr-xml-map "snmp_cfg:V6ACLType";
+            type Snmpacl;
+            description "Access-list type";
+          }
+          leaf v6-access-list {
+            xr:xr-xml-map "snmp_cfg:V6AccessList";
+            type string;
+            description "Ipv6 Access-list name";
+          }
+          leaf owner {
+            xr:xr-xml-map "snmp_cfg:Owner";
+            type Snmp-owner-access;
+            description "Logical Router or System owner access";
+          }
+        }
+      }
+
+      container encrypted-communities {
+        xr:xr-xml-map "snmp_cfg:EncryptedCommunityTable";
+        description
+          "Container class to hold clear/encrypted
+          communities";
+
+        list encrypted-community {
+          xr:xr-xml-map "snmp_cfg:EncryptedCommunity";
+          key "community-name";
+          description
+            "Clear/encrypted SNMP community string and
+            access priviledges";
+          leaf community-name {
+            xr:xr-xml-map "snmp_cfg:CommunityName";
+            type xr:Cisco-ios-xr-string;
+            description "SNMP community string";
+          }
+          leaf priviledge {
+            xr:xr-xml-map "snmp_cfg:Priviledge";
+            type Snmp-access-level;
+            description "Read/Write Access";
+          }
+          leaf view-name {
+            xr:xr-xml-map "snmp_cfg:ViewName";
+            type string;
+            description
+              "MIB view to which the community has access";
+          }
+          leaf v4acl-type {
+            xr:xr-xml-map "snmp_cfg:V4ACLType";
+            type Snmpacl;
+            description "Access-list type";
+          }
+          leaf v4-access-list {
+            xr:xr-xml-map "snmp_cfg:V4AccessList";
+            type string;
+            description "Ipv4 Access-list name";
+          }
+          leaf v6acl-type {
+            xr:xr-xml-map "snmp_cfg:V6ACLType";
+            type Snmpacl;
+            description "Access-list type";
+          }
+          leaf v6-access-list {
+            xr:xr-xml-map "snmp_cfg:V6AccessList";
+            type string;
+            description "Ipv6 Access-list name";
+          }
+          leaf owner {
+            xr:xr-xml-map "snmp_cfg:Owner";
+            type Snmp-owner-access;
+            description "Logical Router or System owner access";
+          }
+        }
+      }
+    }
+
+    container agent {
+      xr:xr-xml-map "snmp_cfg:Agent";
+      description
+        "The heirarchy point for SNMP Agent
+        configurations";
+
+      container engine-id {
+        xr:xr-xml-map "snmp_cfg:EngineID";
+        description "SNMPv3 engineID";
+
+        container remotes {
+          xr:xr-xml-map "snmp_cfg:RemoteTable";
+          description "SNMPv3 remote SNMP Entity";
+
+          list remote {
+            xr:xr-xml-map "snmp_cfg:Remote";
+            xr:xr-cli-map "engineID remote <IPv4"+
+              "/IPv6 address> <string> [udp-port <number>] ";
+            key "remote-address";
+            description "engineID of the remote agent";
+            leaf remote-address {
+              xr:xr-xml-map "snmp_cfg:RemoteAddress";
+              type inet:ip-address-no-zone;
+              description "IP address of remote SNMP entity";
+            }
+            leaf remote-engine-id {
+              xr:xr-xml-map "snmp_cfg:RemoteEngineID";
+              type string;
+              description "engine ID octet string";
+            }
+            leaf port {
+              xr:xr-xml-map "snmp_cfg:Port";
+              type xr:Cisco-ios-xr-port-number;
+              description "UDP port number";
+            }
+          }
+        }
+        leaf local {
+          xr:xr-xml-map "snmp_cfg:Local";
+          xr:xr-cli-map "engineID local <string> ";
+          type string;
+          description "engineID of the local agent";
+        }
+      }
+    }
+
+    container trap {
+      xr:xr-xml-map "snmp_cfg:Trap";
+      description "Class to hold trap configurations";
+      leaf timeout {
+        xr:xr-xml-map "snmp_cfg:Timeout";
+        xr:xr-cli-map "trap-timeout <number> ";
+        type uint32 {
+          range "1..1000";
+        }
+        description "Timeout for TRAP message retransmissions";
+      }
+      leaf throttle-time {
+        xr:xr-xml-map "snmp_cfg:ThrottleTime";
+        xr:xr-cli-map "throttle-time <number> ";
+        type uint32 {
+          range "10..500";
+        }
+        units "millisecond";
+        description "Set throttle time for handling traps";
+      }
+      leaf queue-length {
+        xr:xr-xml-map "snmp_cfg:QueueLength";
+        xr:xr-cli-map "queue-length <number> ";
+        type uint32 {
+          range "1..5000";
+        }
+        description "Message queue length for each TRAP host";
+      }
+    }
+
+    container ipv6 {
+      xr:xr-xml-map "snmp_cfg:IPv6";
+      description "SNMP TOS bit for outgoing packets";
+
+      container tos {
+        xr:xr-xml-map "snmp_cfg:TOS";
+        description "Type of TOS";
+        leaf type {
+          xr:xr-xml-map "snmp_cfg:Type";
+          type Snmp-tos;
+          description "SNMP TOS type DSCP or Precedence";
+        }
+        leaf precedence {
+          xr:xr-xml-map "snmp_cfg:Precedence";
+          when "../type = 'precedence'" {
+            description "../Type = Precedence";
+          }
+          type Snmp-precedence-value1;
+          description "SNMP Precedence value";
+        }
+        leaf dscp {
+          xr:xr-xml-map "snmp_cfg:DSCP";
+          when "../type = 'dscp'" {
+            description "../Type = DSCP";
+          }
+          type Snmp-dscp-value;
+          description "SNMP DSCP value";
+        }
+      }
+    }
+
+    container ipv4 {
+      xr:xr-xml-map "snmp_cfg:IPv4";
+      description "SNMP TOS bit for outgoing packets";
+
+      container tos {
+        xr:xr-xml-map "snmp_cfg:TOS";
+        description "Type of TOS";
+        leaf type {
+          xr:xr-xml-map "snmp_cfg:Type";
+          type Snmp-tos;
+          description "SNMP TOS type DSCP or Precedence";
+        }
+        leaf precedence {
+          xr:xr-xml-map "snmp_cfg:Precedence";
+          when "../type = 'precedence'" {
+            description "../Type = Precedence";
+          }
+          type Snmp-precedence-value1;
+          description "SNMP Precedence value";
+        }
+        leaf dscp {
+          xr:xr-xml-map "snmp_cfg:DSCP";
+          when "../type = 'dscp'" {
+            description "../Type = DSCP";
+          }
+          type Snmp-dscp-value;
+          description "SNMP DSCP value";
+        }
+      }
+    }
+
+    container system {
+      xr:xr-xml-map "snmp_cfg:System";
+      description "container to hold system information";
+      leaf chassis-id {
+        xr:xr-xml-map "snmp_cfg:ChassisID";
+        xr:xr-cli-map "chassis-id <text> ";
+        type string {
+          length "0..255";
+        }
+        description "String to uniquely identify this chassis";
+      }
+      leaf location {
+        xr:xr-xml-map "snmp_cfg:Location";
+        xr:xr-cli-map "location <text> ";
+        type string {
+          length "0..255";
+        }
+        description "The physical location of this node";
+      }
+      leaf contact {
+        xr:xr-xml-map "snmp_cfg:Contact";
+        xr:xr-cli-map "contact <text> ";
+        type string {
+          length "0..255";
+        }
+        description
+          "identification of the contact person for this
+          managed node";
+      }
+    }
+
+    container target {
+      xr:xr-xml-map "snmp_cfg:Target";
+      description "SNMP target configurations";
+
+      container targets {
+        xr:xr-xml-map "snmp_cfg:TargetListTable";
+        description "List of targets";
+
+        list target {
+          xr:xr-xml-map "snmp_cfg:TargetList";
+          key "target-list-name";
+          description "Name of the target list";
+
+          container vrf-names {
+            xr:xr-xml-map "snmp_cfg:VRFNameTable";
+            description "List of VRF Name for a target list";
+
+            list vrf-name {
+              xr:xr-xml-map "snmp_cfg:VRFName";
+              xr:xr-cli-map "target list <string> vrf <string> ";
+              key "name";
+              description "VRF name of the target";
+              leaf name {
+                xr:xr-xml-map "snmp_cfg:Name";
+                type xr:Cisco-ios-xr-string;
+                description "VRF Name";
+              }
+            }
+          }
+
+          container target-addresses {
+            xr:xr-xml-map "snmp_cfg:TargetAddressTable";
+            description "SNMP Target address configurations";
+
+            list target-address {
+              xr:xr-xml-map "snmp_cfg:TargetAddress";
+              xr:xr-cli-map "target list <string> host <IPv4"+
+                "/IPv6 address> ";
+              key "ip-address";
+              description
+                "IP Address to be configured for the Target";
+              leaf ip-address {
+                xr:xr-xml-map "snmp_cfg:IPAddress";
+                type inet:ip-address-no-zone;
+                description "IPv4/Ipv6 address";
+              }
+            }
+          }
+          leaf target-list-name {
+            xr:xr-xml-map "snmp_cfg:TargetListName";
+            type xr:Cisco-ios-xr-string;
+            description "Name of the target list";
+          }
+        }
+      }
+    }
+
+    container notification {
+      xr:xr-xml-map "snmp_cfg:Notification";
+      description "Enable SNMP notifications";
+
+      container snmp {
+        xr:xr-xml-map "snmpmib_cfg:SNMP";
+        description "SNMP notification configuration";
+        leaf authentication {
+          xr:xr-xml-map "snmpmib_cfg:Authentication";
+          xr:xr-cli-map "authentication ";
+          type empty;
+          description "Enable authentication notification";
+        }
+        leaf cold-start {
+          xr:xr-xml-map "snmpmib_cfg:ColdStart";
+          xr:xr-cli-map "coldstart ";
+          type empty;
+          description "Enable cold start notification";
+        }
+        leaf warm-start {
+          xr:xr-xml-map "snmpmib_cfg:WarmStart";
+          xr:xr-cli-map "warmstart ";
+          type empty;
+          description "Enable warm start notification";
+        }
+        leaf enable {
+          xr:xr-xml-map "snmpmib_cfg:Enable";
+          xr:xr-cli-map "traps snmp ";
+          type empty;
+          description "Enable SNMP notifications";
+        }
+      }
+    }
+
+    container correlator {
+      xr:xr-xml-map "snmp_corr_cfg:Correlator";
+      description "Configure properties of the trap correlator";
+
+      container rules {
+        xr:xr-xml-map "snmp_corr_cfg:RuleTable";
+        description "Table of configured rules";
+
+        list rule {
+          xr:xr-xml-map "snmp_corr_cfg:Rule";
+          key "name";
+          description "Rule name";
+
+          container non-stateful {
+            xr:xr-xml-map "snmp_corr_cfg:NonStateful";
+            presence "Indicates a non-stateful node is configured.";
+            description "The Non-Stateful Rule Type";
+
+            container root-causes {
+              xr:xr-xml-map "snmp_corr_cfg:RootCauseTable";
+              description
+                "Table of configured rootcause (only one
+                entry allowed)";
+
+              list root-cause {
+                xr:xr-xml-map "snmp_corr_cfg:RootCause";
+                key "oid";
+                description
+                  "The rootcause - maximum of one can be
+                  configured per rule";
+                leaf created {
+                  xr:xr-xml-map "snmp_corr_cfg:Created";
+                  type empty;
+                  description "Create rootcause";
+                }
+                leaf oid {
+                  xr:xr-xml-map "snmp_corr_cfg:OID";
+                  type string;
+                  description
+                    "OID of rootcause trap (dotted decimal)";
+                }
+                uses VAR-BIND-TABLE;
+              }
+            }
+
+            container non-root-causes {
+              xr:xr-xml-map "snmp_corr_cfg:NonRootCauseTable";
+              description "Table of configured non-rootcause";
+
+              list non-root-cause {
+                xr:xr-xml-map "snmp_corr_cfg:NonRootCause";
+                key "oid";
+                description "A non-rootcause";
+                leaf created {
+                  xr:xr-xml-map "snmp_corr_cfg:Created";
+                  type empty;
+                  description "Create nonrootcause";
+                }
+                leaf oid {
+                  xr:xr-xml-map "snmp_corr_cfg:OID";
+                  type string;
+                  description
+                    "OID of nonrootcause trap (dotted decimal)";
+                }
+                uses VAR-BIND-TABLE;
+              }
+            }
+            leaf timeout {
+              xr:xr-xml-map "snmp_corr_cfg:Timeout";
+              type uint32 {
+                range "1..600000";
+              }
+              units "millisecond";
+              description
+                "Timeout (time to wait for active
+                correlation) in milliseconds";
+            }
+          }
+          leaf name {
+            xr:xr-xml-map "snmp_corr_cfg:Name";
+            type string {
+              length "0..32";
+            }
+            description "Rule name";
+          }
+          uses APPLIED-TO;
+        }
+      }
+
+      container rule-sets {
+        xr:xr-xml-map "snmp_corr_cfg:RulesetTable";
+        description "Table of configured rulesets";
+
+        list rule-set {
+          xr:xr-xml-map "snmp_corr_cfg:Ruleset";
+          key "name";
+          description "Ruleset name";
+
+          container rulenames {
+            xr:xr-xml-map "snmp_corr_cfg:RulenameTable";
+            description "Table of configured rulenames";
+
+            list rulename {
+              xr:xr-xml-map "snmp_corr_cfg:Rulename";
+              xr:xr-cli-map "ruleset <string> rulename <string> ";
+              key "rulename";
+              description "A rulename";
+              leaf rulename {
+                xr:xr-xml-map "snmp_corr_cfg:Rulename";
+                type string {
+                  length "0..32";
+                }
+                description "Rule name";
+              }
+            }
+          }
+          leaf name {
+            xr:xr-xml-map "snmp_corr_cfg:Name";
+            type string {
+              length "0..32";
+            }
+            description "Ruleset name";
+          }
+          uses APPLIED-TO;
+        }
+      }
+      leaf buffer-size {
+        xr:xr-xml-map "snmp_corr_cfg:BufferSize";
+        xr:xr-cli-map "buffer-size <number> ";
+        type uint32 {
+          range "1024..52428800";
+        }
+        description "Configure size of the correlator buffer";
+      }
+    }
+
+    container bulk-stats {
+      xr:xr-xml-map "snmp_bulkstat_cfg:BulkStats";
+      description "SNMP bulk stats configuration commands";
+
+      container schemas {
+        xr:xr-xml-map "snmp_bulkstat_cfg:SchemaTable";
+        description "Configure schema definition";
+
+        list schema {
+          xr:xr-xml-map "snmp_bulkstat_cfg:Schema";
+          key "schema-name";
+          description "The name of the Schema";
+
+          container instance {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Instance";
+            presence "Indicates a instance node is configured.";
+            description "Object instance information";
+            leaf type {
+              xr:xr-xml-map "snmp_bulkstat_cfg:Type";
+              type Snmp-bulkstat-schema;
+              mandatory true;
+              description "Type of the instance";
+            }
+            leaf instance {
+              xr:xr-xml-map "snmp_bulkstat_cfg:Instance";
+              type xr:Interface-name;
+              description "Instance of the schema";
+            }
+            leaf start {
+              xr:xr-xml-map "snmp_bulkstat_cfg:Start";
+              type string;
+              mandatory true;
+              description "Start Instance OID for repetition";
+            }
+            leaf end {
+              xr:xr-xml-map "snmp_bulkstat_cfg:End";
+              type string;
+              mandatory true;
+              description "End Instance OID for repetition";
+            }
+            leaf max {
+              xr:xr-xml-map "snmp_bulkstat_cfg:Max";
+              type int32;
+              mandatory true;
+              description "Max value of Instance repetition";
+            }
+            leaf sub-interface {
+              xr:xr-xml-map "snmp_bulkstat_cfg:SubInterface";
+              type boolean;
+              mandatory true;
+              description "Include all the subinterface";
+            }
+          }
+          leaf type {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Type";
+            type empty;
+            description "Configure schema name";
+          }
+          leaf schema-object-list {
+            xr:xr-xml-map "snmp_bulkstat_cfg:SchemaObjectList";
+            xr:xr-cli-map "schema <string> object-list <string> ";
+            type xr:Cisco-ios-xr-string {
+              length "0..32";
+            }
+            description "Name of an object List";
+          }
+          leaf poll-interval {
+            xr:xr-xml-map "snmp_bulkstat_cfg:PollInterval";
+            xr:xr-cli-map "schema <string> poll-interval <number> ";
+            type uint32 {
+              range "1..20000";
+            }
+            units "minute";
+            description
+              "Periodicity for polling of objects in this
+              schema in minutes";
+          }
+          leaf schema-name {
+            xr:xr-xml-map "snmp_bulkstat_cfg:SchemaName";
+            type xr:Cisco-ios-xr-string {
+              length "0..32";
+            }
+            description "The name of the schema";
+          }
+        }
+      }
+
+      container objects {
+        xr:xr-xml-map "snmp_bulkstat_cfg:ObjectListTable";
+        description "Configure an Object List ";
+
+        list object {
+          xr:xr-xml-map "snmp_bulkstat_cfg:ObjectList";
+          key "object-list-name";
+          description "Name of the object List";
+
+          container objects {
+            xr:xr-xml-map "snmp_bulkstat_cfg:ObjectTable";
+            description "Configure an object List";
+
+            list object {
+              xr:xr-xml-map "snmp_bulkstat_cfg:Object";
+              xr:xr-cli-map "object-list <string> add <string> ";
+              key "oid";
+              description "Object name or OID";
+              leaf oid {
+                xr:xr-xml-map "snmp_bulkstat_cfg:OID";
+                type string;
+                description "Object name or OID ";
+              }
+            }
+          }
+          leaf type {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Type";
+            type empty;
+            description "Configure object list name";
+          }
+          leaf object-list-name {
+            xr:xr-xml-map "snmp_bulkstat_cfg:ObjectListName";
+            type xr:Cisco-ios-xr-string {
+              length "0..32";
+            }
+            description "Name of the object List";
+          }
+        }
+      }
+
+      container transfers {
+        xr:xr-xml-map "snmp_bulkstat_cfg:TransferTable";
+        description
+          "Periodicity for the transfer of bulk data in
+          minutes";
+
+        list transfer {
+          xr:xr-xml-map "snmp_bulkstat_cfg:Transfer";
+          key "transfer-name";
+          description "Name of bulk transfer";
+
+          container transfer-schemas {
+            xr:xr-xml-map "snmp_bulkstat_cfg:TransferSchemaTable";
+            description
+              "Schema that contains objects to be collected";
+
+            list transfer-schema {
+              xr:xr-xml-map "snmp_bulkstat_cfg:TransferSchema";
+              xr:xr-cli-map "transfer-id <string> schema <string> ";
+              key "schema-name";
+              description
+                "Schema that contains objects to be collected";
+              leaf schema-name {
+                xr:xr-xml-map "snmp_bulkstat_cfg:SchemaName";
+                type xr:Cisco-ios-xr-string {
+                  length "0..32";
+                }
+                description
+                  "Schema that contains objects to be
+                  collected";
+              }
+            }
+          }
+          leaf secondary {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Secondary";
+            xr:xr-cli-map "transfer-id <string> url secondary <stri"+
+              "ng> ";
+            type string;
+            description
+              "FTP or rcp or TFTP can be used for file
+              transfer";
+          }
+          leaf type {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Type";
+            type empty;
+            description "Configure transfer list name";
+          }
+          leaf buffer-size {
+            xr:xr-xml-map "snmp_bulkstat_cfg:BufferSize";
+            xr:xr-cli-map "transfer-id <string> buffer-size <number"+
+              "> ";
+            type uint32 {
+              range "1024..2147483647";
+            }
+            units "byte";
+            description "Bulkstat data file maximum size in bytes";
+          }
+          leaf retain {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Retain";
+            xr:xr-cli-map "transfer-id <string> retain <number> ";
+            type uint32 {
+              range "0..20000";
+            }
+            units "minute";
+            description "Retention period in minutes";
+          }
+          leaf format {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Format";
+            xr:xr-cli-map "transfer-id <string> format (bulkBinary)"+
+              "|(bulkASCII)|(schemaASCII) ";
+            type Snmp-bulkstat-file-format;
+            description "Format of the bulk data file";
+          }
+          leaf retry {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Retry";
+            xr:xr-cli-map "transfer-id <string> retry <number> ";
+            type uint32 {
+              range "0..100";
+            }
+            description "Number of transmission retries";
+          }
+          leaf enable {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Enable";
+            xr:xr-cli-map "transfer-id <string> enable ";
+            type empty;
+            description
+              "Start Data Collection for this Configuration";
+          }
+          leaf primary {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Primary";
+            xr:xr-cli-map "transfer-id <string> url primary <string"+
+              "> ";
+            type string;
+            description
+              "FTP or rcp or TFTP can be used for file
+              transfer";
+          }
+          leaf interval {
+            xr:xr-xml-map "snmp_bulkstat_cfg:Interval";
+            xr:xr-cli-map "transfer-id <string> transfer-interval <"+
+              "number> ";
+            type int32;
+            units "minute";
+            description
+              "Periodicity for the transfer of bulk data in
+              minutes";
+          }
+          leaf transfer-name {
+            xr:xr-xml-map "snmp_bulkstat_cfg:TransferName";
+            type xr:Cisco-ios-xr-string {
+              length "0..32";
+            }
+            description "Name of bulk transfer";
+          }
+        }
+      }
+      leaf memory {
+        xr:xr-xml-map "snmp_bulkstat_cfg:Memory";
+        xr:xr-cli-map "mib bulkstat max-procmem-size <number> ";
+        type uint32 {
+          range "100..200000";
+        }
+        units "kilobyte";
+        description "per process memory limit in kilo bytes";
+      }
+    }
+
+    container default-community-maps {
+      xr:xr-xml-map "snmp_cfg:DefaultCommunityMapTable";
+      description
+        "Container class to hold unencrpted community map";
+
+      list default-community-map {
+        xr:xr-xml-map "snmp_cfg:DefaultCommunityMap";
+        key "community-name";
+        description "Unencrpted SNMP community map name ";
+        leaf community-name {
+          xr:xr-xml-map "snmp_cfg:CommunityName";
+          type xr:Cisco-ios-xr-string {
+            length "0..128";
+          }
+          description "SNMP community map";
+        }
+        leaf context {
+          xr:xr-xml-map "snmp_cfg:Context";
+          type string;
+          description "SNMP Context Name ";
+        }
+        leaf security {
+          xr:xr-xml-map "snmp_cfg:Security";
+          type string;
+          description "SNMP Security Name ";
+        }
+        leaf target-list {
+          xr:xr-xml-map "snmp_cfg:TargetList";
+          type string;
+          description "target list name ";
+        }
+      }
+    }
+
+    container overload-control {
+      xr:xr-xml-map "snmp_cfg:OverloadControl";
+      presence "Indicates a overload-control node is configured.";
+      description
+        "Set overload control params for handling
+        incoming messages";
+      leaf drop-time {
+        xr:xr-xml-map "snmp_cfg:DropTime";
+        type uint32 {
+          range "0..300";
+        }
+        units "second";
+        mandatory true;
+        description
+          "Drop time in seconds for incoming queue
+          (default 1 sec)";
+      }
+      leaf throttle-rate {
+        xr:xr-xml-map "snmp_cfg:ThrottleRate";
+        type uint32 {
+          range "0..1000";
+        }
+        units "millisecond";
+        mandatory true;
+        description
+          "Throttle time in milliseconds for incoming
+          queue (default 500 msec)";
+      }
+    }
+
+    container timeouts {
+      xr:xr-xml-map "snmp_cfg:Timeouts";
+      description "SNMP timeouts";
+      leaf duplicates {
+        xr:xr-xml-map "snmp_cfg:Duplicates";
+        xr:xr-cli-map "timeouts duplicate <number> ";
+        type uint32 {
+          range "0..20";
+        }
+        units "second";
+        default "1";
+        description "Duplicate request feature timeout";
+      }
+      leaf in-qdrop {
+        xr:xr-xml-map "snmp_cfg:InQdrop";
+        xr:xr-cli-map "timeouts inQdrop <number> ";
+        type uint32 {
+          range "0..20";
+        }
+        units "second";
+        default "10";
+        description "incoming queue drop feature timeout";
+      }
+      leaf subagent {
+        xr:xr-xml-map "snmp_cfg:Subagent";
+        xr:xr-cli-map "timeouts subagent <number> ";
+        type uint32 {
+          range "1..20";
+        }
+        units "second";
+        default "10";
+        description "Sub-Agent Request timeout";
+      }
+      leaf pdu-stats {
+        xr:xr-xml-map "snmp_cfg:PDUStats";
+        xr:xr-cli-map "timeouts pdu stats <number> ";
+        type uint32 {
+          range "1..10";
+        }
+        units "second";
+        default "2";
+        description "SNMP pdu statistics timeout";
+      }
+    }
+
+    container users {
+      xr:xr-xml-map "snmp_cfg:UserTable";
+      description "Define a user who can access the SNMP engine";
+
+      list user {
+        xr:xr-xml-map "snmp_cfg:User";
+        xr:xr-cli-map "user <string> <string> [remote <IPv4"+
+          "/IPv6 address> [udp-port <number>]] (v1)|(v2c)|(v3 [auth"+
+          " (md5)|(sha) ([0] <string>)|(clear)|((7)|(encrypted) <st"+
+          "ring>)|(<string>) [priv (des56)|(3des)|(aes (128)|(192)|"+
+          "(256)) ([0] <string>)|(clear)|((7)|(encrypted) <string>)"+
+          "|(<string>)]])] [IPv4 <string> [IPv6 <string>]|IPv6 <str"+
+          "ing> [IPv4 <string>]|<string>] [SDROwner|LROwner|SystemO"+
+          "wner] ";
+        key "user-name";
+        description "Name of the user";
+        leaf user-name {
+          xr:xr-xml-map "snmp_cfg:UserName";
+          type string;
+          description "Name of the user";
+        }
+        leaf group-name {
+          xr:xr-xml-map "snmp_cfg:GroupName";
+          type string;
+          mandatory true;
+          description "Group to which the user belongs";
+        }
+        leaf version {
+          xr:xr-xml-map "snmp_cfg:Version";
+          type User-snmp-version;
+          mandatory true;
+          description "SNMP version to be used. v1,v2c or v3";
+        }
+        leaf authentication-password-configured {
+          xr:xr-xml-map "snmp_cfg:AuthenticationPasswordConfigured";
+          type empty;
+          description
+            "Flag to indicate that authentication password
+            is configred for version 3";
+        }
+        leaf algorithm {
+          xr:xr-xml-map "snmp_cfg:Algorithm";
+          type Snmp-hash-algorithm;
+          description "The algorithm used md5 or sha";
+        }
+        leaf authentication-password {
+          xr:xr-xml-map "snmp_cfg:AuthenticationPassword";
+          type xr:Proprietary-password;
+          description "The authentication password";
+        }
+        leaf privacy-password-configured {
+          xr:xr-xml-map "snmp_cfg:PrivacyPasswordConfigured";
+          type empty;
+          description
+            "Flag to indicate that the privacy password is
+            configured for version 3";
+        }
+        leaf priv-algorithm {
+          xr:xr-xml-map "snmp_cfg:Priv_Algorithm";
+          type Snmp-priv-algorithm;
+          description
+            "The algorithm used des56 or aes128 or aes192or
+            aes256 or 3des";
+        }
+        leaf privacy-password {
+          xr:xr-xml-map "snmp_cfg:PrivacyPassword";
+          type xr:Proprietary-password;
+          description "The privacy password";
+        }
+        leaf v4acl-type {
+          xr:xr-xml-map "snmp_cfg:V4ACLType";
+          type Snmpacl;
+          description "Access-list type";
+        }
+        leaf v4-access-list {
+          xr:xr-xml-map "snmp_cfg:V4AccessList";
+          type string;
+          description "Ipv4 Access-list name";
+        }
+        leaf v6acl-type {
+          xr:xr-xml-map "snmp_cfg:V6ACLType";
+          type Snmpacl;
+          description "Access-list type";
+        }
+        leaf v6-access-list {
+          xr:xr-xml-map "snmp_cfg:V6AccessList";
+          type string;
+          description "Ipv6 Access-list name";
+        }
+        leaf owner {
+          xr:xr-xml-map "snmp_cfg:Owner";
+          type Snmp-owner-access;
+          description
+            "The system access either SDROwner or
+            SystemOwner";
+        }
+        leaf remote-address {
+          xr:xr-xml-map "snmp_cfg:RemoteAddress";
+          type inet:ip-address-no-zone;
+          description "IP address of remote SNMP entity";
+        }
+        leaf port {
+          xr:xr-xml-map "snmp_cfg:Port";
+          type xr:Cisco-ios-xr-port-number;
+          description "UDP port number";
+        }
+      }
+    }
+
+    container vrfs {
+      xr:xr-xml-map "snmp_cfg:VRFTable";
+      description "SNMP VRF configuration commands";
+
+      list vrf {
+        xr:xr-xml-map "snmp_cfg:VRF";
+        key "name";
+        description "VRF name";
+        leaf name {
+          xr:xr-xml-map "snmp_cfg:Name";
+          type xr:Cisco-ios-xr-string;
+          description "VRF name";
+        }
+        uses TRAP-HOST-TABLE;
+        uses CONTEXT-TABLE;
+        uses CONTEXT-MAPPING-TABLE;
+      }
+    }
+
+    container groups {
+      xr:xr-xml-map "snmp_cfg:GroupTable";
+      description "Define a User Security Model group";
+
+      list group {
+        xr:xr-xml-map "snmp_cfg:Group";
+        xr:xr-cli-map "group <string> <enum> [notify <string>|read "+
+          "<string>|write <string>|context <string>] [IPv4 <string>"+
+          " [IPv6 <string>]|IPv6 <string> [IPv4 <string>]|<string>]"+
+          " ";
+        key "name";
+        description "Name of the group";
+        leaf name {
+          xr:xr-xml-map "snmp_cfg:Name";
+          type xr:Cisco-ios-xr-string {
+            length "0..128";
+          }
+          description "Name of the group";
+        }
+        leaf snmp-version {
+          xr:xr-xml-map "snmp_cfg:SNMPVersion";
+          type Group-snmp-version;
+          mandatory true;
+          description "snmp version";
+        }
+        leaf security-model {
+          xr:xr-xml-map "snmp_cfg:SecurityModel";
+          type Snmp-security-model;
+          description
+            "security model like auth/noAuth/Priv
+            applicable for v3";
+        }
+        leaf notify-view {
+          xr:xr-xml-map "snmp_cfg:NotifyView";
+          type string;
+          description "notify view name";
+        }
+        leaf read-view {
+          xr:xr-xml-map "snmp_cfg:ReadView";
+          type string;
+          description "read view name";
+        }
+        leaf write-view {
+          xr:xr-xml-map "snmp_cfg:WriteView";
+          type string;
+          description "write view name";
+        }
+        leaf v4acl-type {
+          xr:xr-xml-map "snmp_cfg:V4ACLType";
+          type Snmpacl;
+          description "Access-list type";
+        }
+        leaf v4-access-list {
+          xr:xr-xml-map "snmp_cfg:V4AccessList";
+          type string;
+          description "Ipv4 Access-list name";
+        }
+        leaf v6acl-type {
+          xr:xr-xml-map "snmp_cfg:V6ACLType";
+          type Snmpacl;
+          description "Access-list type";
+        }
+        leaf v6-access-list {
+          xr:xr-xml-map "snmp_cfg:V6AccessList";
+          type string;
+          description "Ipv6 Access-list name";
+        }
+        leaf context-name {
+          xr:xr-xml-map "snmp_cfg:ContextName";
+          type string;
+          description "Context name";
+        }
+      }
+    }
+    leaf inform-retries {
+      xr:xr-xml-map "snmp_cfg:InformRetries";
+      xr:xr-cli-map "inform retries <number> ";
+      type uint32 {
+        range "0..100";
+      }
+      description
+        "Number of times to retry an Inform request
+        (default 3)";
+    }
+    leaf trap-port {
+      xr:xr-xml-map "snmp_cfg:TrapPort";
+      xr:xr-cli-map "port <number> ";
+      type uint32 {
+        range "1024..65535";
+      }
+      description "Change the source port of all traps";
+    }
+    leaf oid-poll-stats {
+      xr:xr-xml-map "snmp_cfg:OIDPollStats";
+      xr:xr-cli-map "oid-poll-stats ";
+      type empty;
+      description "Enable Poll OID statistics";
+    }
+    leaf trap-source {
+      xr:xr-xml-map "snmp_cfg:TrapSource";
+      type xr:Interface-name;
+      description
+        "Assign an interface for the source address of
+        all traps";
+    }
+    leaf vrf-authentication-trap-disable {
+      xr:xr-xml-map "snmp_cfg:VRFAuthenticationTrapDisable";
+      xr:xr-cli-map "authentication vrf disable ";
+      type empty;
+      description
+        "Disable authentication traps for packets on a
+        vrf";
+    }
+    leaf inform-timeout {
+      xr:xr-xml-map "snmp_cfg:InformTimeout";
+      xr:xr-cli-map "inform timeout <number> ";
+      type uint32 {
+        range "1..42949671";
+      }
+      units "second";
+      description
+        "Timeout value in seconds for Inform request
+        (default 15 sec)";
+    }
+    leaf trap-source-ipv6 {
+      xr:xr-xml-map "snmp_cfg:TrapSource_IPV6";
+      type xr:Interface-name;
+      description
+        "Assign an interface for the source IPV6 address
+        of all traps";
+    }
+    leaf packet-size {
+      xr:xr-xml-map "snmp_cfg:PacketSize";
+      xr:xr-cli-map "packetsize <number> ";
+      type uint32 {
+        range "484..65500";
+      }
+      description "Largest SNMP packet size";
+    }
+    leaf throttle-time {
+      xr:xr-xml-map "snmp_cfg:ThrottleTime";
+      xr:xr-cli-map "throttle-time <number> ";
+      type uint32 {
+        range "50..1000";
+      }
+      description
+        "Throttle time for incoming queue (default 0
+        msec)";
+    }
+    leaf inform-pending {
+      xr:xr-xml-map "snmp_cfg:InformPending";
+      xr:xr-cli-map "inform pending <number> ";
+      type uint32 {
+        range "0..4294967295";
+      }
+      description
+        "Max nmber of informs to hold in queue, (default
+        25)";
+    }
+    uses TRAP-HOST-TABLE;
+    uses CONTEXT-TABLE;
+    uses CONTEXT-MAPPING-TABLE;
+  }
+
+  container mib {
+    xr:xr-xml-map "snmp_cfg:MIB";
+    description "mib";
+  }
+}
\ No newline at end of file
diff --git a/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-types@2015-06-29.yang b/cisco-xrmodels/src/main/yang/Cisco-IOS-XR-types@2015-06-29.yang
new file mode 100644 (file)
index 0000000..adaf8bc
--- /dev/null
@@ -0,0 +1,444 @@
+module Cisco-IOS-XR-types {
+
+  namespace "http://cisco.com/ns/yang/cisco-xr-types";
+  prefix "xr";
+
+  organization "Cisco Systems, Inc.";
+
+  contact 
+    "Cisco Systems, Inc.
+     Customer Service
+
+     Postal: 170 W Tasman Drive
+     San Jose, CA 95134
+
+     Tel: +1 1800 553-NETS
+
+     E-mail: cs-yang@cisco.com";
+
+
+  description       
+    "This module contains a collection of IOS-XR derived YANG data 
+     types.
+    
+     Copyright (c) 2013-2015 by Cisco Systems, Inc.
+     All rights reserved.";
+
+  revision "2015-06-29" {
+    description
+     "This revision adds the following new data types:
+      - Rpl-policy
+      - Rpl-set";
+  }
+
+  revision "2015-05-18" {
+    description
+      "Updated Node-id string pattern to match also shorter ncs4k
+       node names.";
+  }
+
+  revision "2015-01-19" {
+    description
+     "This revision adds the following new data types:
+      - Bgp-ipv4-flowspec-address
+      - Bgp-ipv6-flowspec-address";
+  }
+
+  revision "2013-07-22" {
+    description
+      "Initial revision.";
+  }
+
+  extension xr-cli-map {
+    argument "cli-command";
+    description "The xr-cli-map statement takes as an argument
+                 relevant CLI configuration command.";
+  }
+  
+  extension xr-xml-map {
+    argument "xr-xml-node";
+    description "The xr-xml-map statement takes as an argument
+                 relevant Cisco XML Schema node name.";
+  }
+  
+  typedef Route-dist {
+    type string {
+      pattern "[a-fA-F0-9]{16}";
+    }
+    description "Route distinguisher in hexadecimal notation.";
+  }
+
+  typedef Bgp-l2vpn-evpn-addrs {
+    type string {
+      pattern "[a-fA-F0-9]{58}";
+    }
+    description "L2VPN EVPN Address in hexadecimal notation.";
+  }
+
+  typedef Bgp-ls-addr {
+    type string {
+      pattern "[a-fA-F0-9]+";
+    }
+    description "BGP link state unicast address in hexadecimal
+                 notation.";
+  }
+
+  typedef Bgp-ipv6-mvpn-addr {
+    type string {
+      pattern "[a-fA-F0-9]{104}";
+    }
+    description "An IPV6 MVPN address in hexadecimal notation.";
+  }
+
+  typedef Bgp-ipv4-mvpn-addr {
+    type string {
+      pattern "[a-fA-F0-9]{56}";
+    }
+    description "An IPV4 MVPN address in hexadecimal notation.";
+  }
+
+  typedef Bgp-rt-constrt-addr {
+    type string {
+      pattern "[a-fA-F0-9]{24}";
+    }
+    description 
+      "An IPV4 RTConstraint address in hexadecimal notation.";
+  }
+
+  typedef Bgp-ipv4-mdt-addr {
+    type string {
+      pattern "(([a-f0-9]{16}-)(([1-9]?[0-9]|1[0-9][0-9]|2[0-4]"+
+        "[0-9]|25[0-5])\.){3}([1-9]?[0-9]|1[0-9][0-9]|2[0-4][0-9]"+
+        "|25[0-5]))";
+    }
+    description "An IPV4 MDT address in dotted decimal notation.
+                 An IPv4 MDT address should be of the form 
+                 0000006400000065-129.29.83.45. This datatype 
+                 restricts the value of each field 16 digits in 
+                 hexadecimal for RD field and between 0 and 255
+                 for IPv4 address field, i.e. 
+                 [0000000000000000-ffffffffffffffff]-
+                 [0-255].[0-255].[0-255].[0-255].";
+  }
+
+  typedef Bgp-ipv4-tunnel-addr {
+    type string {
+      pattern "((0:|[1-9][0-9]{0,4}:)"+
+        "(([1-9]?[0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\.){3}"+
+        "([1-9]?[0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5]))";
+    }
+    description "An IPV4 tunnel address in dotted decimal notation.
+                 An IPv4 tunnel address should be of the form 
+                 65535:129.29.83.45. This datatype restricts the 
+                 value of each field between 0 and 65535 for prefix
+                 field and 0 and 255 for IPv4 address field, i.e.
+                 [0-65535]:[0-255].[0-255].[0-255].[0-255]";
+  }
+
+  typedef Cisco-ios-xr-port-number {
+    type uint16 {
+      range "1..65535";
+    }
+    description "Port number of range from 1 to 65535";
+  }
+
+  typedef Interface-name {
+    type string {
+      pattern "(([a-zA-Z0-9_]*\d+/){3}\d+)|"+
+              "(([a-zA-Z0-9_]*\d+/){4}\d+)|"+
+              "(([a-zA-Z0-9_]*\d+/){3}\d+\.\d+)|"+
+              "(([a-zA-Z0-9_]*\d+/){2}([a-zA-Z0-9_]*\d+))|"+
+              "(([a-zA-Z0-9_]*\d+/){2}([a-zA-Z0-9_]+))|"+
+              "([a-zA-Z0-9_-]*\d+)|"+
+              "([a-zA-Z0-9_-]*\d+\.\d+)|"+
+              "(mpls)|(dwdm)";
+    }
+    description "An interface name specifying an interface type and 
+                 instance.
+                 Interface represents a string defining an interface
+                 type and instance, e.g. MgmtEth0/4/CPU1/0 or
+                 TenGigE0/2/0/0.2 or Bundle-Ether9 or 
+                 Bundle-Ether9.98";
+  }
+  
+  typedef Cisco-ios-xr-string {
+    type string {
+      pattern "[\w\-\.:,_@#%$\+=\|;]+";
+    }
+    description "Special characters are not allowed.";
+  }
+
+  typedef Ipv4-prefix-length {
+    type uint8 {
+      range "0..32";
+    }
+    description "An IPv4 address prefix length. 
+                 Must lie between 0 and 32 inclusive.";
+  }
+  
+  typedef Ipv6-prefix-length {
+    type uint8 {
+      range "0..128";
+    }
+    description "An IPv6 address prefix length. 
+                 Must lie between 0 and 32 inclusive.";
+  }
+  
+  typedef Rack-id {
+    type string {
+      pattern "[a-zA-Z0-9_]*\d+";
+    }
+    description "Names the rack portion of a NodeID 
+                 Rack/Slot/Instance triple";
+  }
+  
+  typedef Slot-id {
+    type string {
+      pattern "[a-zA-Z0-9_]*\d+";
+    }
+    description "Names the slot portion of a NodeID 
+                 Rack/Slot/Instance triple";
+  }
+  
+  typedef Instance-id {
+    type string {
+      pattern "[a-zA-Z0-9_]*\d+";
+    }
+    description "Names the instance portion of a NodeID 
+                 Rack/Slot/Instance triple";
+  }
+  
+  typedef Sub-instance-id {
+    type string {
+      pattern "[a-zA-Z0-9_]*\d+";
+    }
+    description "Names the sub-instance portion of an extended
+                 NodeID Rack/Slot/Instance/SubInstance";
+  }
+  
+  typedef Encryption-type {
+    type enumeration {
+      enum none {
+        value "0";
+        description "The password string is clear text.";
+      }
+      enum md5 {
+        value "1";
+        description "The password is encrypted to an MD5 digest.";
+      }
+      enum proprietary {
+        value "2";
+        description "The password is encrypted using Cisco type 7 
+                     password encryption.";
+      }
+    }
+    description "The type of encryption used on a password string.";
+  
+  }
+  
+  typedef Hex-integer {
+    type string {
+      pattern "[0-9a-fA-F]{1,8}";
+    }
+    description "An unsigned 32-bit integer represented in
+                 hexadecimal format.";
+  }
+  
+  typedef Osi-system-id {
+    type string {
+      pattern "[a-fA-F0-9]{4}(\.[a-fA-F0-9]{4}){2}";
+    }
+    description "An OSI system ID should be of the form 
+                 0123.4567.89ab. This data type restricts each
+                 character to a hex character.";
+  }
+  
+  typedef Osi-area-address {
+    type string {
+      pattern "[a-fA-F0-9]{2}(\.[a-fA-F0-9]{4}){0,6}";
+    }
+    description "An OSI area address should consist of an odd number
+                 of octets, and be of the form 01 or 01.2345 etc up
+                 to 01.2345.6789.abcd.ef01.2345.6789. This data type
+                 restricts each character to a hex character.";
+  }
+  
+  typedef Isis-node-id {
+    type string {
+      pattern "[a-fA-F0-9]{4}(\.[a-fA-F0-9]{4}){2}\.[a-fA-F0-9]{2}";
+    }
+    description "An ISIS node ID should be of the form 
+                 0123.4567.89ab.cd. This data type restricts each
+                 character to a hex character.";
+  }
+  
+  typedef Isis-snpa {
+    type string {
+      pattern "[a-fA-F0-9]{4}(\.[a-fA-F0-9]{4}){2}";
+    }
+    description "String representation of a SNPA, 802.2 MAC address
+                 in canonical format, e.g. 0123.4567.89ab";
+  }
+  
+  typedef Isis-lsp-id {
+    type string {
+      pattern "[a-fA-F0-9]{4}(\.[a-fA-F0-9]{4}){2}\.[a-fA-F0-9]{2}"+
+               "\-[a-fA-F0-9]{2}";
+    }
+    description "An ISIS LSP ID should be of the form 
+                 0123.4567.89ab.cd-ef. This data type restricts each
+                 character to a hex character.";
+  }
+  
+  typedef Osi-net {
+    type string {
+      pattern 
+        "[a-fA-F0-9]{2}(\.[a-fA-F0-9]{4}){3,9}\.[a-fA-F0-9]{2}";
+    }
+    description "An OSI NET should consist of an even number of 
+                 octets, and be of the form 01.2345.6789.abcd.ef etc
+                 up to 
+                 01.2345.6789.abcd.ef01.2345.6789.abcd.ef01.2345.67.
+                 This data type restricts each character to a hex
+                 character.";
+  }
+  
+  typedef String-identifier {
+    type string {
+      pattern "[a-zA-Z][\w\-]*";
+    }
+    description "A string for specifying identifier.";
+  }
+  
+  typedef Char-num {
+    type union {
+      type string {
+        pattern "(\p{IsBasicLatin}|\p{IsLatin-1Supplement})*";
+      }
+      type uint8;
+    }
+    description "Takes a character or its ASCII decimal equivalent
+                 (0-255).";
+  }
+  
+  typedef Tty-escape-char-num {
+    type union {
+      type string {
+        pattern "((\p{IsBasicLatin}|\p{IsLatin-1Supplement})*)"+
+                "|(DEFAULT)|(BREAK)|(NONE)";
+      }
+      type uint8;
+    }
+    description "Escape character or its ASCII decimal equivalent
+                 (0-255) or one of the three string DEFAULT, BREAK,
+                 NONE.";
+  }
+  
+  typedef Extended-node-id {
+    type string {
+      pattern "([a-zA-Z0-9_]*\d+/){3}([a-zA-Z0-9_]*\d+)";
+    }
+    description "A location used as value information and specified
+                 as a Rack/Slot/Instance/SubInstance, e.g. 
+                 0/1/CPU0/NPU0";
+  }
+  
+  typedef Node-id {
+    type string {
+      pattern "([a-zA-Z0-9_]*\d+/){1,2}([a-zA-Z0-9_]*\d+)";
+    }
+    description "A location used as value information and specified
+                 as a Rack/Slot/Instance triple, e.g. F0/SC1/0.";
+  }
+
+  typedef Pq-node-id {
+    type string {
+      pattern "((([a-zA-Z0-9_]*\d+)|(\*))/){2}(([a-zA-Z0-9_]*\d+)"+
+              "|(\*))";
+    }
+    description "Partially qualified location which is used for 
+                 wildcarding location specifications, e.g. 1/*/*";
+  }  
+  
+  typedef Md5-password {
+    type string {
+      pattern "(!.+)|([^!].+)";
+    }
+    description 
+      "The Md5-password type is used to store password using the MD5
+       hash function.
+       When a clear text value is set to a leaf of this type, the
+       server calculates a password hash and stores the result
+       in the datastore. The password is never stored in clear text.
+
+       When a leaf of this type is read, the stored password hash is
+       returned.
+
+       A value of this type matches one of the forms:
+
+         !<clear text password>
+         <password hash>
+         
+       The '!' prefix signals that the value is clear text. When
+       such a value is received by the server, a hash value is
+       calculated. This value is stored in the configuration data 
+       store.
+
+       If a value starting without '!' is received, the server knows 
+       that the value already represents a hashed value, and stores 
+       it as is in the data store.";
+  }
+  
+  typedef Proprietary-password {
+    type string {
+      pattern "(!.+)|([^!].+)";
+    }
+    description 
+      "The Proprietary-password type is used to store password 
+       using the Cisco proprietary hash function.
+       When a clear text value is set to a leaf of this type, the
+       server calculates a password hash and stores the result
+       in the datastore. The password is never stored in clear text.
+
+       When a leaf of this type is read, the stored password hash is
+       returned.
+
+       A value of this type matches one of the forms:
+
+         !<clear text password>
+         <password hash>
+         
+       The '!' prefix signals that the value is clear text. When
+       such a value is received by the server, a hash value is
+       calculated. This value is stored in the configuration data 
+       store.
+
+       If a value starting without '!' is received, the server knows 
+       that the value already represents a hashed value, and stores 
+       it as is in the data store.";
+  }
+  
+  typedef Bgp-ipv4-flowspec-address {
+    type string {
+      pattern "[a-fA-F0-9]{4096}";
+    }
+    description "An IPV4 Flowspec address in hexadecimal notation.";
+  }
+
+  typedef Bgp-ipv6-flowspec-address {
+    type string {
+      pattern "[a-fA-F0-9]{4096}";
+    }
+    description "An IPV6 Flowspec address in hexadecimal notation.";
+  }
+
+  typedef Rpl-policy {
+    type string;
+    description "RPL Policy info";
+  }
+
+  typedef Rpl-set{
+    type string;
+    description "RPL Set info";
+  }
+}
\ No newline at end of file
diff --git a/edgeassure-1000/pom.xml b/edgeassure-1000/pom.xml
new file mode 100644 (file)
index 0000000..e3dd72a
--- /dev/null
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (c) 2015 Cisco Systems, Inc. All rights reserved.
+
+This program and the accompanying materials are made available under the
+terms of the Eclipse Public License v1.0 which accompanies this distribution,
+and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <parent>
+    <groupId>org.opendaylight.mdsal</groupId>
+    <artifactId>binding-parent</artifactId>
+    <version>0.9.0-SNAPSHOT</version>
+    <relativePath />
+  </parent>
+
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>org.opendaylight.unimgr</groupId>
+  <artifactId>edgeassure-1000</artifactId>
+  <version>0.1.0-SNAPSHOT</version>
+  <packaging>bundle</packaging>
+
+  <dependencies>
+    <dependency>
+      <groupId>org.opendaylight.mdsal.model</groupId>
+      <artifactId>ietf-inet-types-2013-07-15</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.mdsal.model</groupId>
+      <artifactId>ietf-yang-types-20130715</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.mdsal.model</groupId>
+      <artifactId>iana-if-type-2014-05-08</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.mdsal.model</groupId>
+      <artifactId>ietf-interfaces</artifactId>
+    </dependency>
+  </dependencies>
+
+</project>
diff --git a/edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/HostBuilder.java b/edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/HostBuilder.java
new file mode 100644 (file)
index 0000000..62ca8a6
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class HostBuilder {
+
+    public static Host getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/IpAddressBuilder.java b/edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/IpAddressBuilder.java
new file mode 100644 (file)
index 0000000..85f8077
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class IpAddressBuilder {
+
+    public static IpAddress getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/IpAddressNoZoneBuilder.java b/edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/IpAddressNoZoneBuilder.java
new file mode 100644 (file)
index 0000000..1adede9
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class IpAddressNoZoneBuilder {
+
+    public static IpAddressNoZone getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/IpPrefixBuilder.java b/edgeassure-1000/src/main/java/org/opendaylight/yang/gen/v1/urn/ietf/params/xml/ns/yang/ietf/inet/types/rev130715/IpPrefixBuilder.java
new file mode 100644 (file)
index 0000000..3b252f6
--- /dev/null
@@ -0,0 +1,19 @@
+package org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715;
+
+
+/**
+ * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation.
+ * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32).
+ *
+ * The reason behind putting it under src/main/java is:
+ * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent
+ * loss of user code.
+ *
+ */
+public class IpPrefixBuilder {
+
+    public static IpPrefix getDefaultInstance(java.lang.String defaultValue) {
+        throw new java.lang.UnsupportedOperationException("Not yet implemented");
+    }
+
+}
diff --git a/edgeassure-1000/src/main/yang/ENTITY-STATE-TC-MIB@2005-11-22.yang b/edgeassure-1000/src/main/yang/ENTITY-STATE-TC-MIB@2005-11-22.yang
new file mode 100644 (file)
index 0000000..d749952
--- /dev/null
@@ -0,0 +1,184 @@
+/*
+ * This module has been generated by smidump 0.4.8:
+ *
+ *      smidump -f yang ENTITY-STATE-TC-MIB
+ *
+ * Do not edit. Edit the source file instead!
+ */
+
+module ENTITY-STATE-TC-MIB {
+
+  /*** NAMESPACE / PREFIX DEFINITION ***/
+
+  namespace "urn:ietf:params:xml:ns:yang:smiv2:ENTITY-STATE-TC-MIB";
+  prefix "entity-state";
+
+  /*** LINKAGE (IMPORTS / INCLUDES) ***/
+
+
+  /*** META INFORMATION ***/
+
+  organization      
+   "IETF Entity MIB Working Group";
+
+  contact           
+   "General Discussion: entmib@ietf.org
+    To Subscribe:
+    http://www.ietf.org/mailman/listinfo/entmib
+    
+    http://www.ietf.org/html.charters/entmib-charter.html
+    
+    Sharon Chisholm
+    Nortel Networks
+    PO Box 3511 Station C
+    Ottawa, Ont.  K1Y 4H7
+    Canada
+    schishol@nortel.com
+    
+    David T. Perkins
+    548 Qualbrook Ct
+    San Jose, CA 95110
+    USA
+    Phone: 408 394-8702
+    dperkins@snmpinfo.com";
+
+  description       
+   "This MIB defines state textual conventions.
+    
+    Copyright (C) The Internet Society 2005.  This version
+    of this MIB module is part of RFC 4268;  see the RFC
+    itself for full legal notices.";
+
+  revision "2005-11-22" {
+    description     
+     "Initial version, published as RFC 4268.";
+  }
+
+  /*** TYPE DEFINITIONS ***/
+
+  typedef EntityAdminState {
+    type enumeration {
+      enum unknown      { value 1; }
+      enum locked       { value 2; }
+      enum shuttingDown { value 3; }
+      enum unlocked     { value 4; }
+    }
+    description     
+     " Represents the various possible administrative states.
+      
+      
+      
+      
+      
+      A value of 'locked' means the resource is administratively
+      prohibited from use.  A value of 'shuttingDown' means that
+      usage is administratively limited to current instances of
+      use.  A value of 'unlocked' means the resource is not
+      administratively prohibited from use.  A value of
+      'unknown' means that this resource is unable to
+      report administrative state.";
+  }
+
+  typedef EntityOperState {
+    type enumeration {
+      enum unknown  { value 1; }
+      enum disabled { value 2; }
+      enum enabled  { value 3; }
+      enum testing  { value 4; }
+    }
+    description     
+     " Represents the possible values of operational states.
+      
+      A value of 'disabled' means the resource is totally
+      inoperable.  A value of 'enabled' means the resource
+      is partially or fully operable.  A value of 'testing'
+      means the resource is currently being tested
+      and cannot therefore report whether it is operational
+      or not.  A value of 'unknown' means that this
+      resource is unable to report operational state.";
+  }
+
+  typedef EntityUsageState {
+    type enumeration {
+      enum unknown { value 1; }
+      enum idle    { value 2; }
+      enum active  { value 3; }
+      enum busy    { value 4; }
+    }
+    description     
+     " Represents the possible values of usage states.
+      A value of 'idle' means the resource is servicing no
+      users.  A value of 'active' means the resource is
+      currently in use and it has sufficient spare capacity
+      to provide for additional users.  A value of 'busy'
+      means the resource is currently in use, but it
+      currently has no spare capacity to provide for
+      additional users.  A value of 'unknown' means
+      that this resource is unable to report usage state.";
+  }
+
+  typedef EntityAlarmStatus {
+    type bits {
+      bit unknown       { position 0; }
+      bit underRepair   { position 1; }
+      bit critical      { position 2; }
+      bit major         { position 3; }
+      bit minor         { position 4; }
+      bit warning       { position 5; }
+      bit indeterminate { position 6; }
+    }
+    description     
+     " Represents the possible values of alarm status.
+      An Alarm [RFC3877] is a persistent indication
+      of an error or warning condition.
+      
+      When no bits of this attribute are set, then no active
+      alarms are known against this entity and it is not under
+      repair.
+      
+      When the 'value of underRepair' is set, the resource is
+      currently being repaired, which, depending on the
+      implementation, may make the other values in this bit
+      string not meaningful.
+      
+      When the value of 'critical' is set, one or more critical
+      alarms are active against the resource.  When the value
+      of 'major' is set, one or more major alarms are active
+      against the resource.  When the value of 'minor' is set,
+      one or more minor alarms are active against the resource.
+      When the value of 'warning' is set, one or more warning
+      alarms are active against the resource.  When the value
+      of 'indeterminate' is set, one or more alarms of whose
+      perceived severity cannot be determined are active
+      against this resource.
+      
+      A value of 'unknown' means that this resource is
+      unable to report alarm state.";
+  }
+
+  typedef EntityStandbyStatus {
+    type enumeration {
+      enum unknown          { value 1; }
+      enum hotStandby       { value 2; }
+      enum coldStandby      { value 3; }
+      enum providingService { value 4; }
+    }
+    description     
+     " Represents the possible values of standby status.
+      
+      A value of 'hotStandby' means the resource is not
+      providing service, but it will be immediately able to
+      take over the role of the resource to be backed up,
+      without the need for initialization activity, and will
+      contain the same information as the resource to be
+      backed up.  A value of 'coldStandy' means that the
+      resource is to back up another resource, but will not
+      be immediately able to take over the role of a resource
+      to be backed up, and will require some initialization
+      activity.  A value of 'providingService' means the
+      resource is providing service.  A value of
+      'unknown' means that this resource is unable to
+      report standby state.";
+  }
+
+} /* end of module ENTITY-STATE-TC-MIB */
diff --git a/edgeassure-1000/src/main/yang/msea-types@2016-02-29.yang b/edgeassure-1000/src/main/yang/msea-types@2016-02-29.yang
new file mode 100644 (file)
index 0000000..8f015cd
--- /dev/null
@@ -0,0 +1,297 @@
+module msea-types {\r
+    \r
+  namespace "http://www.microsemi.com/microsemi-edge-assure/msea-types";\r
+  prefix "msea-types"; //MicroSemi EdgeAssure (msea)\r
+\r
+  organization\r
+   "Microsemi Inc., FTD Division";\r
+\r
+  contact           \r
+   "Web URL: http://www.microsemi.com/\r
+    E-mail:  info@microsemi.com\r
+    Postal:  Microsemi Corporation Corporate Headquarters\r
+             One Enterprise Aliso Viejo, \r
+             CA 92656\r
+             U.S.A.\r
+    Phone:   +1 949 380 6100\r
+    Fax:     +1 949 215-4996";\r
+\r
+  description       \r
+   "This module contains a collection of generally useful derived\r
+    YANG data types for VLans and Meps and such.\r
+       \r
+    Copyright 2016 Microsemi Inc.\r
+    All rights reserved.";\r
+\r
+  revision "2016-02-29" {\r
+    description     \r
+     "Initial version - Sean Condon, Microsemi";\r
+    reference\r
+        "Eagle EANTC Tail-f Inter-operation Summary Revision 1.0 16th Feb 2016";\r
+  }\r
+\r
+  //\r
+  // Extensions related to Edge Assure\r
+  //\r
+  extension not-changeable {\r
+       description\r
+         "Marks the leaf as being settable at creation time \r
+          only and not writable thereafter";\r
+  }\r
+    \r
+  //\r
+  // Type definitions related to Edge Assure\r
+  //\r
+  typedef mep-id-type {\r
+    type uint16 {\r
+      range "1..8191";\r
+    }\r
+\r
+    description\r
+      "Maintenance association End Point Identifier (MEPID): A small integer,\r
+       unique over a given Maintenance Association, identifying a\r
+       specific MEP.";\r
+    reference\r
+      "[802.1q] 3.19 and 19.2.1";\r
+  }\r
+\r
+  typedef vlan-id-type {\r
+    type uint16 {\r
+      range "1..4094";\r
+    }\r
+\r
+    description\r
+      "The VLAN-ID that uniquely identifies a VLAN.  This is the 12-bit VLAN-ID\r
+       used in the VLAN Tag header.";\r
+\r
+    reference\r
+      "[802.1q] 9.6";\r
+  }\r
+\r
+  typedef port-status-type {\r
+    type enumeration {\r
+      enum no-status-tlv {\r
+          description "Indicates either that no CCM has been received or that \r
+                       no port status TLV was present in the last CCM received.";\r
+      }\r
+      enum blocked {\r
+          description "Ordinary data cannot pass freely through the port on \r
+                       which the remote MEP resides. Value of enableRmepDefect \r
+                       is equal to false.";\r
+      }\r
+      enum up {\r
+          description "Ordinary data can pass freely through the port on which\r
+                       the remote MEP resides. Value of enableRmepDefect is \r
+                       equal to true.";\r
+      }\r
+    }    \r
+\r
+    description\r
+      "The set of values available from the Port Status TLV in CCM PDUs\r
+       including the default no-status-tlv";\r
+\r
+    reference\r
+      "[802.1q] 20.19.3, 12.14.7.6.3:f\r
+       IEEE8021-CFM-MIB.Dot1agCfmPortStatus";\r
+  }\r
+\r
+  typedef interface-status-type {\r
+    type enumeration {\r
+      enum no-status-tlv {\r
+          description "Indicates either that no CCM has been received or that\r
+                       no interface status TLV was present in the last CCM received.";\r
+      }\r
+      enum up {\r
+          description "The interface is ready to pass packets.";\r
+      }\r
+      enum down {\r
+          description "The interface cannot pass packets.";\r
+      }\r
+      enum testing {\r
+          description "The interface is in some test mode.";\r
+      }\r
+      enum unknown {\r
+          description "The interface status cannot be determined for some reason.";\r
+      }\r
+      enum dormant {\r
+          description "The interface is not in a state to pass\r                          packets but is in a pending state, waiting\r                     for some external event.";\r
+      }\r
+      enum not-present {\r
+          description "Some component of the interface is missing.";\r
+      }\r
+      enum lower-layer-down {\r
+          description "The interface is down due to state of the lower layer \r
+                       interfaces.";\r
+      }\r
+    }\r
+\r
+    description\r
+      "The set of values available from the Interface Status TLV in CCM PDUs\r
+       including the default no-status-tlv";\r
+    reference\r
+      "[802.1q] 20.19.4, 12.14.7.6.3:g\r
+       IEEE8021-CFM-MIB.Dot1agCfmInterfaceStatus";\r
+  }\r
+  \r
+  typedef mac-address-and-uint-type {\r
+    type binary {\r
+      length "8";\r
+    } \r
+    description\r
+      "A MAC address and a two-octet unsigned integer";\r
+    reference\r
+      "[802.1q] IEEE8021-CFM-MIB.Dot1agCfmMaintDomainNameType";\r
+  }\r
+\r
+  typedef md-level-type {\r
+    type uint8 {\r
+      range "0..7";\r
+    }\r
+\r
+    description\r
+      "Maintenance Domain Level (MD Level) identifier.  Higher numbers\r
+       correspond to higher Maintenance Domains, those with the greatest\r
+       physical reach, with the highest values for customers' CFM PDUs.\r
+       Lower numbers correspond to lower Maintenance Domains, those with\r
+       more limited physical reach, with the lowest values for CFM PDUs\r
+       protecting single bridges or physical links.";\r
+\r
+    reference\r
+      "[802.1q] 18.3, 21.4.1, IEEE8021-CFM-MIB.Dot1agCfmMDLevel";\r
+  }\r
+\r
+  typedef priority-type {\r
+    type uint8 {\r
+      range "0..7";\r
+    }\r
+\r
+    description\r
+      "A 3 bit priority value to be used in the VLAN tag, if present\r
+       in the transmitted frame.";\r
+    reference\r
+      "[802.1q] 12.14.7.3.2:e";\r
+  }\r
+  \r
+  typedef cos-color-type {\r
+    type enumeration {\r
+      enum "green" {\r
+         description "Change color to green";\r
+      }\r
+      enum "yellow" {\r
+         description "Change color to yellow";\r
+      }\r
+      enum "drop" {\r
+         description "Delete color information";\r
+      }\r
+    }\r
+    description\r
+      "TBD";\r
+    reference "[MEF23.1].";\r
+  }\r
+  \r
+  typedef service-list-type {\r
+    type string {\r
+      length "0..255";\r
+      pattern "\d*([,:]\d*)?";\r
+    }\r
+    description     \r
+     "An octet string containing a list of item values.\r
+      \r
+      An item value is an arbitrary string of octets from\r
+      ASCII character 0x30 - 0x39, but may not contain \r
+      a delimiter character. Delimiter characters are \r
+      defined to be one of the following:\r
+      \r
+          -  An ASCII comma character (0x2C)\r
+          -  An ASCII colon character (0x3A)\r
+      \r
+      Delimiter characters are used to separate item values\r
+      in a item list.  Only a single delimiter character may\r
+      occur between two item values.  A item value may not\r
+      have a zero length.  These constraints imply certain\r
+      restrictions on the contents of this object:\r
+      \r
+          - There cannot be a leading or trailing delimiter\r
+            character.\r
+      \r
+          - There cannot be multiple adjacent delimiter\r
+            characters.\r
+      \r
+      The 'comma' delimiter separates individual items or a\r
+      sequence of items. The 'colon' delimiter indicates a range\r
+      of items from the first item before the colon through the\r
+      last item after the colon. Individual ranges in the same\r
+      item list need to be separated by a 'comma'.\r
+      \r
+      Some examples of valid item lists are:\r
+      \r
+          - ''            -- an empty list\r
+          - '1234'        -- list of one item\r
+          - '10,11,12'    -- list of several items\r
+          - '10:20'       -- a list containing all the valid values from\r
+                             10 through 20\r
+      \r
+      Note that although an item value may not have a length of\r
+      zero, an empty string is still valid.  This indicates\r
+      an empty list (i.e. there are no tag values in the list).\r
+      \r
+      The use of the item list is to select one or more items at\r
+      one time with a single object instead of having separate row\r
+      entries in a table for each individual item.";\r
+  }\r
+  \r
+  \r
+  typedef service-preservation-type {\r
+    type enumeration {\r
+      enum preserve   { \r
+               description "The type of service is preserved, either CE-VLAN ID or \r
+                       CE-VLAN CoS as indicated by the specific object";\r
+               }\r
+      enum noPreserve { \r
+               description "The type of service is not preserved, either CE-VLAN ID\r
+                       or CE-VLAN CoS as indicated by the specific object.";\r
+               }\r
+    }\r
+    description     \r
+     "Configures the EVC preservation attributes.";\r
+    reference       \r
+     "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";\r
+  }\r
+\r
+  typedef service-delivery-type {\r
+    type enumeration {\r
+      enum discard { \r
+       description "Service Frames are discarded";\r
+       }\r
+      enum unconditional { \r
+       description "Service Frames are unconditionally delivered no matter the \r
+               content of the Service Frame. An example of this is a \r
+               Point-to-Point EVC";\r
+       }\r
+      enum conditional { \r
+       description "Service Frame are conditionally delivered to the \r
+               destination UNI. The condition is specified, for example via a\r
+               bandwidth profile or unicast MAC address learning.";\r
+       }\r
+    }\r
+    description    \r
+     "A MEF service can have one of three different delivery types.";\r
+    reference       \r
+     "[MEF 6.1] 6.0";\r
+  }\r
+\r
+  \r
+  typedef identifier45 {\r
+    type string {\r
+      length "min..45";\r
+    }\r
+    description\r
+      "This type definition accepts any visible ASCII character " +\r
+      "plus the <space> character.The string must be RFC 2579 " +\r
+      "Display " +\r
+      "String but not contain the characters 0.00 through 0.1f " +\r
+      "It does not accept the <delete> character despite the " +\r
+      "current MEF specification.";\r
+    reference "MEF 10.3 [R8], [R9]";\r
+  }\r
+}
\ No newline at end of file
diff --git a/edgeassure-1000/src/main/yang/msea-uni-evc-interface@2016-03-17.yang b/edgeassure-1000/src/main/yang/msea-uni-evc-interface@2016-03-17.yang
new file mode 100644 (file)
index 0000000..6bf80fd
--- /dev/null
@@ -0,0 +1,1034 @@
+module msea-uni-evc-interface {
+
+       namespace "http://www.microsemi.com/microsemi-edge-assure/msea-uni-evc-interface";
+       prefix "msea-if"; //MicroSemi EdgeAssure (msea)
+
+       import ietf-yang-types {
+               prefix yang;
+               revision-date 2013-07-15;
+       }
+       
+       import msea-types {
+               prefix msea;
+               revision-date 2016-02-29;
+       }
+       
+       import ietf-interfaces { 
+               prefix "if";
+       }
+
+       import iana-if-type { 
+               prefix "ianaift"; 
+       }
+
+       organization
+       "Microsemi Inc., FTD Division";
+
+       contact
+       "Web URL: http://www.microsemi.com/
+       E-mail: info@microsemi.com
+       Postal: Microsemi Corporation Corporate Headquarters
+       One Enterprise Aliso Viejo,
+       CA 92656
+       U.S.A.
+       Phone: +1 949 380 6100
+       Fax: +1 949 215-4996";
+
+
+       description
+       "This YANG module is based on the MEF 40 SNMP model, for the management 
+       objects for the management of User Network Interfaces (UNIs). 
+       It has been converted to YANG and modified slightly to suit the 
+       EdgeAssure SFP which has some extra constraints that are not handled by 
+       the original model
+
+       Copyright 2016 Microsemi Inc.
+       All rights reserved.";
+
+       reference
+       "***************************************************************************
+       Reference Overview
+
+       A number of base documents have been used to create this MIB. The following
+       are the abbreviations for the baseline documents:
+       [MEF 40] refers to SNMP MIB
+       [MEF6.1] refers to MEF 6.1 'Ethernet Services Definitions - Phase 2',
+       April 2008
+       [MEF 6.1.1] refers to MEF 6.1.1 'Layer 2 Control Protocol Handling Amendment
+       to MEF 6.1', January 2012
+       [MEF 7.2] refers to MEF 7.2 'Carrier Ethernet Management Information Model',
+       January 2013
+       [MEF 10.2] refers to MEF 10.2 'Ethernet Services Attributes Phase 2',
+       October 2009
+       [MEF 26.1] refers to MEF 26.1 'External Network Network Interface (ENNI) -
+       Phase 2', January 2012
+       [Q.840.1] refers to 'ITU-T Requirements and analysis for NMS-EMS
+       management interface of Ethernet over Transport and Metro Ethernet
+       Network (EoT/MEN)', March 2007
+       ****************************************************************************";
+
+       revision "2016-03-17" {
+               description
+               "Initial Version. Sean Condon - Microsemi";
+               reference "MEF 6.2";
+       }
+
+
+  typedef MefServiceInterfaceType {
+    type bits {
+//      bit bUni1d1;
+//      bit bUni1d2;
+      bit bUni2d1 {description "Only bUni2d1 is supported by EdgeAssure 1000";}
+//      bit bUni2d2;
+//      bit bEnni;
+//      bit bEnniVuni;
+    }
+    
+    default "bUni2d1";
+    description     
+     "A MEF Interface can be one of several types:
+      
+      bUni1d1    UNI Type 1.1 See MEF 13. Non-multiplexed UNI for services such as EPL,
+      bUni1d2    UNI Type 1.2 See MEF 13. Multiplexed UNI for services such as EVPL, 
+      bUni2d1    UNI Type 2.1 See MEF 20 section 7
+      bUni2d2    UNI Type 2.2 See MEF 20 section 7
+      bEnni      ENNI
+      bEnniVuni  VUNI on an ENNI";
+    reference       
+     "[MEF 6.1] 6.0";
+  }
+
+  typedef l2cp-dest-mac-address {
+      type string {
+          pattern '01-80-[cC]2-(00-){2}[02][0-9a-fA-F]|01:80:[cC]2:(00:){2}[02][0-9a-fA-F]';
+      }
+      description
+         "The L2CP Destination MAC address for CoS 
+                       Identifier type of 'l2cp' and is ignored for other types.
+       
+                       Valid values are 01-80-C2-00-00-00 through 01-80-C2-00-00-0F and
+                       01-80-C2-00-00-20 through 01-80-C2-00-00-2F
+                       
+                       Values can be upper or lower case and can be separated by hyphen or colon (but not both)";
+  }
+  
+
+  
+       typedef l2cp-destination-address {
+               type enumeration {
+                       enum destinationAddressOnly {
+                               description "L2CP selection is determined by
+                               MAC Destination Address only";
+                       }
+               
+//                                             enum daPlusProtocol {
+//                                                     description "L2CP selection is determined by
+//                                                             MAC Destination Address plus
+//                                                             Ethernet protocol";
+//                                             }
+//                                             
+//                                             enum daPlusProtocolPlusSubtype {
+//                                                     description "L2CP selection is determined by
+//                                                     MAC Destination Address plus
+//                                                     Ethernet protocol plus subtype";
+//                                             }
+               }               
+       }
+       
+/*** OBJECT DEFINITIONS ***/
+  //
+  // Augments ietf-interfaces (only of type ethernetCsmacd) with MEF Services
+  //
+  augment "/if:interfaces/if:interface" {
+      when "if:type='ianaift:ethernetCsmacd' and (if:name='eth0' or if:name='eth1')";
+      
+      leaf frame-format { //aka mefServiceInterfaceCfgFrameFormat
+        type enumeration {
+          enum noTag    { 
+                 description "Indicates that all data on the interface 
+                               is regarded as untagged, regardless of it ingress type"; }
+          enum ctag     { 
+                 description "Ingress frames with CTAG(vlan>0) will be 
+                         regared as 'VLAN tagged'; with CTAG(vlan=0) as Priority; otherwise untagged";
+          }
+          enum stag     { 
+                 description "Ingress frames with STAG(vlan>0) will be 
+                         regared as 'VLAN tagged'; with STAG(vlan=0) as Priority; otherwise untagged";
+                 }
+//          enum stagCtag { description "Indicates that service traffic identified 
+//                             with both an S-TAG (outer tag) and a C-TAG 
+//                             (inner tag)"; }
+        }
+           //default noTag; --These defaults break the validation - not using them in Eagle
+        description 
+         "This object indicates the interface frame format type that the
+          interface can recognize.";
+        reference   
+         "[MEF 6.1] 6.0";
+      }
+
+      leaf interface-ingress-bwp-group-index { //aka mefServiceInterfaceCfgIngressBwpGrpIndex
+        type leafref {
+          path "/if:interfaces/msea-if:interface-profiles/msea-if:interface-bwp-group/msea-if:group-index";
+        }
+        description 
+         "This object is the index number of the ingress bandwidth profile group
+          associated with the current interface. A value of 0 indicates that no
+          interface ingress bandwidth profile group is associated with the 
+          interface.
+          
+          This index indicates the specific bandwidth profile group previously 
+          configured via mefServiceBwpGrpCfgTable and mefServiceBwpCfgTable 
+          using this value for mefServiceBwpGrpCfgIndex. There may be multiple 
+          entries in mefServiceBwpCfgTable using this index, each containing
+          bandwidth parameters for a different Class of Service Identifier.";
+        reference   
+         "[MEF 6.1] 6.0; [MEF 7.2] 6.2.1.2";
+      }
+      
+         leaf ce-vid-untagged { //aka mefServiceUniCfgCeVidUntagged
+               type msea:vlan-id-type;
+       
+               description
+               "Configures the CE VLAN ID associated with untagged and priority
+               Service Frames. It allows the identification of untagged and
+               priority tagged traffic with a specific CE-VLAN ID. This object
+               is ignored for all to one bundling at the UNI.
+               This attribute has been placed on the interface (rather than the UNI)
+               as it can be defined regardless of whether a UNI exists or not";
+               reference
+               "[MEF 6.1] 6.0, [MEF 7.2] 6.2.1.2";
+         }
+       
+         leaf ce-priority-untagged { //aka mefServiceUniCfgCePriorityUntagged
+               type msea:priority-type;
+       
+               description
+               "Configures the CE VLAN Priority associated with untagged Service
+               Frames. It allows the assignment of a specific VLAN priority to
+               untagged traffic. This object is ignored for all to one bundling
+               at the UNI.
+               This attribute has been placed on the interface (rather than the UNI)
+               as it can be defined regardless of whether a UNI exists or not";
+               reference
+               "[MEF 7.2] 6.2.1.2";
+         }
+
+      leaf admittance-criteria {
+         type enumeration {
+                       enum admitAll { description "Admit all frames";}
+                       enum admitPrioUntaggedOnly { description "Admit only frames that are not Priority tagged";}
+                       enum admitVlanOnly { description "Admit only frames that are VLAN tagged";}
+         }
+         
+//       default admitAll; 
+         
+         description "Criteria for admitting packets to this interface. 
+                         The Frame Format attribute to determintes how frames are tagged";
+      }
+      
+    } //End augment "/if:interfaces/if:interface
+
+
+  augment "/if:interfaces-state/if:interface" {
+
+      leaf max-vc { //aka mefServiceInterfaceStatusMaxVc
+        type uint32 {
+          range "1..4095";
+        }
+        description 
+         "This object indicates the maximum number of virtual channels that the
+          interface can support. A virtual connection can be an Ethernet Virtual 
+          Connection (EVC) or an Operator Virtual Connection (OVC) depending upon
+          the type of interface that is selected.  ";
+        reference   
+         "[MEF 6.1] 6.0; [MEF 7.2] 6.2.1.2";
+      }
+
+      leaf max-end-point-per-vc { //aka mefServiceInterfaceStatusMaxEndPointPerVc
+        type uint32 {
+          range "1..10";
+        }
+        description 
+         "This object indicates the interface maximum number of end points per
+          virtual channel. It can be used to indicate the maximum number of OVC
+          end points per OVC. It has no current applicability for EVCs. ";
+        reference   
+         "[MEF 26.1]";
+      }
+    } //End augment "/if:interfaces-state/if:interface"
+
+
+  augment "/if:interfaces-state/if:interface/if:statistics" {
+
+      leaf ingress-undersized { //aka mefServiceInterfaceStatisticsIngressUndersized
+        type yang:counter32;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each frame received
+          on a NE interface that was smaller than 64 octets.
+          
+          This object defaults to '0'. ";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf ingress-oversized { //aka mefServiceInterfaceStatisticsIngressOversized
+        type yang:counter32;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each frame received
+          on a NE interface that was larger than the maximum MTU size.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf ingress-fragments { //aka mefServiceInterfaceStatisticsIngressFragments
+        type yang:counter32;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each frame received
+          on a NE interface that was less than 64 octets in length
+          (excluding framing bits but including FCS octets) and had 
+          either a bad Frame Check Sequence (FCS) with an integral 
+          number of octets (FCS Error) or a bad FCS with a non-integral
+          number of octets (Alignment Error).
+          
+          Note that it is entirely normal for this counter to
+          increment.  This is because it counts both runts (which are
+          normal occurrences due to collisions) and noise hits.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf ingress-crc-alignment { //aka mefServiceInterfaceStatisticsIngressCrcAlignment
+        type yang:counter32;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each frame received
+          on a NE interface that was from 64 octets to the maximum MTU
+          size in length, but had either a bad Frame Check Sequence (FCS)
+          with an integral number of octets (FCS Error) or a bad FCS with
+          a non-integral number of octets (Alignment Error).
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf ingress-invalid-vid { //aka mefServiceInterfaceStatisticsIngressInvalidVid
+        type yang:counter32;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each frame received
+          on a NE interface with an invalid VLAN ID.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf ingress-octets { //aka mefServiceInterfaceStatisticsIngressOctets
+        type yang:counter64;
+        units "octets";
+        description 
+         "This object is incremented by the number of octets in a
+          valid frame received on a NE interface.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf ingress-unicast { //aka mefServiceInterfaceStatisticsIngressUnicast
+        type yang:counter64;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each valid unicast frame received
+          on a NE interface.
+          
+          NEs that do not support 64 bit counters can return the
+          upper half of the counter as all zeros.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf ingress-multicast { //aka mefServiceInterfaceStatisticsIngressMulticast
+        type yang:counter64;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each valid multicast frame received
+          on a NE interface.
+          
+          ME-NEs that do not support 64 bit counters can return the
+          upper half of the counter as all zeros.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf ingress-broadcast { //aka mefServiceInterfaceStatisticsIngressBroadcast
+        type yang:counter64;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each valid broadcast frame received
+          on a NE interface.
+          
+          ME-NEs that do not support 64 bit counters can return the
+          upper half of the counter as all zeros.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf egress-octets { //aka mefServiceInterfaceStatisticsEgressOctets
+        type yang:counter64;
+        units "octets";
+        description 
+         "This object is incremented by the number of octets in a frame 
+          transmitted on a NE interface.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf egress-unicast { //aka mefServiceInterfaceStatisticsEgressUnicast
+        type yang:counter64;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each unicast frame transmitted on a
+          NE interface.
+          
+          ME-NEs that do not support 64 bit counters can return the
+          upper half of the counter as all zeros.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf egress-multicast { //aka mefServiceInterfaceStatisticsEgressMulticast
+        type yang:counter64;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each multicast frame transmitted on a
+          NE interface.
+          
+          ME-NEs that do not support 64 bit counters can return the
+          upper half of the counter as all zeros.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+
+      leaf egress-broadcast { //aka mefServiceInterfaceStatisticsEgressBroadcast
+        type yang:counter64;
+        units "Ethernet frames";
+        description 
+         "This object is incremented for each broadcast frame transmitted on a
+          NE interface.
+          
+          ME-NEs that do not support 64 bit counters can return the
+          upper half of the counter as all zeros.
+          
+          This object defaults to '0'.";
+        reference   
+         "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+      }
+    } //End augment "/if:interfaces-state/if:interface/if:statistics
+  
+  
+  augment "/if:interfaces-state" {
+         leaf mef-service-type-options { //aka mefServiceInterfaceStatusType
+               type MefServiceInterfaceType;
+               description 
+                "This object is a vector of bits that indicates the possible
+                 interface types that an interface can be configured to. An interface,
+                 for instance, can be configured to be a UNI type 1 or 2, or an ENNI.
+                 
+                 All the possible capabilities of an interface are indicated, one bit
+                 per possible type. At least one bit must be set for MEF compliant NEs.";
+               reference   
+                "[MEF 6.1] 6.0";
+         }
+  } //End augment "/if:interfaces-state
+
+  
+  
+  augment "/if:interfaces" {
+      leaf l2cp-group-index { //aka mefServiceInterfaceCfgL2cpGrpIndex
+        type leafref {
+          path "/if:interfaces/msea-if:interface-profiles/msea-if:l2cp-group/msea-if:group-index";
+        }
+        description 
+         "This object is the index of the L2CP profile group
+          (mefServiceL2cpGrpCfgIndex) associated with the current interface. A 
+          value of 0 indicates that no interface L2CP profile group is associated
+          with the interface. The L2CP group must be the same for both interfaces";
+        reference   
+         "[MEF 6.1] 6.0; [MEF 6.1.1] 8.0; [MEF 7.2] 6.2.1.2";
+        
+//        must "count(//if:interfaces/if:interface[msea-if:l2cp-group-index = current()]) = 2" {
+//               error-app-tag "msea-if-must-01";
+//               error-message "The same L2CP Group must be used on both interfaces of this device";
+//          }
+      }
+
+      leaf mef-service-type { //aka mefServiceInterfaceCfgType
+        type MefServiceInterfaceType;
+        description 
+         "This object indicates the configured interface type. One
+          bit in the vector can be set at one time based upon the
+          possible values indicated by mefServiceInterfaceStatusType.";
+           //default bUni1d1; --These defaults break the validation - not using them in Eagle
+        reference   
+         "[MEF 6.1] 6.0; [MEF 7.2] 6.2.1.1, 6.2.1.2, 6.2.1.3";
+      }
+      
+      
+       container interface-profiles {
+
+               list interface-bwp-group { //aka mefServiceBwpGrpCfgEntry
+
+                       key "group-index";
+                       max-elements 64;
+                       description
+                       "Bandwidth profile group settings table entry.";
+
+                       leaf group-index { //aka mefServiceBwpGrpCfgIndex
+                               type uint8;
+                               description
+                               "Bandwidth profile group index number";
+                       }
+
+                       list interface-bwp { //aka mefServiceBwpCfgEntry
+                               key "cos-index";//Changed to cos-index (from bwp-index) based on MEP 40 6.4.2 
+                               unique name;
+                               max-elements 64;
+                               
+                               description
+                               "Bandwidth profile. This maps 1:1 with a COS instance. This object is 
+                               maintained here to keep the traditional layout of BWPGroup-BWP-COS, but does 
+                               not have any other purpose in the current implementation";
+
+                               leaf cos-index { //aka mefServiceBwpCfgCosIndex
+                                       type leafref {
+                                               path "/if:interfaces/msea-if:interface-profiles/msea-if:interface-cos/msea-if:cos-index";
+                                       }
+                                       description
+                                       "This object is the index number of the CoS ID profile
+                                       associated with the current bandwidth profile. A value of 0 indicates
+                                       that no CoS ID profile is associated with the bandwidth profile and the
+                                       bandwidth profile applies to all CoS IDs.
+
+                                       This index indicates a specific CoS ID profile previously configured via
+                                       mefServiceCosCfgTable as indicated by the mefServiceCosCfgIndex object.";
+                                       reference
+                                       "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+                                       
+                                       must "current()/../../msea-if:group-index > 0" {
+                                               error-app-tag "msea-if-must-02";
+                                               error-message "No BWP's can be added to the Bandwidth Profile Group 0, as this index represents a special case";
+                                       }
+                               }
+
+                               leaf name { //mefServiceBwpCfgIdentifier
+                                       type string {
+                                               length "1..45";
+                                       }
+                                       mandatory true;
+                                       description
+                                       "This object indicates the bandwidth profile identifier for the
+                                       associated bandwidth profile index and is an arbitrary
+                                       text string that is used to identify a bandwidth profile. Unique
+                                       string values are chosen to uniquely identify the bandwidth
+                                       profile.
+
+                                       Octet values of 0x00 through 0x1f are illegal.
+
+                                       MEF 26.1 restricts the maximum size identifiers to 45 octets.";
+                                       reference
+                                       "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+                               }
+// The attributes of BWP Group are not made visible here as they are not used in the device
+//                             leaf committed-information-rate { //aka mefServiceBwpCfgCir
+//                                     type uint32 {
+//                                             range "0..10000000";
+//                                     }
+//                                     units "kbits/s";
+//                                     default 1000000;
+//                                     msea:not-changeable;
+//                                     
+//                                     description
+//                                     "This object indicates the Committed Information Rate (CIR) in kbits/s
+//                                     and defines the average rate in kbits/sec up to which
+//                                     the network delivers Service Frames. Service Frames that meet
+//                                     the CIR are said to be in profile or in conformance to performance
+//                                     objectives. These frames are generally identified as 'Green' 
+//                                     Service Frames.";
+//                                     reference
+//                                     "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+//                             }
+//
+//                             leaf committed-burst-size { //aka mefServiceBwpCfgCbs
+//                                     type uint32 {
+//                                             range "0..10000000";
+//                                     }
+//                                     units "bytes";
+//                                     default 12;
+//                                     msea:not-changeable;
+//
+//                                     description
+//                                     "This object indicates the Committed Burst Size (CBS) in bytes. It limits
+//                                     the maximum number of bytes available for a burst of Service Frames sent
+//                                     at interface speed to remain CIR-conformant.";
+//                                     reference
+//                                     "[MEF 10.2]";
+//                             }
+//
+//                             leaf excess-information-rate { //aka mefServiceBwpCfgEir
+//                                     type uint32 {
+//                                             range "0..10000000";
+//                                     }
+//                                     units "kbits/s";
+//                                     msea:not-changeable;
+//
+//                                     description
+//                                     "This object indicates the Excess Information Rate (EIR) in kbits/s
+//                                     and defines the average rate in kbits/sec of Service Frames up to
+//                                     which the network may deliver Service Frames but without performance
+//                                     objectives. Service Frames that meet the EIR as set to be in out-of-
+//                                     profile or not in conformance to performance objectives. These
+//                                     frames are not guaranteed to be delivered and are generally identified
+//                                     as 'Yellow' service frames.";
+//                                     reference
+//                                     "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+//                             }
+//
+//                             leaf excess-burst-size { //aka mefServiceBwpCfgEbs
+//                                     type uint32 {
+//                                             range "0..10000000";
+//                                     }
+//                                     units "bytes";
+//                                     msea:not-changeable;
+//
+//                                     description
+//                                     "This object indicates the Excess Burst Size (EBS) in bytes. It limits
+//                                     the maximum number of bytes available for a burst of Service Frames
+//                                     sent at the interface speed to remain EIR-conformant.";
+//                                     reference
+//                                     "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+//                             }
+//
+//                             leaf color-mode { //aka mefServiceBwpCfgCm
+//                                     type enumeration {
+//                                             enum colorBlind {description "A bandwidth profile property where ingress 
+//                                                     Service Frames are not pre-colored for either
+//                                                     green or yellow, and if present, is ignored when
+//                                                     determining the level of compliance for each
+//                                                     Service Frame";
+//                                             }
+//                                             
+//                                             enum colorAware {
+//                                                     description "A bandwidth profile property were a pre-determined
+//                                                     level of Bandwidth Profile compliance for each
+//                                                     Service Frame is taken into account when determining
+//                                                     the level of compliance for each Service Frame.
+//                                                     Each service frame can be colored red (discarded),
+//                                                     yellow (conditional delivery), or green (unconditional
+//                                                     delivery.";
+//                                             }
+//                                     }
+//                                     default colorBlind;
+//                                     msea:not-changeable;
+//
+//                                     description
+//                                     "This object configures the bandwidth profile color mode.";
+//
+//                                     reference
+//                                     "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+//                             }
+//
+//                             leaf coupling-flag { //aka mefServiceBwpCfgCf
+//                                     type enumeration {
+//                                             enum couplingYellowEirOnly {
+//                                                     description "The long term average bit rate of Service
+//                                                     Frames that are declared Yellow is bounded by EIR."; 
+//                                             }
+//
+//                                             enum couplingYellowEirPlusCir {
+//                                                     description "The long term average bit rate of Service
+//                                                     Frames that are declared Yellow is bounded
+//                                                     by CIR + EIR depending on the volume of
+//                                                     the offered Service Frames that are
+//                                                     declared Green.";
+//                                             }
+//                                     }
+//                                     
+//                                     default couplingYellowEirOnly;
+//                                     msea:not-changeable;
+//
+//                                     description
+//                                     "This object configures the bandwidth profile coupling flag and has
+//                                     the effect of controlling the volume of the Service Frames that are
+//                                     declared Yellow.";
+//
+//                                     reference
+//                                     "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+//                             }
+//
+//                             container performance { //aka mefServicePerformanceEntry
+//                                     config false;
+//                                     description
+//                                     "Traffic Performance Data Set profile settings table entry.";
+//
+//                                     leaf ingress-green-frames { //aka mefServicePerformanceIngressGreenFrameCount
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//
+//                                             description
+//                                             "This object indicates the number of green frames that were 
+//                                             received on a ME-NE for the associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-yellow-frames { //aka mefServicePerformanceIngressYellowFrameCount
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//
+//                                             description
+//                                             "This object indicates the number of yellow frames that were 
+//                                             received on the ME-NE for the associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-red-frames { //aka mefServicePerformanceIngressRedFrameCount
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//                                             description
+//                                             "This object indicates the number of red frames that were 
+//                                             received on the ME-NE for the associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//
+//                                     leaf ingress-green-frame-discards { //aka mefServicePerformanceIngressGreenFrameDiscards
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//                                             description
+//                                             "This object indicates the number of green frames that were 
+//                                             discarded due to congestion within the ME-NE for the
+//                                             associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-yellow-frame-discards { //aka mefServicePerformanceIngressYellowFrameDiscards
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//                                             description
+//                                             "This object indicates the number of yellow frames that were 
+//                                             discarded due to congestion within the ME-NE for the
+//                                             associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-octets-discards {
+//                                             type yang:counter64;
+//                                             units "octets";
+//                                             description
+//                                             "This object indicates the number of valid octets of any colour 
+//                                             that were discarded due to congestion within the ME-NE for the
+//                                             associated bandwidth profile.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//                                     
+//                             } //End performance
+
+                       } //End bwp
+
+               } //End bwp-group
+               
+               list interface-cos { //aka mefServiceCosCfgEntry
+                       key "cos-index";
+                       unique name;
+                       max-elements 64;
+                       description
+                       "Class of Service Identifier settings table entry.";
+
+                       leaf cos-index { //aka mefServiceCosCfgIndex
+                               type uint32 {
+                                       range 1..max;
+                               }
+                               description
+                               "Class of Service Identifier profile index number.";
+                       }
+
+                       leaf name { //aka mefServiceCosCfgIdentifier
+                               type string {
+                                       length 1..45;
+                               }
+                               
+                               description
+                               "This object indicates the Class of Service Name for the
+                               associated CoS profile index and is an arbitrary text string that is
+                               used to identify a CoS ID profile. Unique string values are chosen to
+                               uniquely identify the profile.
+
+                               Octet values of 0x00 through 0x1f are illegal.
+
+                               MEF 26.1 restricts the maximum size identifiers to 45 octets.";
+                               reference
+                               "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+                       }
+                       
+                       container dscp-cos-type {
+                               description "Indicates that the CoS profile is associated
+                               with the incoming frame's DSCP field if it is an IP frame. 
+                               If it is not an IP frame no action is taken on it";
+                               
+                               choice dscp-id-choice {
+                                       case dscp-bits-list {
+                                               leaf dscp-group-bit-list {
+                                                       type bits {
+                                                               bit dscp-0-7 {
+                                                                       description "The set of DSCP identifiers from 0-7";
+                                                               }
+                                                               bit dscp-8-15 {
+                                                                       description "The set of DSCP identifiers from 8-15";
+                                                               }
+                                                               bit dscp-16-23 {
+                                                                       description "The set of DSCP identifiers from 16-23";
+                                                               }
+                                                               bit dscp-24-31 {
+                                                                       description "The set of DSCP identifiers from 24-31";
+                                                               }
+                                                               bit dscp-32-39 {
+                                                                       description "The set of DSCP identifiers from 32-39";
+                                                               }
+                                                               bit dscp-40-47 {
+                                                                       description "The set of DSCP identifiers from 40-47";
+                                                               }
+                                                               bit dscp-48-55 {
+                                                                       description "The set of DSCP identifiers from 48-55";
+                                                               }
+                                                               bit dscp-56-63 {
+                                                                       description "The set of DSCP identifiers from 56-63";
+                                                               }
+                                                       }
+                                               }
+                                       }
+
+                                       case dscp-0-63 {
+                                               container dscp-0-63 {
+                                                       presence "The full set of DSCP identifiers from 0-63";
+                                               }
+                                       }
+
+                                       case specific-values {
+                                               leaf-list dscp-id {
+                                                       type uint16 {
+                                                               range 0..64;
+                                                       }
+                                                       ordered-by system;
+                                                       description "The set of DSCP identifiers handled by this COS";
+                                               }
+                                       }
+                                       mandatory true;
+                                       msea:not-changeable;
+                               }
+                               
+                               choice color-specification {
+                                       case all-green {
+                                               container color-all-green {
+                                                       presence "Color for all specified DSCPs mapped to green";
+                                               }
+                                       }
+                                       case all-yellow {
+                                               container color-all-yellow {
+                                                       presence "Color for all specified DSCPs mapped to yellow";
+                                               }
+                                       }
+                                       case all-dropped {
+                                               container color-all-dropped {
+                                                       presence "Color for all specified DSCPs mapped to dropped";
+                                               }
+                                       }
+                                       
+                                       case dscp-to-color-map {
+                                               list dscp-color {
+                                                       key dscp-id;
+                                                       ordered-by system;
+                                                       description "A list of DSCP values that apply to this COS.
+                                                       When the COS type is DSCP a subset of the values can 
+                                                       be specified. Other DSCP values can be specified in 
+                                                       additional COS profiles. In total the same priority
+                                                       cannot be repeated in a BWP Group";
+               
+                                                       leaf dscp-id {
+                                                               type uint16 {
+                                                                       range 0..64;
+                                                               }
+                                                       }
+                                                       
+                                                       leaf color {
+                                                               description "Color to apply to incoming IP frames
+                                                               with this DSCP id";
+                                                               
+                                                               type msea:cos-color-type;
+                                                       }
+                                               }
+                                       }
+                                       default all-green;
+                                       msea:not-changeable;
+                               }
+                       }
+                       
+                       leaf outgoing-cos-value {
+                         type msea:priority-type;
+                         mandatory true;
+                         msea:not-changeable;
+
+                     description
+                       "Used to set the egress COS to use for all ingress COS explicitly listed";
+                     reference   
+                                "Edge Assure internal API";
+                   }
+               }
+
+               
+               list l2cp-group { //aka mefServiceL2cpGrpCfgEntry
+                       key "group-index";
+                       max-elements 64;
+                       description
+                       "L2CP profile group settings table entry on an interface.";
+
+                       leaf group-index { //aka mefServiceL2cpGrpCfgIndex
+                               type uint32;
+                               description
+                               "L2CP profile group index number, indicating the specific L2CP profile 
+                               group";
+                       }
+
+                       list l2cp { //aka mefServiceL2cpCfgEntry
+                               key "index";
+                               max-elements 64;
+                               description
+                               "L2CP settings table entry on an interface or a service.";
+
+                               leaf index { //aka mefServiceL2cpCfgIndex
+                                       type uint32;
+                                       description
+                                       "This object configures the L2CP index number on an interface or a 
+                                       Service and is used to create/access a L2CP profile within a L2CP
+                                       group.";
+
+                                       must "current()/../../msea-if:group-index > 0" {
+                                               error-app-tag "msea-if-must-03";
+                                               error-message "No L2CP's can be added to the L2CP Group 0, as this index represents a special case";
+                                       }
+                               }
+
+                               leaf handling { //aka mefServiceL2cpCfgType
+                                       type enumeration {
+                                               enum discard {description "The indicated L2CP is discarded";}
+                                               
+                                               enum tunnel {description "The indicated L2CP is tunneled (passed)";}
+                                               
+                                               enum peer {description "The indicated L2CP is peered with the NE";}
+                                               
+//                                             enum passToEvc {description "the indicated L2CP is passed to the EVC for
+//                                                     EVC processing of the L2CP. Final L2CP
+//                                                     disposition is based the L2CP profile for
+//                                                     the EVC to be tunneled, discarded, or peered.
+//                                                     This value is not valid for EVC based L2CP";
+//                                             }
+                                       }
+                                       default tunnel;
+                                       msea:not-changeable;
+                                       
+                                       description
+                                       "This object configures the handling of matching L2CP frames.";
+                                       reference
+                                       "[MEF 6.1] 6.0, 8.0; [MEF 6.1.1] 8.0; [MEF 7.2] 6.2.1.2";
+                               }
+
+                               leaf match-scope { //aka mefServiceL2cpCfgMatchScope
+                                       type l2cp-destination-address;
+                                       default destinationAddressOnly;
+                                       msea:not-changeable;
+                                       
+                                       description
+                                       "This object configures the L2CP selection matching scope.";
+                                       reference
+                                       "[MEF 6.1] 6.0, 8.0; [MEF 6.1.1] 8.0; [MEF 7.2] 6.2.1.2";
+                                       
+                               }
+
+                               leaf mac-address { //aka mefServiceL2cpCfgMacAddress
+                                       type l2cp-dest-mac-address;
+                                       mandatory true;
+                                       msea:not-changeable;
+                                       
+                                       description
+                                       "This object configures the L2CP Destination MAC address.
+
+                                       Valid values are 01-80-C2-00-00-00 through 01-80-C2-00-00-0F and
+                                       01-80-C2-00-00-20 through 01-80-C2-00-00-2F";
+
+                                       must "count(current()/../../msea-if:l2cp[msea-if:mac-address = current()]) <= 1" {
+                                               error-app-tag "msea-if-must-04";
+                                               error-message "A destination address can only appear once in an L2CP Group";
+                                       }
+                               }
+                       } //End l2cp
+
+               } //End l2cp-group
+
+               
+       } //End profiles
+  } //end augment interfaces
+  
+} /* end of module msea-uni-evc-interface */
diff --git a/edgeassure-1000/src/main/yang/msea-uni-evc-service@2016-03-17.yang b/edgeassure-1000/src/main/yang/msea-uni-evc-service@2016-03-17.yang
new file mode 100644 (file)
index 0000000..3fe4a12
--- /dev/null
@@ -0,0 +1,1572 @@
+module msea-uni-evc-service {
+
+       namespace "http://www.microsemi.com/microsemi-edge-assure/msea-uni-evc-service";
+       prefix "msea-svcs"; //MicroSemi EdgeAssure (msea)
+
+
+       import msea-types {
+               prefix msea;
+               revision-date 2016-02-29;
+       }
+
+//     import ietf-interfaces { prefix if; }
+//     import mef-uni-evc-interface { prefix mef-interface; }
+       import ENTITY-STATE-TC-MIB {prefix "entity-state";}
+
+       /*** META INFORMATION ***/
+
+       organization
+       "Microsemi Inc., FTD Division";
+
+       contact
+       "Web URL: http://www.microsemi.com/
+       E-mail: info@microsemi.com
+       Postal: Microsemi Corporation Corporate Headquarters
+       One Enterprise Aliso Viejo,
+       CA 92656
+       U.S.A.
+       Phone: +1 949 380 6100
+       Fax: +1 949 215-4996";
+
+       description
+       "This YANG module is based on the MEF 40 SNMP model, for the management 
+       objects for the management of User Network Interfaces (UNIs) and Ethernet
+       Virtual Connections (EVCs). It has been converted to YANG and modified
+       slightly to suit the EdgeAssure SFP which has some extra
+       constraints that are not handled by the original model
+
+       Copyright 2016 Microsemi Inc.
+       All rights reserved.";
+
+       reference
+       "***************************************************************************
+       Reference Overview
+
+       A number of base documents have been used to create this MIB. The following
+       are the abbreviations for the baseline documents:
+       [MEF 40] refers to SNMP MIB
+       [MEF6.1] refers to MEF 6.1 'Ethernet Services Definitions - Phase 2',
+       April 2008
+       [MEF 6.1.1] refers to MEF 6.1.1 'Layer 2 Control Protocol Handling Amendment
+       to MEF 6.1', January 2012
+       [MEF 7.2] refers to MEF 7.2 'Carrier Ethernet Management Information Model',
+       January 2013
+       [MEF 10.2] refers to MEF 10.2 'Ethernet Services Attributes Phase 2',
+       October 2009
+       [MEF 26.1] refers to MEF 26.1 'External Network Network Interface (ENNI) -
+       Phase 2', January 2012
+       [Q.840.1] refers to 'ITU-T Requirements and analysis for NMS-EMS
+       management interface of Ethernet over Transport and Metro Ethernet
+       Network (EoT/MEN)', March 2007
+       ****************************************************************************";
+
+       revision "2016-03-17" {
+               description
+               "Initial Version. Sean Condon - Microsemi";
+               reference "MEF 6.2";
+       }
+
+       
+
+    
+    grouping uni-attributes {
+       
+       description "Common UNI attributes";
+
+               leaf bundling-multiplex { //aka mefServiceUniCfgBundlingMultiplex
+                       type enumeration {
+                               enum allToOne {
+                                       description 
+                                       "All to One Bundling, used for Private services: 
+                                               EPL, EP-LAN, and EP-Tree";
+                               }
+                               
+                               enum bundling {
+                                       description 
+                                               "Bundling, indicates one or more 
+                                               CE-VLANS per service, used for virtual private CE-VLAN
+                                               preservation services: EVPL, EVP-LAN, EVP-Tree";
+                               }
+                                               
+                               enum multiplex {
+                                       description 
+                                               "Service Multiplexing, indicates 
+                                               one or more EVCs per UNI, used for virtual private
+                                               CE-VLAN preservation or non-preservation services:
+                                               EVPL, EVP-LAN, EVP-Tree";
+                               }
+                               
+                               enum bundlingMultiplex {
+                                       description 
+                                       "Service Multiplexing plus 
+                                       Bundling, indicates one or more EVCs per UNI that are
+                                       composed of one or more CE-VLANs, used for virtual
+                                       CE-VLAN preservation services: EVPL, EVP-LAN, EVP-Tree";
+                               }
+                       }
+                       
+                       default allToOne;
+                       msea:not-changeable;
+
+                       description
+                               "Configures bundling and multiplexing options for the UNI. This object
+                               is an enumerated list of possible multiplexing and bundling options
+                               on a UNI that is unambiguous and provides only the legal possibilities.";
+
+                       reference
+                               "[MEF 6.1] 6.0, [MEF 7.2] 6.2.1.2";
+               }
+
+    }
+    
+       
+       grouping evc-per-uni-extension-attributes {
+               description "EVC attributes that are configured depending on
+                               the UNI side.";
+
+               leaf ce-vlan-map { //aka mefServiceEvcPerUniCfgCeVlanMap
+                       type msea:service-list-type;
+                       
+                       mandatory true;
+                       description
+                       "This object indicates the CE-VLANs associated with the specific
+                       EVC on a UNI. CE-VLAN IDs have value of 0 to 4095. The CE-VLAN ID
+                       list can be a single value or multiple values separated by a delimiter.
+       
+                       Some valid values are: '100', '1:10', '10,20,30', '1:4095'. In the
+                       first example only CE-VLAN ID 100 is associated with the VLAN map.
+                       In the second example the CE-VLAN map includes CE-VLAN IDs 1 through
+                       10 (range of values). The third example indicates three separate values
+                       that make up the CE-VLAN map. The last example indicates all CE-VLAN IDs
+                       are included in the map (range of values). ";
+                       reference
+                       "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+               }
+
+               
+               leaf ingress-bwp-group-index { //aka mefServiceEvcPerUniCfgIngressBwpGrpIndex
+                       type leafref {
+                               path "/msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group/msea-svcs:group-index";
+                       }
+                       
+                       mandatory true;
+       
+                       description
+                       "This object is the index number of the ingress bandwidth profile group
+                       associated with the current EVC on a UNI. A value of 0 indicates that
+                       no ingress bandwidth profile group is associated with the EVC on a UNI.
+       
+                       This index indicates the specific bandwidth profile group previously
+                       configured via mefServiceBwpGrpCfgTable and mefServiceBwpCfgTable
+                       using this value for mefServiceBwpGrpCfgIndex. There may be multiple
+                       entries in mefServiceBwpCfgTable using this index, each containing
+                       bandwidth parameters for a different Class of Service Identifier.";
+                       reference
+                       "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+               }
+               
+
+        choice tag-manipulation {
+          description "Tag Action to take for an EVC. 
+                         If no case is specified then the default noAction will apply";
+          //case noAction - if not specified then noAction will be taken
+          case tagPop {
+               container tag-pop {
+                       description "Pop the tag.";
+                       presence "Tag pop.";
+               }
+          }
+          
+          case tagPush {
+               container tag-push {
+                       description "Push the tag.";
+                       
+                       leaf push-tag-type { //Microsemi Eagle specific configuration attribute
+                               type enumeration {
+                                 enum pushCtag  { description "Use Ctag type on push"; }
+                                 enum pushStag    { description "Use Stag type on push"; }
+                               }
+                               default pushCtag;
+
+                               description 
+                                 "Specify what tag type should be used is if tagAction is 'push'.";
+                               reference   
+                                "Edge Assure internal API";
+                       }
+                       
+                       leaf outer-tag-vlan { //Microsemi Eagle specific configuration attribute
+                               type msea:vlan-id-type;
+                               mandatory true;
+                               description 
+                                 "The VLan value to use as the outer tag's vlan.";
+                               reference   
+                                "Edge Assure internal API";
+                       }
+               }
+          }
+          
+          case tagOverwrite {
+                 container tag-overwrite {
+                         description "Overwrite the tag";
+                         
+                               leaf outer-tag-vlan { //Microsemi Eagle specific configuration attribute
+                                       type msea:vlan-id-type;
+                                       mandatory true;
+                                       description 
+                                         "The VLan value to use as the outer tag's vlan.";
+                                       reference   
+                                        "Edge Assure internal API";
+                               }
+                 }
+          }
+               }
+        
+               leaf evc-per-uni-service-type { //aka mefServiceEvcPerUniCfgServiceType
+                       type enumeration {
+                               enum epl {
+                                       description "Ethernet Private Line Service (EPL)
+                                       Point-to-Point EVC, all to one bundling";
+                               }
+                               
+                               enum evpl {
+                                       description "Ethernet Virtual Private Line (EVPL)
+                                       Point-to-Point EVC, bundling and/or multiplexing";
+                               }
+                               
+                               enum eplan {
+                                       description "Ethernet Private LAN Service (EP-LAN)
+                                       Multipoint-to-Multipoint EVC, all to one bundling";
+                               }
+                               
+                               enum evplan {
+                                       description "Ethernet Virtual Private LAN Service (EVP-LAN)
+                                       Multipoint-to-Multipoint EVC, bundling and/or multiplexing"; 
+                               }
+                               
+                               enum eptree {
+                                       description "Ethernet Private Tree Service (EP-Tree)
+                                       Rooted-Multipoint EVC, all to one bundling";
+                               }
+                               
+                               enum evptree {
+                                       description "Ethernet Virtual Private Tree Service (EVP-Tree)
+                                       Rooted-Multipoint EVC, bundling and/or multiplexing";
+                               }
+                       }
+                       config false;
+                               
+                       description
+                       "This object indicates the specific Ethernet service type. The value is 
+                       derived from the EVC object 'mefServiceEvcCfgType' and the UNI object
+                       'mefServiceUniCfgBundlingMultiplex'.";
+       
+                       reference
+                       "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+               }
+       }
+       
+       
+       grouping pcp-color-map-grouping {
+               description "The PCP identifiers for the COS";
+               leaf pcp-id {
+                       description "The priority level";
+                       type msea:priority-type;
+               }
+               
+               leaf pcp-color {
+                       description "The color to apply to this Priority";
+                       type msea:cos-color-type;
+                       msea:not-changeable;
+               }
+       }
+       
+       container mef-services {
+               description
+               "This acts as a container of the MEF (6.2) Services configuration.";
+
+               container uni {
+//                     must "count(/if:interfaces/if:interface/[mef-interface:mef-service-type = 'bUni2d1']) = 2" {
+//                             error-message "The interfaces must be configured as a UNI";
+//                             error-app-tag "msea-uni-must-01";
+//                     } //Unenforceable as the interface resides in a different module - may have to be implemented in the TransAPI
+
+                       presence "If present this device acts as a UNI";
+
+                       description "This Edge Assure device support only one UNI.
+                               This device supports only one UNI even though it has two interfaces. 
+                               One of the interfaces corresponds to the UNI-N side of the UNI, 
+                               while the other interface corresponds to the UNI-C side of the interface.
+                               Each side performs the mapping to and from the EVC on the ingress
+                               of packets to the device.";
+
+                       
+                       leaf name { //aka mefServiceUniCfgIdentifier
+                               type msea:identifier45;
+                               mandatory true;
+                               description
+                               "This object indicates the UNI identifier. This is distinct from 
+                               the mefServiceInterfaceCfgIdentifier and allows the naming of the
+                               UNI separately from the Interface name. The identifier is
+                               an arbitrary text string that is used to identify an interface.
+                               Unique string values are chosen to uniquely identify the UNI.
+
+                               This object is used to add an identifier to a service interface. The
+                               mefServiceInterfaceCfgIdentifier can be used to add a separate
+                               identifier that is associated with the physical interface name.
+
+                               Octet values of 0x00 through 0x1f are illegal.
+
+                               MEF 26.1 restricts the maximum size identifiers to 45 octets.";
+                               reference
+                               "[MEF 6.1] 6.0, [MEF 7.2] 6.2.1.2";
+                       }
+                       
+                       leaf uni-side-interface-assignment {
+                               type enumeration {
+                                       enum uni-c-on-host {
+                                               description "Uni-C (Customer) is the Host/eth1/LAN  - commonly the System port. 
+                                                       Uni-N (Network) is the Optics/eth0/WAN - commonly the Carrier port";
+                                       }
+                                       enum uni-c-on-optics {
+                                               description "Uni-C (Customer) is the Optics/eth0/WAN - commonly the Carrier port.
+                                                       Uni-N (Network) is the Host/eth1/LAN  - commonly the System port";
+                                       }
+                               }
+                               
+                               default uni-c-on-host;
+                               msea:not-changeable;
+
+
+                               description "An attribute to configure the assignment of UNI-C (Customer) and 
+                                               UNI-N (Network) to the interfaces.
+                                               This Edge Assure supports only one UNI over its two interfaces. 
+                                               One of the interfaces corresponds to the UNI-N side of the UNI, 
+                                               while the other interface corresponds to the UNI-C side of the interface.
+                                               Each side acts on packets only on ingress at each interface";
+                       }
+                       
+                       container uni-c { //aka mefServiceUniCfgEntry
+                               presence "If present this configures the UNI-C";
+
+                               uses uni-attributes;
+                               
+                               must "//msea-svcs:mef-services/msea-svcs:uni/msea-svcs:uni-n" {
+                                       error-app-tag "msea-svcs-must-00";
+                                       error-message "Both UNI-C and UNI-N must be specified";
+                               }
+
+                               description "The configuration of the UNI-C side of the UNI.
+                                               UNI-C refers to eth1 by default but can be changed through the 
+                                               uni-side-interface-assignment attribute.
+                                               The interface used must have been configured as a UNI";
+                       }
+
+                       container uni-n { //aka mefServiceUniCfgEntry
+                               presence "If present this configures the UNI-N";
+
+                               uses uni-attributes;
+
+                               must "//msea-svcs:mef-services/msea-svcs:uni/msea-svcs:uni-c" {
+                                       error-app-tag "msea-svcs-must-01";
+                                       error-message "Both UNI-C and UNI-N must be specified";
+                               }
+
+                               description "The configuration of the UNI-C side of the UNI.
+                                               UNI-N refers to eth0 by default but can be changed through the 
+                                               uni-side-interface-assignment attribute.
+                                               The interface used must have been configured as a UNI";
+                       }
+
+                       list evc { //aka mefServiceEvcPerUniCfgEntry
+                               key evc-index;
+                               max-elements 32;
+                               description "The UNI can support one or more EVCs";
+                               
+                               
+                               leaf evc-index { //aka mefServiceEvcCfgIndex
+                                       type uint32 {
+                                               range 1..max;
+                                       }
+                                       description
+                                       "The specific instance of an EVC number.";
+                               }
+               
+                               leaf name { //aka mefServiceEvcCfgIdentifier
+                                       type msea:identifier45;
+                                       mandatory true;
+                                       
+                                       description
+                                       "This object indicates the EVC identifier. The identifier is
+                                       an arbitrary text string that is used to identify an EVC.
+                                       Unique string values are chosen to uniquely identify the EVC.
+               
+                                       Octet values of 0x00 through 0x1f are illegal.
+               
+                                       MEF 26.1 restricts the maximum size identifiers to 45 octets.";
+                                       reference
+                                       "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+                               }
+
+                               
+                               leaf uni-evc-id { //aka mefServiceEvcCfgIdentifier
+                                       type msea:identifier45;
+                                       config false;
+                                       description
+                                       "The UNI EVC ID is a string formed by the concatenation of 
+                                       the UNI ID (Section 9.1) and the EVC ID (Section 8.2) that
+                                       is used to identify an EVC at the UNI. It is intended for 
+                                       management and control purposes.";
+                                       reference
+                                       "[MEF 10.3] 10.1";
+                               }
+                               
+                               leaf service-type { //aka mefServiceEvcCfgServiceType
+                                       type enumeration {
+                                               enum pointToPoint {
+                                                       description "EVC Point-to-Point service,
+                                                       used for EPL and EVPL services"; 
+                                               }
+                                               
+                                               enum multipointToMultipoint {
+                                                       description "EVC Multipoint-to-Multipoint 
+                                                       Service, used for EP-LAN and EVP-LAN
+                                                       services"; 
+                                               }
+                                               
+                                               enum rootedMultipoint {
+                                                       description "EVC Rooted-Multipoint Service,
+                                                       used for EP-Tree and EVP-Tree services"; 
+                                               }
+                                               
+                                       }
+                                       default pointToPoint;
+                                       msea:not-changeable;
+
+                                       description
+                                       "This object configures the EVC service type for the ME-NE.";
+
+                                       reference
+                                       "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+                               }
+
+                               leaf mtu-size { //aka mefServiceEvcCfgMtuSize
+                                       type uint32 {
+                                               range "9600";
+                                       }
+                                       units "octets";
+                                       default 9600;
+                                       description
+                                       "This object indicates the configured EVC maximum service frame format
+                                       size. It must be less than or equal to the
+                                       mefServiceEvcStatusMaxMtuSize.";
+                                       reference
+                                       "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+                               }
+
+                               leaf cevlan-id-preservation { //aka mefServiceEvcCfgCevlanIdPreservation
+                                       type msea:service-preservation-type;
+                                       default preserve;
+                                       msea:not-changeable;
+                                       
+                                       description
+                                       "This object configures the EVC CE-VLAN ID preservation.
+
+                                       preserve(1) The CE-VLAN ID is preserved. The ingress CE-VLAN
+                                       is the CE-VLAN ID at the egress UNI
+                                       noPreserve(2) The CE-VLAN ID is not preserved. The ingress
+                                       CE-VLAN ID may not be the CE-VLAN ID at the egress
+                                       UNI";
+                                       reference
+                                       "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+                               }
+
+                               leaf cevlan-cos-preservation { //aka mefServiceEvcCfgCevlanCosPreservation
+                                       type msea:service-preservation-type;
+                                       default preserve;
+                                       msea:not-changeable;
+
+                                       description
+                                       "This object configures EVC CE-VLAN CoS preservation.
+
+                                       preserve(1) The CE-VLAN CoS is preserved. The ingress CE-VLAN
+                                       CoS is the CE-VLAN CoS at the egress UNI
+                                       noPreserve(2) The CE-VLAN CoS is not preserved. The ingress
+                                       CE-VLAN CoS may not be the CE-VLAN CoS at the
+                                       egress UNI";
+                                       reference
+                                       "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+                               }
+
+               //                      No effect on per EVC with this device
+               //                      leaf unicast-delivery { //aka mefServiceEvcCfgUnicastDelivery
+               //                              type msea:service-delivery-type;
+               //                              default unconditional;
+               //                              description
+               //                              "This object configures EVC Unicast delivery condition.";
+               //                              reference
+               //                              "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+               //                      }
+               //
+               //                      No effect on per EVC with this device
+               //                      leaf multicast-delivery { //aka mefServiceEvcCfgMulticastDelivery 
+               //                              type msea:service-delivery-type;
+               //                              default unconditional;
+               //                              description
+               //                              "This object configures EVC Multicast delivery condition.";
+               //                              reference
+               //                              "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+               //                      }
+               //
+               //                      No effect on per EVC with this device
+               //                      leaf broadcast-delivery { //aka mefServiceEvcCfgBroadcastDelivery
+               //                              type msea:service-delivery-type;
+               //                              default unconditional;
+               //                              description
+               //                              "This object configures EVC Broadcast delivery condition.";
+               //                              reference
+               //                              "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+               //                      }
+               //
+               //                      No effect on per EVC with this device
+               //                      leaf l2cp-group-index { //aka mefServiceEvcCfgL2cpGrpIndex
+               //                              type leafref {
+               //                                      path "/msea-svcs:mef-services/msea-svcs:l2cp-group/msea-svcs:group-index";
+               //                              }
+               //                              description
+               //                              "This object is the index of the L2CP profile group
+               //                              (mefServiceL2cpGrpCfgIndex) associated with the current EVC on an
+               //                              interface. A value of 0 indicates that no EVC L2CP profile group is
+               //                              associated with the EVC.
+               //
+               //                              This index indicates the L2CP profile group previously configured via
+               //                              the mefServiceL2cpGrpCfgTable and mefServiceL2cpCfgTable using the value
+               //                              of the mefServiceL2cpGrpCfgIndex. There may be multiple entries in
+               //                              mefServiceL2cpCfgTable using this index, each containing
+               //                              parameters for a different L2CP protocol.";
+               //                              reference
+               //                              "[MEF 6.1] 6.1; [MEF 6.1.1] 8.0; [MEF 7.2] 6.2.1.3";
+               //                      }
+               //                      
+               //                      No effect on per EVC with this device
+               //                      leaf admin-state { //aka mefServiceEvcCfgAdminState
+               //                              type entity-state:EntityAdminState;
+               //                              default unlocked;
+               //                              description
+               //                              "This object specifies the administrative state of the EVC.
+               //
+               //                              If mefServiceEvcCfgAdminState is set to 'locked', the EVC will be
+               //                              administratively locked.
+               //
+               //                              If mefServiceEvcCfgAdminState is set to 'unlocked', the EVC will be
+               //                              administratively unlocked if previously locked.
+               //
+               //                              Other values of mefServiceEvcCfgAdminState are undefined.";
+               //                              reference
+               //                              "[MEF 7.2] 6.2.1.3";
+               //                      }
+
+                               container evc-status { //aka mefServiceEvcStatusEntry
+                                       config false;
+                                       description
+                                       "The conceptual row of mefServiceEvcStatusTable.";
+
+                                       leaf max-mtu-size { //aka mefServiceEvcStatusMaxMtuSize
+                                               type uint32 {
+                                                       range "1522..16384";
+                                               }
+                                               units "octets";
+                                               description
+                                               "This object indicates the EVC maximum configurable service
+                                               frame format size. The actual configured size is set via the
+                                               mefServiceEvcCfgMtuSize object.";
+                                               reference
+                                               "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+                                       }
+
+                                       leaf max-num-uni { //aka mefServiceEvcStatusMaxNumUni
+                                               type uint32 {
+                                                       range "2..16384";
+                                               }
+                                               description
+                                               "This object indicates the maximum number of UNIs in an EVC. For
+                                               a Point-to-Point EVC this value is '2'. For a Multipoint EVC the
+                                               value can be '2' or greater.";
+                                               reference
+                                               "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+                                       }
+
+                                       leaf operational-state { //aka mefServiceEvcStatusOperationalState
+                                               type entity-state:EntityOperState;
+                                               description
+                                               "This object indicates the operational state (current
+                                               capability) of the EVC.
+
+                                               If the value is 'enabled', the EVC is able to ingress and
+                                               egress service frames and has been set to active.
+
+                                               If the value is 'disabled' the EVC is not able to ingress and
+                                               egress service frames, has detected an operational failure
+                                               condition, or has failed an internal test.
+
+                                               If the value is 'testing' the EVC has been placed into a test mode,
+                                               either a troubleshooting mode or a test mode.
+
+                                               If the value is 'unknown' the EVC is unable to report the operational
+                                               state.";
+                                               reference
+                                               "[MEF 7.2] 6.2.1.3";
+                                       }
+                               } //End evc-status
+
+               //                      list evc-uni { //aka mefServiceEvcUniCfgEntry
+
+               //                              key "if-index";
+               //                              description
+               //                              "The conceptual row of mefServiceEvcUniCfgTable.";
+               //
+               //                              leaf if-index {
+               //                                      type leafref {
+               //                                              path "/if:interfaces/if:interface/if:name";
+               //                                      }
+               //                                      description
+               //                                      "Automagically generated keyref leaf.";
+               //                              }
+                               container evc-per-uni {
+                                       leaf evc-uni-type { //aka mefServiceEvcUniCfgType
+                                               type enumeration {
+                                                       enum root {
+                                                               description "Valid setting for all service types. A UNI set
+                                                               to this value may send frames to UNIs configured
+                                                               as 'root' or 'leaf'";
+                                                       }
+                                               }                                               
+               //                                              enum leaf {
+               //                                                      description "Valid setting for Root-Multipoint EVCs only. A
+               //                                                      UNI set to this value may send frames to UNIs
+               //                                                      'root'";
+               //                                              }
+               //                                              
+               //                                              enum unknown {
+               //                                                      description "UNI port is not configured or illegally
+               //                                                      configured. This value cannot be written, but
+               //                                                      is only returned when the type is unknown."; 
+               //                                              }
+               //                                      }                                               
+                                               default root;
+                                               description
+                                               "This object configures UNI type on an EVC.";
+                                               reference
+                                               "[MEF 10.2]";
+       
+                                       }
+                                       
+                                       container evc-per-uni-c { //aka mefServiceUniCfgEntry
+       
+                                               description "The configuration of the UNI-C side of the EVC-per-UNI.";
+                                               
+                                               uses evc-per-uni-extension-attributes;
+                                                       
+                                       } //End evc-per-uni-c
+                                       
+                                       
+                                       container evc-per-uni-n { //aka mefServiceUniCfgEntry
+       
+                                               description "The configuration of the UNI-N side of the EVC-per-UNI";
+                       
+                                               uses evc-per-uni-extension-attributes;
+                                                       
+                                       } //End evc-per-uni-n
+                               }
+                       } //End evc
+               } //end of uni
+               
+               
+       container profiles {
+
+               list bwp-group { //aka mefServiceBwpGrpCfgEntry
+
+                       key "group-index";
+                       max-elements 64;
+                       description
+                       "Bandwidth profile group settings table entry.";
+
+                       leaf group-index { //aka mefServiceBwpGrpCfgIndex
+                               type uint8;
+                               description
+                               "Bandwidth profile group index number";
+                       }
+
+                       list bwp { //aka mefServiceBwpCfgEntry
+                               key "cos-index";//Changed to cos-index (from bwp-index) based on MEP 40 6.4.2 
+                               unique name;
+                               max-elements 64;
+                               
+                               description
+                               "Bandwidth profile settings table entry.";
+
+                               leaf cos-index { //aka mefServiceBwpCfgCosIndex
+                                       type leafref {
+                                               path "/msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos/msea-svcs:cos-index";
+                                       }
+                                       description
+                                       "This object is the index number of the CoS ID profile
+                                       associated with the current bandwidth profile. A value of 0 indicates
+                                       that no CoS ID profile is associated with the bandwidth profile and the
+                                       bandwidth profile applies to all CoS IDs.
+
+                                       This index indicates a specific CoS ID profile previously configured via
+                                       mefServiceCosCfgTable as indicated by the mefServiceCosCfgIndex object.";
+                                       reference
+                                       "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+                                       
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:*/priority[.='0']) <= 1" {
+                                               error-app-tag "msea-svcs-must-02";
+                                               error-message "Priority 0 can be specified only once in the COS's related to a BWP Group";
+                                       }
+
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:*/priority[.='1']) <= 1" {
+                                               error-app-tag "msea-svcs-must-03";
+                                               error-message "Priority 1 can be specified only once in the COS's related to a BWP Group";
+                                       }
+
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:*/priority[.='2']) <= 1" {
+                                               error-app-tag "msea-svcs-must-04";
+                                               error-message "Priority 2 can be specified only once in the COS's related to a BWP Group";
+                                       }
+
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:*/priority[.='3']) <= 1" {
+                                               error-app-tag "msea-svcs-must-05";
+                                               error-message "Priority 3 can be specified only once in the COS's related to a BWP Group";
+                                       }
+
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:*/priority[.='4']) <= 1" {
+                                               error-app-tag "msea-svcs-must-06";
+                                               error-message "Priority 4 can be specified only once in the COS's related to a BWP Group";
+                                       }
+
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:*/priority[.='5']) <= 1" {
+                                               error-app-tag "msea-svcs-must-07";
+                                               error-message "Priority 5 can be specified only once in the COS's related to a BWP Group";
+                                       }
+
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:*/priority[.='6']) <= 1" {
+                                               error-app-tag "msea-svcs-must-08";
+                                               error-message "Priority 6 can be specified only once in the COS's related to a BWP Group";
+                                       }
+
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:*/priority[.='7']) <= 1" {
+                                               error-app-tag "msea-svcs-must-09";
+                                               error-message "Priority 7 can be specified only once in the COS's related to a BWP Group";
+                                       }
+
+                                       
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:evc-cos-type-all-8-prio-to-1-evc-color) <= 1" {
+                                               error-app-tag "msea-svcs-must-10";
+                                               error-message "Only one COS can be specified in a Bandwidth Profile Group when the cos-type is 'evc-cos-type-all-8-prio-to-1-evc-color' ";
+                                       }
+
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:evc-cos-type-all-8-prio-to-1-pcp-color) <= 1" {
+                                               error-app-tag "msea-svcs-must-11";
+                                               error-message "Only one COS can be specified in a Bandwidth Profile Group when the cos-type is 'evc-cos-type-all-8-prio-to-1-pcp-color' ";
+                                       }
+
+                                       must "count(//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:cos[msea-svcs:cos-index=//msea-svcs:mef-services/msea-svcs:profiles/msea-svcs:bwp-group[msea-svcs:group-index=current()/../../msea-svcs:group-index]/msea-svcs:bwp/msea-svcs:cos-index]/msea-svcs:evc-cos-type-all-8-prio-to-1-dei-color) <= 1" {
+                                               error-app-tag "msea-svcs-must-12";
+                                               error-message "Only one COS can be specified in a Bandwidth Profile Group when the cos-type is 'evc-cos-type-all-8-prio-to-1-dei-color' ";
+                                       }
+
+                                       must "current()/../../msea-svcs:group-index > 0" {
+                                               error-app-tag "msea-svcs-must-15";
+                                               error-message "No BWP's can be added to the Bandwidth Profile Group 0, as this index represents a special case";
+                                       }
+                               }
+
+                               leaf name { //mefServiceBwpCfgIdentifier
+                                       type string {
+                                               length "1..45";
+                                       }
+                                       mandatory true;
+                                       description
+                                       "This object indicates the bandwidth profile identifier for the
+                                       associated bandwidth profile index and is an arbitrary
+                                       text string that is used to identify a bandwidth profile. Unique
+                                       string values are chosen to uniquely identify the bandwidth
+                                       profile.
+
+                                       Octet values of 0x00 through 0x1f are illegal.
+
+                                       MEF 26.1 restricts the maximum size identifiers to 45 octets.";
+                                       reference
+                                       "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+                               }
+
+                               leaf committed-information-rate { //aka mefServiceBwpCfgCir
+                                       type uint32 {
+                                               range "0..10000000";
+                                       }
+                                       units "kbits/s";
+                                       default 1000000;
+                                       msea:not-changeable;
+                                       
+                                       description
+                                       "This object indicates the Committed Information Rate (CIR) in kbits/s
+                                       and defines the average rate in kbits/sec up to which
+                                       the network delivers Service Frames. Service Frames that meet
+                                       the CIR are said to be in profile or in conformance to performance
+                                       objectives. These frames are generally identified as 'Green' 
+                                       Service Frames.";
+                                       reference
+                                       "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+                               }
+
+                               leaf committed-burst-size { //aka mefServiceBwpCfgCbs
+                                       type uint32 {
+                                               range "0..10000000";
+                                       }
+                                       units "bytes";
+                                       default 12;
+                                       msea:not-changeable;
+
+                                       description
+                                       "This object indicates the Committed Burst Size (CBS) in bytes. It limits
+                                       the maximum number of bytes available for a burst of Service Frames sent
+                                       at interface speed to remain CIR-conformant.";
+                                       reference
+                                       "[MEF 10.2]";
+                               }
+
+                               leaf excess-information-rate { //aka mefServiceBwpCfgEir
+                                       type uint32 {
+                                               range "0..10000000";
+                                       }
+                                       units "kbits/s";
+                                       msea:not-changeable;
+
+                                       description
+                                       "This object indicates the Excess Information Rate (EIR) in kbits/s
+                                       and defines the average rate in kbits/sec of Service Frames up to
+                                       which the network may deliver Service Frames but without performance
+                                       objectives. Service Frames that meet the EIR as set to be in out-of-
+                                       profile or not in conformance to performance objectives. These
+                                       frames are not guaranteed to be delivered and are generally identified
+                                       as 'Yellow' service frames.";
+                                       reference
+                                       "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+                               }
+
+                               leaf excess-burst-size { //aka mefServiceBwpCfgEbs
+                                       type uint32 {
+                                               range "0..10000000";
+                                       }
+                                       units "bytes";
+                                       msea:not-changeable;
+
+                                       description
+                                       "This object indicates the Excess Burst Size (EBS) in bytes. It limits
+                                       the maximum number of bytes available for a burst of Service Frames
+                                       sent at the interface speed to remain EIR-conformant.";
+                                       reference
+                                       "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+                               }
+
+                               leaf color-mode { //aka mefServiceBwpCfgCm
+                                       type enumeration {
+                                               enum colorBlind {description "A bandwidth profile property where ingress 
+                                                       Service Frames are not pre-colored for either
+                                                       green or yellow, and if present, is ignored when
+                                                       determining the level of compliance for each
+                                                       Service Frame";
+                                               }
+                                               
+                                               enum colorAware {
+                                                       description "A bandwidth profile property were a pre-determined
+                                                       level of Bandwidth Profile compliance for each
+                                                       Service Frame is taken into account when determining
+                                                       the level of compliance for each Service Frame.
+                                                       Each service frame can be colored red (discarded),
+                                                       yellow (conditional delivery), or green (unconditional
+                                                       delivery.";
+                                               }
+                                       }
+                                       default colorBlind;
+                                       msea:not-changeable;
+
+                                       description
+                                       "This object configures the bandwidth profile color mode.";
+
+                                       reference
+                                       "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+                               }
+
+                               leaf coupling-flag { //aka mefServiceBwpCfgCf
+                                       type enumeration {
+                                               enum couplingYellowEirOnly {
+                                                       description "The long term average bit rate of Service
+                                                       Frames that are declared Yellow is bounded by EIR."; 
+                                               }
+
+                                               enum couplingYellowEirPlusCir {
+                                                       description "The long term average bit rate of Service
+                                                       Frames that are declared Yellow is bounded
+                                                       by CIR + EIR depending on the volume of
+                                                       the offered Service Frames that are
+                                                       declared Green.";
+                                               }
+                                       }
+                                       
+                                       default couplingYellowEirOnly;
+                                       msea:not-changeable;
+
+                                       description
+                                       "This object configures the bandwidth profile coupling flag and has
+                                       the effect of controlling the volume of the Service Frames that are
+                                       declared Yellow.";
+
+                                       reference
+                                       "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+                               }
+
+//                             leaf performance-enable { //aka mefServiceBwpCfgPerformanceEnable
+//                                     type enumeration {
+//                                             enum disablePerformanceDataSet {
+//                                                     description "A performance data set is enabled for this
+//                                                             bandwidth profile";
+//                                             }
+//                                             
+//                                             enum enablePerformanceDataSet {
+//                                                     description "A performance data set is not enabled for
+//                                                             this bandwidth profile";
+//                                             }
+//                                     }
+//                                     default disablePerformanceDataSet;
+//                                     
+//                                     description
+//                                     "This object indicates whether a performance data set is configured
+//                                     for a specific bandwidth profile. This allows for only specific
+//                                     bandwidth profiles to be monitored if there are limitations in the
+//                                     ME-NE being accessed.";
+//
+//                                     reference
+//                                     "[MEF 6.1] 6.1; [MEF 7.2] 6.2.1.3";
+//                             }
+//
+//                             container performance { //aka mefServicePerformanceEntry
+//                                     config false;
+//                                     description
+//                                     "Traffic Performance Data Set profile settings table entry.";
+//
+//                                     leaf ingress-green-frames { //aka mefServicePerformanceIngressGreenFrameCount
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//
+//                                             description
+//                                             "This object indicates the number of green frames that were 
+//                                             received on a ME-NE for the associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-yellow-frames { //aka mefServicePerformanceIngressYellowFrameCount
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//
+//                                             description
+//                                             "This object indicates the number of yellow frames that were 
+//                                             received on the ME-NE for the associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-red-frames { //aka mefServicePerformanceIngressRedFrameCount
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//                                             description
+//                                             "This object indicates the number of red frames that were 
+//                                             received on the ME-NE for the associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-green-octets { //aka mefServicePerformanceIngressGreenOctets
+//                                             type yang:counter64;
+//                                             units "octets";
+//                                             description
+//                                             "This object indicates the number of valid green octets 
+//                                             that were received on the ME-NE for the associated bandwidth
+//                                             profile.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-yellow-octets { //aka mefServicePerformanceIngressYellowOctets
+//                                             type yang:counter64;
+//                                             units "octets";
+//                                             description
+//                                             "This object indicates the number of valid yellow octets 
+//                                             that were received on the ME-NE for the associated bandwidth
+//                                             profile.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-red-octets { //aka mefServicePerformanceIngressRedOctets
+//                                             type yang:counter64;
+//                                             units "octets";
+//                                             description
+//                                             "This object indicates the number of valid red octets 
+//                                             that were received on the ME-NE for the associated bandwidth
+//                                             profile.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-green-frame-discards { //aka mefServicePerformanceIngressGreenFrameDiscards
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//                                             description
+//                                             "This object indicates the number of green frames that were 
+//                                             discarded due to congestion within the ME-NE for the
+//                                             associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-yellow-frame-discards { //aka mefServicePerformanceIngressYellowFrameDiscards
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//                                             description
+//                                             "This object indicates the number of yellow frames that were 
+//                                             discarded due to congestion within the ME-NE for the
+//                                             associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-octets-discards {
+//                                             type yang:counter64;
+//                                             units "octets";
+//                                             description
+//                                             "This object indicates the number of valid octets of any colour 
+//                                             that were discarded due to congestion within the ME-NE for the
+//                                             associated bandwidth profile.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//                                     
+//                                     leaf ingress-green-octets-discards { //aka mefServicePerformanceIngressGreenOctetsDiscards
+//                                             type yang:counter64;
+//                                             units "octets";
+//                                             description
+//                                             "This object indicates the number of valid green octets 
+//                                             that were discarded due to congestion within the ME-NE for the
+//                                             associated bandwidth profile.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf ingress-yellow-octets-discards { //aka mefServicePerformanceIngressYellowOctetsDiscards
+//                                             type yang:counter64;
+//                                             units "octets";
+//                                             description
+//                                             "This object indicates the number of valid yellow octets 
+//                                             that were discarded due to congestion within the ME-NE for the
+//                                             associated bandwidth profile.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+
+//                                     leaf egress-green-frames { //aka mefServicePerformanceEgressGreenFrameCount
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//                                             config false;
+//                                             description
+//                                             "This object indicates the number of green frames that were 
+//                                             transmitted on the ME-NE for the associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf egress-yellow-frames { //aka mefServicePerformanceEgressYellowFrameCount
+//                                             type yang:counter64;
+//                                             units "Ethernet frames";
+//                                             config false;
+//                                             description
+//                                             "This object indicates the number of yellow frames that were 
+//                                             transmitted on the ME-NE for the associated bandwidth profile.
+//
+//                                             ME-NEs that do not support 64 bit counters can return the
+//                                             upper half of the counter as all zeros.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf egress-green-octets { //aka mefServicePerformanceEgressGreenOctets
+//                                             type yang:counter64;
+//                                             units "octets";
+//                                             config false;
+//                                             description
+//                                             "This object indicates the number of valid green octets 
+//                                             that were transmitted on the ME-NE for the associated bandwidth
+//                                             profile.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//
+//                                     leaf egress-yellow-octets { //aka mefServicePerformanceEgressYellowOctets
+//                                             type yang:counter64;
+//                                             units "octets";
+//                                             config false;
+//                                             description
+//                                             "This object indicates the number of valid yellow octets 
+//                                             that were transmitted on the ME-NE for the associated bandwidth
+//                                             profile.
+//
+//                                             This object defaults to '0'. ";
+//                                             reference
+//                                             "[MEF 15] 8.2; [Q.840.1] 6.2.4";
+//                                     }
+//                             } //End performance
+
+                       } //End bwp
+
+               } //End bwp-group
+
+               list cos { //aka mefServiceCosCfgEntry
+                       key "cos-index";
+                       unique name;
+                       max-elements 64;
+                       description
+                       "Class of Service Identifier settings table entry.";
+
+                       leaf cos-index { //aka mefServiceCosCfgIndex
+                               type uint32 {
+                                       range 1..max;
+                               }
+                               description
+                               "Class of Service Identifier profile index number.";
+                       }
+
+                       leaf name { //aka mefServiceCosCfgIdentifier
+                               type string {
+                                       length 1..45;
+                               }
+                               
+                               description
+                               "This object indicates the Class of Service Name for the
+                               associated CoS profile index and is an arbitrary text string that is
+                               used to identify a CoS ID profile. Unique string values are chosen to
+                               uniquely identify the profile.
+
+                               Octet values of 0x00 through 0x1f are illegal.
+
+                               MEF 26.1 restricts the maximum size identifiers to 45 octets.";
+                               reference
+                               "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+                       }
+
+                       
+                       
+//                     leaf type { //aka mefServiceCosCfgType
+//                             type enumeration {
+//                                     enum interface {
+//                                             description "This value indicates that the CoS ID profile is associated
+//                                             with the interface, i.e. UNI or ENNI";
+//                                     }
+//                                     
+//                                     enum evc {
+//                                             description "This value indicates that the CoS ID profile is associated
+//                                                     with the virtual channel, i.e. EVC or OVC";
+//                                     }
+//                                     enum pcp {description "This value indicates that the CoS ID profile is associated
+//                                             with the outer tag's Priority Code Point (priority bits)";
+//                                     }
+//                             
+//                                     enum dscp {description "This value indicates that the CoS ID profile is associated
+//                                                     the IP's frames DSCP (priority) setting"; 
+//                                     }
+//                                     
+//                                     enum l2cp {description "This value indicates that the CoS ID profile is associated
+//                                                             a Layer 2 Control Protocol"; 
+//                                     }
+//                             }
+//                                     
+//                             default pcp;
+//                             description
+//                             "This object configures the CoS ID type and indicates the interpretation
+//                             of the mefServiceCosIdentifierList object.";
+//     
+//                             reference
+//                             "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+//                     }
+                       
+                       choice cos-type-choice {
+                               description "CoS configuration alternatives.";
+                               //We have 6 choices in a single tier choice structure which is easier for client
+                               //tools to represent automatically rather than a two tier choice structure
+                               
+                               case evc-cos-type-evc-color-id {
+                                       container evc-cos-type-all-8-prio-to-1-evc-color {
+                                               description "Indicates that the CoS profile is associated
+                                               with the virtual channel, i.e. EVC or OVC. All 8 priorities
+                                               are mapped to the outgoing-cos-value - therefore there can 
+                                               only be one of this type of COS specified in any BWP Group";
+                                                               
+                                               leaf evc-all-8-color-to {
+                                                       description "The color to be applied regardless of priority";
+                                                       mandatory true;
+                                                       type msea:cos-color-type;
+                                               }
+                                       }                                                       
+                               }
+                               
+                               case evc-cos-type-pcp-color-id {
+                               
+                                       container evc-cos-type-all-8-prio-to-1-pcp-color {
+                                               description "Indicates that the CoS profile is associated
+                                               with the virtual channel, i.e. EVC or OVC. All 8 priorities
+                                               are mapped to the outgoing-cos-value - therefore there can 
+                                               only be one of this type of COS specified in any BWP Group";
+
+                                               list pcp-color-per-prio {
+                                                       key pcp-id;
+                                                       description "The PCP value of the incoming frame is 
+                                                       used to lookup the following table to determine the 
+                                                       frame's color";
+
+                                                       min-elements 8;
+                                                       max-elements 8;
+                                                       uses pcp-color-map-grouping;
+                                               }
+                                       }
+                               }
+                                                       
+                               case evc-cos-type-dei-color-id {
+                                       container evc-cos-type-all-8-prio-to-1-dei-color {
+                                               presence "Cos type EVC and Color Mapping DEI";
+                                               
+                                               description "Indicates that the CoS profile is associated
+                                               with the virtual channel, i.e. EVC or OVC. All 8 priorities
+                                               are mapped to the outgoing-cos-value - therefore there can 
+                                               only be one of this type of COS specified in any BWP Group
+                                               The source of the color is DEI of the
+                                               incoming frame. False (0) in the DEI field will set 
+                                               the color to Green and True (1) will set to Yellow";
+
+                                       }
+                               }
+                                       
+                               case pcp-cos-type-evc-color-id {
+                                       container pcp-cos-type-n-prio-to-1-evc-color {
+                                               description "Indicates that the CoS profile is associated
+                                                       with the incoming frame's Priority Code Point (priority bits).";
+                                                       
+                                               leaf-list priority {
+                                                       type msea:priority-type;
+                                                       ordered-by system;
+                                                       
+                                                       description "A list of priorities that apply to this COS.
+                                                       When the COS type is PCP a subset of the priorities can 
+                                                       be specified. Other priorities can be specified in 
+                                                       additional COS profiles. In total the same priority
+                                                       cannot be repeated in a BWP Group";
+
+                                                       min-elements 1;
+                                                       max-elements 8;
+                                               }
+                                               
+                                               leaf evc-all-8-colors-to {
+                                                       description "The color to be applied regardless 
+                                                       of priority. If multiple instances of this cos
+                                                       type have different values then the color-type
+                                                       of the last one will apply";
+
+                                                       type msea:cos-color-type;
+                                                       mandatory true;
+                                               }
+                                       }
+                               }
+                                                       
+                               case pcp-cos-type-pcp-color-id {
+                                       container pcp-cos-type-n-prio-to-1-pcp-color {
+                                               description "Indicates that the CoS profile is associated
+                                                       with the incoming frame's Priority Code Point (priority bits). 
+                                                       The PCP value of the incoming frame is used to lookup the 
+                                                       follwing table to determine the frame's color";
+                                                       
+                                               leaf-list priority {
+                                                       type msea:priority-type;
+                                                       min-elements 1;
+                                                       max-elements 8;
+                                                       ordered-by system;
+
+                                                       description "A list of priorities that apply to this COS.
+                                                       When the COS type is PCP a subset of the priorities can 
+                                                       be specified. Other priorities can be specified in 
+                                                       additional COS profiles. In total the same priority
+                                                       cannot be repeated in a BWP Group";
+                                               }
+                                               
+                                               list pcp-color-for-prio {
+                                                       key pcp-id;
+                                                       description "Each priority specified above must
+                                                       have a corresponding color otherwise the default 
+                                                       (green) will apply";
+
+                                                       min-elements 1;
+                                                       ordered-by system;
+
+                                                       uses pcp-color-map-grouping {
+                                                               refine pcp-id {
+                                                                       must "count(current()/../../msea-svcs:priority[.=current()]) = 1" {
+                                                                               error-message "Each element must already exist in the priority list";
+                                                                       }
+                                                               }
+                                                       }
+                                               }
+                                       }
+                               }
+                                                       
+
+                               case pcp-cos-type-dei-color-id {
+                                       container pcp-cos-type-n-prio-to-1-dei-color {
+                                               description "Indicates that the CoS profile is associated
+                                                       with the incoming frame's Priority Code Point (priority bits). 
+                                                       The DEI value of the incoming frame is used to determine 
+                                                       the frame's color. False (0) in the DEI field of the frame 
+                                                       will set the color to Green and True (1) will set to Yellow";
+                                                       
+                                               leaf-list priority {
+                                                       type msea:priority-type;
+                                                       min-elements 1;
+                                                       max-elements 8;
+                                                       ordered-by system;
+                                                       
+                                                       description "A list of priorities that apply to this COS.
+                                                       When the COS type is PCP a subset of the priorities can 
+                                                       be specified. Other priorities can be specified in 
+                                                       additional COS profiles. In total the same priority
+                                                       cannot be repeated in a BWP Group";
+                                               }
+                                       }
+                               }
+                                       
+//                             case dscp {
+//                                     container cos-dscp {
+//                                             description "Indicates that the CoS ID profile is associated
+//                                                     the IP's frames DSCP (priority) setting.";
+//                                             
+//                                             list dscp-ids { //aka mefServiceCosCfgIdentifierList
+//                                                     key dscp-id;
+//                                                     description "The 6-bit DSCP value of the IP frame. Has a range of '0:63' for IPv4.";
+//                                                     leaf dscp-id {
+//                                                             type uint8 {
+//                                                                     range 0..63; //has a range of '0:63' for IPv4 and '0:16384' for IPv6
+//                                                             }
+//                                                     }
+//                                                     
+//                                                     leaf dscp-color {
+//                                                             description "The color to apply to this dscp-id";
+//                                                             type cos-color-type;
+//                                                     }
+//                                             }
+//                                     }
+//                             }
+//                                     
+//                             case l2cp {
+//                                     container cos-l2cp {
+//                                             description "This value indicates that the CoS ID profile is associated
+//                                                             a Layer 2 Control Protocol";
+//                                             
+//                                             leaf l2cp-type {
+//                                                     type l2cp-destination-address;
+//                                                     default destinationAddressOnly;
+//                                             }
+//                                                     
+//                                             leaf mac-address { //aka mefServiceCosCfgMacAddress
+//                                                     type l2cp-dest-mac-address;
+//                                                     
+//                                                     description
+//                                                     "This object configures the L2CP Destination MAC address for CoS 
+//                                                     Identifier type of 'l2cp' and is ignored for other types.
+//
+//                                                     Valid values are 01-80-C2-00-00-00 through 01-80-C2-00-00-0F and
+//                                                     01-80-C2-00-00-20 through 01-80-C2-00-00-2F";
+//                                             }
+//
+//                                             leaf protocol { //aka mefServiceCosCfgProtocol
+//                                                     type uint16;
+//
+//                                                     description
+//                                                     "This object configures the L2CP Ethernet protocol for CoS Identifier
+//                                                     type of 'l2cp' and is ignored for other types. It is also ignored if
+//                                                     mefServiceCosCfgIdentifierList has a value of '1'.
+//
+//                                                     The protocol is defined in the Ethertype field of the Ethertype
+//                                                     frame. For instance the Ethertype for Link OAM is 0x8809, for
+//                                                     E-LMI it is 0x88EE, for LLDP it is 0x88CC.
+//
+//                                                     Valid protocol values are defined by MEF 6.1 and MEF 6.1.1.";
+//                                                     reference
+//                                                     "[MEF 6.1] 6.0, 8.0; [MEF 6.1.1] 8.0; [MEF 7.2] 6.2.1.2";
+//                                             }
+//
+//                                             leaf sub-type { //aka mefServiceCosCfgSubType
+//                                                     type uint16;
+//
+//                                                     description
+//                                                     "This object configures the L2CP subtype protocol for CoS Identifier
+//                                                     type of 'l2cp' and is ignored for other types. It is also ignored if
+//                                                     mefServiceCosCfgIdentifierList has a value of '1' or '2'.
+//
+//                                                     For instance, the subtype for LACP is '2' and Link OAM is '3'.
+//
+//                                                     Valid subtype values are defined by MEF 6.1 and MEF 6.1.1.";
+//                                                     reference
+//                                                     "[MEF 6.1] 6.0, 8.0; [MEF 6.1.1] 8.0; [MEF 7.2] 6.2.1.2";
+//                                             }
+//                                     }
+//                             }
+                               
+                               mandatory true;
+                               msea:not-changeable;
+                       }
+
+//                     leaf identifier-list { //aka mefServiceCosCfgIdentifierList
+//                             type msea:service-list-type;
+//                             default "0:7";
+//                             
+//                             description
+//                             "This object indicates the list of CoS identifiers associated with
+//                             the specific CoS ID profile. Interpretation of the values in the list
+//                             are based upon the mefServiceCosCfgType object.
+//
+//                             For each of the mefServiceCosCfgType types valid range is:
+//
+//                             interface - the value of this object is ignored for the 'interface' type
+//                             vc - the value of this object is ignored for the 'vc' type 
+//                             pcp - the value of this object has a range of '0:7'
+//                             dscp - the value of this object has a range of '0:63' for IPv4 and '0:16384' for IPv6
+//                             l2cp - the value of this object indicates the matching criteria:
+//                                     '1' - destination MAC address only
+//                                     '2' - destination MAC address plus Ethernet protocol
+//                                     '3' - destination MAC address plus Ethernet protocol
+//                             plus subtype
+//
+//                             CoS identifier list can be a single value or multiple values separated
+//                             by a delimiter.
+//
+//                             Some valid values are: '1', '1:3', '1,3,5', '0:7'. In the first example
+//                             only one item, '1', is included in the CoS ID list. In the second example
+//                             values 1, 2, and 3 are included in the CoS ID list (range of values). In
+//                             the third example three individual values are included. In the fourth
+//                             example eight values are included: 0 through 7 (range of values).";
+//
+//                             reference
+//                             "[MEF 6.1] 6.0, 6.1, 6.2, 6.3; [MEF 7.2] 6.2.1.2, 6.2.1.3";
+//                     }
+
+
+                       
+                       //Microsemi Eagle specific configuration attribute
+//                 leaf color-map { 
+//                   type string {
+//                     length "0..32";
+//                     pattern "[0-2x:,']";
+//                   }
+//                   description
+//                     "Custom attribute for setting up COS color map. 
+//                     Each entry in this defines the color to be used for each
+//                             item of the identity list. 0 = green, 1 = yellow, x=no value
+//                             ',' to separate values, ':' to define a range of values,
+//                             ''n' to define a repeated value n times";
+//                   reference   
+//                              "Edge Assure internal API";
+//                 }
+                   
+                       leaf outgoing-cos-value {
+                         type msea:priority-type;
+                         mandatory true;
+                         msea:not-changeable;
+
+                     description
+                       "Used to set the egress COS to use for all ingress COS explicitly listed";
+                     reference   
+                                "Edge Assure internal API";
+                   }
+
+                       leaf color-aware {
+                         type boolean;
+                         default false;
+                         msea:not-changeable;
+
+                         description
+                           "Set if the profile should be treated as colour aware (true) or not (false)";
+                     reference   
+                                "Edge Assure internal API";
+                       }
+                       
+                       leaf color-forward {
+                         type boolean;
+                         default false;
+                         msea:not-changeable;
+
+                         description
+                           "Used to override the colour mapping of the profile. If true the ingress colour is forwarded";
+                     reference   
+                                "Edge Assure internal API";
+                       }
+
+               } //End cos
+               
+             
+    } //End of profiles
+
+       } //End of mef-services
+
+} /* end of module msea-uni-evc-service */
\ No newline at end of file
index 9022a59aebf8db0e35c11398dfd896085b5b0a0c..d90c354188e8d7855c5b8ccb7da0075634defa9d 100644 (file)
@@ -28,6 +28,7 @@ and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
     <dlux.version>0.4.0-SNAPSHOT</dlux.version>
     <ovsdb.version>1.3.0-SNAPSHOT</ovsdb.version>
     <mdsal.model.version>0.9.0-SNAPSHOT</mdsal.model.version>
+    <netconf.version>1.1.0-SNAPSHOT</netconf.version>
     <configfile.directory>etc/opendaylight/karaf</configfile.directory>
   </properties>
   <dependencyManagement>
@@ -47,6 +48,13 @@ and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
         <type>pom</type>
         <scope>import</scope>
       </dependency>
+      <dependency>
+        <groupId>org.opendaylight.netconf</groupId>
+        <artifactId>netconf-artifacts</artifactId>
+        <version>${netconf.version}</version>
+        <type>pom</type>
+        <scope>import</scope>
+      </dependency>
     </dependencies>
   </dependencyManagement>
   <dependencies>
@@ -70,7 +78,6 @@ and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
       <groupId>org.opendaylight.controller</groupId>
       <artifactId>features-mdsal</artifactId>
       <classifier>features</classifier>
-      <version>${mdsal.version}</version>
       <type>xml</type>
       <scope>runtime</scope>
     </dependency>
@@ -78,10 +85,21 @@ and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
       <groupId>org.opendaylight.netconf</groupId>
       <artifactId>features-restconf</artifactId>
       <classifier>features</classifier>
-      <version>${restconf.version}</version>
       <type>xml</type>
       <scope>runtime</scope>
     </dependency>
+    <dependency>
+      <groupId>org.opendaylight.netconf</groupId>
+      <artifactId>features-netconf</artifactId>
+      <type>xml</type>
+      <classifier>features</classifier>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.netconf</groupId>
+      <artifactId>features-netconf-connector</artifactId>
+      <type>xml</type>
+      <classifier>features</classifier>
+    </dependency>
     <dependency>
       <groupId>org.opendaylight.dlux</groupId>
       <artifactId>features-dlux</artifactId>
@@ -114,10 +132,33 @@ and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
       <artifactId>unimgr-api</artifactId>
       <version>${project.version}</version>
     </dependency>
-        <dependency>
+    <dependency>
       <groupId>${project.groupId}</groupId>
       <artifactId>unimgr-cli</artifactId>
       <version>${project.version}</version>
     </dependency>
+    <dependency>
+      <groupId>${project.groupId}</groupId>
+      <artifactId>unimgr-cisco-xr-driver</artifactId>
+      <version>${project.version}</version>
+    </dependency>
+    <dependency>
+      <groupId>${project.groupId}</groupId>
+      <artifactId>unimgr-cisco-xr-driver</artifactId>
+      <version>${project.version}</version>
+      <type>xml</type>
+      <classifier>config</classifier>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.unimgr</groupId>
+      <artifactId>cisco-xrmodels</artifactId>
+      <version>${project.version}</version>
+    </dependency>
+    <dependency>
+      <groupId>org.opendaylight.unimgr</groupId>
+      <artifactId>edgeassure-1000</artifactId>
+      <version>${project.version}</version>
+    </dependency>
   </dependencies>
+
 </project>
index b65d3a64fb5a14b710dce026b610bf39bed8c82a..c13815253c717a67584dbf08d741ed82fd4e8446 100755 (executable)
@@ -15,17 +15,22 @@ and is available at http://www.eclipse.org/legal/epl-v10.html
   <repository>mvn:org.opendaylight.netconf/features-restconf/{{VERSION}}/xml/features</repository>
   <repository>mvn:org.opendaylight.ovsdb/southbound-features/{{VERSION}}/xml/features</repository>
   <repository>mvn:org.opendaylight.dlux/features-dlux/{{VERSION}}/xml/features</repository>
+  <repository>mvn:org.opendaylight.netconf/features-netconf/{{VERSION}}/xml/features</repository>
+  <repository>mvn:org.opendaylight.netconf/features-netconf-connector/{{VERSION}}/xml/features</repository>
 
   <feature name='odl-unimgr-api' version='${project.version}' description='OpenDaylight :: UniMgr :: api'>
     <feature version='${mdsal.model.version}'>odl-mdsal-models</feature>
     <feature version='${ovsdb.version}'>odl-ovsdb-southbound-api</feature>
-    <bundle>mvn:org.opendaylight.unimgr/unimgr-api/${project.version}</bundle>
+    <bundle>mvn:org.opendaylight.unimgr/unimgr-api/{{VERSION}}</bundle>
   </feature>
 
   <feature name='odl-unimgr' version='${project.version}' description='OpenDaylight :: UniMgr'>
     <feature version='${mdsal.version}'>odl-mdsal-broker</feature>
     <feature version='${ovsdb.version}'>odl-ovsdb-southbound-impl</feature>
     <feature version='${project.version}'>odl-unimgr-api</feature>
+    <feature version='${netconf.version}'>odl-netconf-connector</feature>
+    <feature version='${netconf.version}'>odl-netconf-connector-ssh</feature>
+    <bundle>mvn:org.opendaylight.unimgr/edgeassure-1000/{{VERSION}}</bundle>
     <bundle>mvn:org.opendaylight.unimgr/unimgr-impl/{{VERSION}}</bundle>
     <configfile finalname="${configfile.directory}/unimgr.xml">mvn:org.opendaylight.unimgr/unimgr-impl/{{VERSION}}/xml/config</configfile>
   </feature>
@@ -48,4 +53,11 @@ and is available at http://www.eclipse.org/legal/epl-v10.html
     <feature version="${dlux.version}">odl-dlux-all</feature>
   </feature>
 
+  <feature name='odl-unimgr-cisco-xr-driver' version='${project.version}' description='OpenDaylight :: UniMgr :: Cisco XR Driver'>
+    <feature version='${project.version}'>odl-unimgr</feature>
+    <bundle>mvn:org.opendaylight.unimgr/cisco-xrmodels/{{VERSION}}</bundle>
+    <bundle>mvn:org.opendaylight.unimgr/unimgr-cisco-xr-driver/{{VERSION}}</bundle>
+    <configfile finalname="${configfile.directory}/unimgr-cisco-xr-driver.xml">mvn:org.opendaylight.unimgr/unimgr-cisco-xr-driver/{{VERSION}}/xml/config</configfile>
+  </feature>
+
 </features>
index 8b6fe819d290407f035c4f69101c2ceb79eab792..12b0f5dd17981ccbf7adb513d5c42766d6091904 100644 (file)
@@ -6,88 +6,124 @@ This program and the accompanying materials are made available under the
 terms of the Eclipse Public License v1.0 which accompanies this distribution,
 and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
 -->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
 
-  <parent>
-    <groupId>org.opendaylight.controller</groupId>
-    <artifactId>config-parent</artifactId>
-    <version>0.5.0-SNAPSHOT</version>
-    <relativePath/>
-  </parent>
+    <parent>
+        <groupId>org.opendaylight.controller</groupId>
+        <artifactId>config-parent</artifactId>
+        <version>0.5.0-SNAPSHOT</version>
+        <relativePath/>
+    </parent>
 
-  <properties>
-  <ovsdb.version>1.3.0-SNAPSHOT</ovsdb.version>
-  </properties>
+    <properties>
+        <ovsdb.version>1.3.0-SNAPSHOT</ovsdb.version>
+    </properties>
 
-  <modelVersion>4.0.0</modelVersion>
-  <groupId>org.opendaylight.unimgr</groupId>
-  <artifactId>unimgr-impl</artifactId>
-  <version>0.1.0-SNAPSHOT</version>
-  <packaging>bundle</packaging>
-  <dependencies>
-    <dependency>
-      <groupId>${project.groupId}</groupId>
-      <artifactId>unimgr-api</artifactId>
-      <version>${project.version}</version>
-    </dependency>
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.opendaylight.unimgr</groupId>
+    <artifactId>unimgr-impl</artifactId>
+    <version>0.1.0-SNAPSHOT</version>
+    <packaging>bundle</packaging>
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-compiler-plugin</artifactId>
+                <configuration>
+                    <source>1.8</source>
+                    <target>1.8</target>
+                </configuration>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <configuration>
+                    <instructions>
+                        <Import-Package>*</Import-Package>
+                        <Export-Package>org.mef.nrp.impl, org.opendaylight.unimgr.api
+                        </Export-Package>
+                    </instructions>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
 
-<!--     OVSDB dependency -->
-    <dependency>
-      <groupId>org.opendaylight.ovsdb</groupId>
-      <artifactId>southbound-impl</artifactId>
-      <version>${ovsdb.version}</version>
-    </dependency>
+    <dependencies>
+        <dependency>
+            <groupId>${project.groupId}</groupId>
+            <artifactId>unimgr-api</artifactId>
+            <version>${project.version}</version>
+        </dependency>
 
-    <!-- Testing Dependencies -->
-    <dependency>
-      <groupId>junit</groupId>
-      <artifactId>junit</artifactId>
-      <scope>test</scope>
-    </dependency>
+        <!--     OVSDB dependency -->
+        <dependency>
+            <groupId>org.opendaylight.ovsdb</groupId>
+            <artifactId>southbound-impl</artifactId>
+            <version>${ovsdb.version}</version>
+        </dependency>
 
-    <dependency>
-      <groupId>org.mockito</groupId>
-      <artifactId>mockito-all</artifactId>
-      <scope>test</scope>
-    </dependency>
+        <dependency>
+                <groupId>org.opendaylight.unimgr</groupId>
+                <artifactId>edgeassure-1000</artifactId>
+                <version>${project.version}</version>
+        </dependency>
 
-    <dependency>
-      <groupId>org.powermock</groupId>
-      <artifactId>powermock-core</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.powermock</groupId>
-      <artifactId>powermock-module-junit4</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.powermock</groupId>
-      <artifactId>powermock-api-mockito</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.powermock</groupId>
-      <artifactId>powermock-api-support</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.powermock</groupId>
-      <artifactId>powermock-reflect</artifactId>
-      <scope>test</scope>
-    </dependency>
-    <dependency>
-      <groupId>org.opendaylight.mdsal.model</groupId>
-      <artifactId>ietf-yang-types-20130715</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>ch.qos.logback</groupId>
-      <artifactId>logback-core</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>ch.qos.logback</groupId>
-      <artifactId>logback-classic</artifactId>
-    </dependency>
-  </dependencies>
+        <dependency>
+            <groupId>org.opendaylight.netconf</groupId>
+            <artifactId>netconf-topology</artifactId>
+            <version>1.1.0-SNAPSHOT</version>
+        </dependency>
 
+        <!-- Testing Dependencies -->
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.mockito</groupId>
+            <artifactId>mockito-all</artifactId>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-core</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-module-junit4</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-api-mockito</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-api-support</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.powermock</groupId>
+            <artifactId>powermock-reflect</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.opendaylight.mdsal.model</groupId>
+            <artifactId>ietf-yang-types-20130715</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-core</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>ch.qos.logback</groupId>
+            <artifactId>logback-classic</artifactId>
+        </dependency>
+    </dependencies>
 </project>
diff --git a/impl/src/main/java/org/mef/nrp/impl/ActivationDriver.java b/impl/src/main/java/org/mef/nrp/impl/ActivationDriver.java
new file mode 100644 (file)
index 0000000..92b43cb
--- /dev/null
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GForwardingConstruct;
+
+/**
+ * Interface of a driver that maps NRP concepts to the configuration of underlying infrastructure.
+ * The driver is used in following scenario
+ * <ol>
+ *     <li>Driver is initialized. Otherwise stop</li>
+ *     <li>Driver is attached to transaction</li>
+ *     <li>Driver activate/deactivate method gets called</li>
+ *     <li>If all drivers within transaction succeed commit method is called. Otherwise rollback is triggered</li>
+ * </ol>
+ *
+ * @author bartosz.michalik@amartus.com
+ */
+public interface ActivationDriver {
+
+    /**
+     * Called in case all drivers in the transaction has succeeded
+     */
+    void commit();
+
+    /**
+     * Called in case any of drivers in the transaction has failed
+     */
+    void rollback();
+
+    /**
+     * Set state for the driver
+     * @param from near end
+     * @param to far end
+     * @param context context
+     */
+    void initialize(GFcPort from, GFcPort to, GForwardingConstruct context);
+
+    /**
+     * Activates the port from
+     */
+    void activate();
+
+    /**
+     * Deactivates the port from
+     */
+    void deactivate();
+
+
+    /**
+     * Influences the order in which drivers are called within the transaction
+     * @return int priority of this driver when resoving ambiguity
+     */
+    int priority();
+
+
+
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/ActivationDriverAmbiguousException.java b/impl/src/main/java/org/mef/nrp/impl/ActivationDriverAmbiguousException.java
new file mode 100644 (file)
index 0000000..c71ead9
--- /dev/null
@@ -0,0 +1,16 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+/**
+ * This exception indicates that multiple activation drivers are candidates for activating a service. The service
+ * will not be activated because the system failed to select a single driver candidate.
+ */
+public class ActivationDriverAmbiguousException extends RuntimeException {
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/ActivationDriverBuilder.java b/impl/src/main/java/org/mef/nrp/impl/ActivationDriverBuilder.java
new file mode 100644 (file)
index 0000000..8760c89
--- /dev/null
@@ -0,0 +1,85 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import java.util.HashSet;
+import java.util.Map;
+import java.util.Optional;
+import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
+
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+
+/**
+ * Driver builder that can provide stateful driver that are used in NRP forwarding construct transaction.
+ * @author bartosz.michalik@amartus.com
+ */
+public interface ActivationDriverBuilder {
+    /**
+     * Get driver for a single port.
+     * @param port to configure
+     * @param context (de)activation context
+     * @return {@link Optional#empty()} in case it cannot be instantiated for a port, driver otherwise
+     */
+    Optional<ActivationDriver> driverFor(GFcPort port, BuilderContext context);
+
+    /**
+     * Get driver for two ports.
+     * @param aPort a-end port
+     * @param zPort z-end port
+     * @param context blackboard for recording state during driver selection
+     * @return {@link Optional#empty()} in case it cannot be instantiated for a port, driver otherwise
+     */
+    Optional<ActivationDriver> driverFor(GFcPort aPort, GFcPort zPort, BuilderContext context);
+
+    /***
+     * Blackboard pattern that allows for passing the context information between {@link ActivationDriverBuilder}s taking part in transaction
+     */
+    class BuilderContext {
+        private Map<String, Object> ctx = new ConcurrentHashMap<>();
+
+        /**
+         * Get value of a certain type.
+         * @param key key
+         * @param <T> expected type
+         * @return value or empty
+         */
+        @SuppressWarnings("unchecked")
+        public <T> Optional<T> get(String key) {
+            return Optional.ofNullable((T) ctx.get(key));
+        }
+
+
+        /**
+         * Put value to blackboard.
+         * @param k key
+         * @param value value object
+         */
+        public void put(String k, Object value) {
+            ctx.put(k, value);
+        }
+
+        /**
+         * Remove value from blackboard.
+         * @param k key
+         */
+        public void remove(String k) {
+            ctx.remove(k);
+        }
+
+        /**
+         * Get all keys.
+         * @return available keys in blackboard
+         */
+        public Set<String> keys() {
+            return new HashSet<>(ctx.keySet());
+        }
+    }
+
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/ActivationDriverNotFoundException.java b/impl/src/main/java/org/mef/nrp/impl/ActivationDriverNotFoundException.java
new file mode 100644 (file)
index 0000000..a72e6ba
--- /dev/null
@@ -0,0 +1,16 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+/**
+ * his exception indicates that no activation drivers was found for activating a service. The service
+ * will not be activated because the system failed to identify any driver candidate.
+ */
+public class ActivationDriverNotFoundException extends RuntimeException {
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/ActivationDriverRepoService.java b/impl/src/main/java/org/mef/nrp/impl/ActivationDriverRepoService.java
new file mode 100644 (file)
index 0000000..9c49ca3
--- /dev/null
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+
+/**
+ * This interface is used to request an ActivationDriver for a given MEF service fragment.
+ */
+public interface ActivationDriverRepoService {
+
+    void bindBuilder(ActivationDriverBuilder builder);
+
+    void unbindBuilder(ActivationDriverBuilder builder);
+
+    /**
+     * Get driver for a port.
+     * @param port to
+     * @param context blackboard for recording state during driver selection
+     * @return activation driver
+     * @throws ActivationDriverAmbiguousException when multiple drivers declare they can configure port
+     * @throws ActivationDriverNotFoundException when no driver found for port
+     */
+    ActivationDriver getDriver(GFcPort port, ActivationDriverBuilder.BuilderContext context);
+
+    /**
+     * Get driver for two ports on a single device.
+     * @param aPort from port
+     * @param zPort to port
+     * @param context blackboard for recording state during driver selection
+     * @return activation driver
+     * @throws ActivationDriverAmbiguousException when multiple drivers declare they can configure ports
+     * @throws ActivationDriverNotFoundException when no driver found for ports
+     */
+    ActivationDriver getDriver(GFcPort aPort, GFcPort zPort, ActivationDriverBuilder.BuilderContext context);
+}
\ No newline at end of file
diff --git a/impl/src/main/java/org/mef/nrp/impl/ActivationDriverRepoServiceImpl.java b/impl/src/main/java/org/mef/nrp/impl/ActivationDriverRepoServiceImpl.java
new file mode 100644 (file)
index 0000000..4aec03f
--- /dev/null
@@ -0,0 +1,77 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import java.util.Collection;
+import java.util.List;
+import java.util.Optional;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.function.Function;
+import java.util.stream.Collectors;
+
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * @author alex.feigin@hpe.com
+ */
+public class ActivationDriverRepoServiceImpl implements ActivationDriverRepoService {
+    private static final Logger LOG = LoggerFactory.getLogger(ActivationDriverRepoServiceImpl.class);
+
+    private Collection<ActivationDriverBuilder> builders = ConcurrentHashMap.newKeySet();
+
+
+    /* (non-Javadoc)
+     * @see org.mef.nrp.impl.ActivationDriverRepoService#bindBuilder(org.mef.nrp.impl.ActivationDriverBuilder)
+     */
+    @Override
+    public void bindBuilder(ActivationDriverBuilder builder) {
+        if (builder == null) {
+            return;
+        }
+        LOG.info("ActivationDriverRepoService.bindBuilder got [{}] instance", builder.getClass().getSimpleName());
+        builders.add(builder);
+    }
+
+    /* (non-Javadoc)
+     * @see org.mef.nrp.impl.ActivationDriverRepoService#unbindBuilder(org.mef.nrp.impl.ActivationDriverBuilder)
+     */
+    @Override
+    public void unbindBuilder(ActivationDriverBuilder builder) {
+        if (builder == null) {
+            return;
+        }
+        LOG.info("ActivationDriverRepoService.unbindBuilder got [{}] instance", builder.getClass().getSimpleName());
+        builders.remove(builder);
+    }
+
+    protected ActivationDriver getDriver(Function<ActivationDriverBuilder, Optional<ActivationDriver>> driver) {
+        final List<ActivationDriver> drivers = builders.stream().map(driver)
+                .filter(Optional::isPresent)
+                .map(Optional::get)
+                .collect(Collectors.toList());
+
+        if (drivers.size() > 1) {
+            throw new ActivationDriverAmbiguousException();
+        }
+        if (drivers.size() == 0) {
+            throw new ActivationDriverNotFoundException();
+        }
+        return drivers.get(0);
+    }
+
+    public ActivationDriver getDriver(GFcPort aPort, GFcPort zPort, ActivationDriverBuilder.BuilderContext context) {
+        return getDriver(x -> x.driverFor(aPort, zPort, context));
+    }
+
+    public ActivationDriver getDriver(GFcPort port, ActivationDriverBuilder.BuilderContext context) {
+        return getDriver(x -> x.driverFor(port, context));
+    }
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/ActivationTransaction.java b/impl/src/main/java/org/mef/nrp/impl/ActivationTransaction.java
new file mode 100644 (file)
index 0000000..c968236
--- /dev/null
@@ -0,0 +1,70 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * Runs activation over multiple @ drivers.
+ *
+ * @author bartosz.michalik@amartus.com
+ */
+public class ActivationTransaction {
+    private static final Logger LOG = LoggerFactory.getLogger(ActivationTransaction.class);
+    private List<ActivationDriver> drivers = new ArrayList<>();
+
+
+    public void addDriver(ActivationDriver driver) {
+        drivers.add(driver);
+    }
+
+    public void activate() {
+        sortDrivers();
+        try {
+            for(ActivationDriver d: drivers) { d.activate(); }
+            commit();
+            LOG.info("Activate transaction successful");
+        } catch (Exception e) {
+            //XXX add transaction identification ???
+            LOG.warn("Rolling back activate transaction ", e);
+            rollback();
+        }
+    }
+
+
+    public void deactivate() {
+        sortDrivers();
+        try {
+            for(ActivationDriver d: drivers) { d.deactivate(); }
+            LOG.info("Deactivate transaction successful");
+            commit();
+        } catch (Exception e) {
+            //XXX add transaction identification ???
+            LOG.warn("Rolling back deactivate transaction ", e);
+            rollback();
+        }
+    }
+
+    private void commit() {
+        drivers.stream().forEach(ActivationDriver::commit);
+    }
+
+    private void rollback() {
+        drivers.stream().forEach(ActivationDriver::rollback);
+    }
+
+    private void sortDrivers() {
+        drivers.sort((a,b) -> a.priority() - b.priority());
+    }
+
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/DummyActivationDriver.java b/impl/src/main/java/org/mef/nrp/impl/DummyActivationDriver.java
new file mode 100644 (file)
index 0000000..2bfbfc2
--- /dev/null
@@ -0,0 +1,36 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GForwardingConstruct;
+
+/**
+ * Useful for scenarios where {@link GForwardingConstruct} (de)activaiton can be completed in single shoot
+ * @author bartosz.michalik@amartus.com
+ */
+public class DummyActivationDriver implements ActivationDriver {
+    @Override
+    public void commit() {}
+
+    @Override
+    public void rollback() {}
+
+    @Override
+    public void initialize(GFcPort from, GFcPort to, GForwardingConstruct context) {}
+
+    @Override
+    public void activate() {}
+
+    @Override
+    public void deactivate() {}
+
+    @Override
+    public int priority() {return Integer.MIN_VALUE;}
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/EdgeAssureActivator.java b/impl/src/main/java/org/mef/nrp/impl/EdgeAssureActivator.java
new file mode 100644 (file)
index 0000000..daece2b
--- /dev/null
@@ -0,0 +1,79 @@
+/*
+ * Copyright (c) 2016 Microsemi and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import java.util.LinkedList;
+import java.util.List;
+
+import org.opendaylight.controller.md.sal.binding.api.DataBroker;
+import org.opendaylight.controller.md.sal.binding.api.MountPointService;
+import org.opendaylight.controller.md.sal.binding.api.WriteTransaction;
+import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType;
+import org.opendaylight.yang.gen.v1.http.www.microsemi.com.microsemi.edge.assure.msea.types.rev160229.Identifier45;
+import org.opendaylight.yang.gen.v1.http.www.microsemi.com.microsemi.edge.assure.msea.uni.evc.service.rev160317.MefServices;
+import org.opendaylight.yang.gen.v1.http.www.microsemi.com.microsemi.edge.assure.msea.uni.evc.service.rev160317.mef.services.Uni;
+import org.opendaylight.yang.gen.v1.http.www.microsemi.com.microsemi.edge.assure.msea.uni.evc.service.rev160317.mef.services.uni.Evc;
+import org.opendaylight.yang.gen.v1.http.www.microsemi.com.microsemi.edge.assure.msea.uni.evc.service.rev160317.mef.services.uni.EvcBuilder;
+import org.opendaylight.yang.gen.v1.http.www.microsemi.com.microsemi.edge.assure.msea.uni.evc.service.rev160317.mef.services.uni.EvcKey;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import com.google.common.base.Optional;
+
+public class EdgeAssureActivator implements ResourceActivator {
+
+    private static final Logger log = LoggerFactory.getLogger(EdgeAssureActivator.class);
+    private MountPointService mountService;
+    DataBroker baseDataBroker;
+
+    EdgeAssureActivator(DataBroker dataBroker, MountPointService mountService) {
+        this.mountService = mountService;
+        baseDataBroker = dataBroker;
+    }
+
+    @Override
+    public void activate(String nodeName, String outerName, String innerName, GFcPort port, GFcPort neighbor,
+            long mtu) {
+        log.info("Activation called on EdgeAssureActivator");
+
+        String portLtpId = port.getLtpRefList().get(0).getValue();
+        String neighborLtpId = neighbor.getLtpRefList().get(0).getValue();
+
+        String neighborHostname = neighborLtpId.split(":")[0];
+
+        long evcId = 1;
+
+        EvcBuilder evcBuilder = new EvcBuilder();
+        evcBuilder.setEvcIndex(evcId).setName(new Identifier45("evc" + String.valueOf(evcId)));
+        List<Evc> evcConfigs = new LinkedList<>();
+        evcConfigs.add(evcBuilder.build());
+
+        InstanceIdentifier<Evc> evcConfigId = InstanceIdentifier.builder(MefServices.class).child(Uni.class)
+                .child(Evc.class, new EvcKey(evcId)).build();
+
+        Optional<DataBroker> optional = MountPointHelper.getDataBroker(mountService, nodeName);
+        if (optional.isPresent()) {
+            DataBroker netconfDataBroker = optional.get();
+            WriteTransaction w = netconfDataBroker.newWriteOnlyTransaction();
+            w.merge(LogicalDatastoreType.CONFIGURATION, evcConfigId, evcBuilder.build());
+        } else {
+            log.error("");
+        }
+    }
+
+    @Override
+    public void deactivate(String nodeName, String outerName, String innerName, GFcPort port, GFcPort neighbor,
+            long mtu) {
+        log.info("Deactivation called on EdgeAssureActivator. Not yet implemented.");
+
+    }
+
+}
\ No newline at end of file
diff --git a/impl/src/main/java/org/mef/nrp/impl/EdgeAssureDriverBuilder.java b/impl/src/main/java/org/mef/nrp/impl/EdgeAssureDriverBuilder.java
new file mode 100644 (file)
index 0000000..704972e
--- /dev/null
@@ -0,0 +1,92 @@
+/*
+ * Copyright (c) 2016 Microsemi and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import org.opendaylight.controller.md.sal.binding.api.DataBroker;
+import org.opendaylight.controller.md.sal.binding.api.MountPointService;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GForwardingConstruct;
+
+import java.util.Optional;
+
+/**
+ * Fake driver builder;
+ * @author sean.condon@microsemi.com
+ */
+public class EdgeAssureDriverBuilder implements ActivationDriverBuilder {
+
+    private final FixedServiceNaming namingProvider;
+    private final EdgeAssureActivator edgeAssureActivator;
+
+    EdgeAssureDriverBuilder(DataBroker dataBroker, MountPointService mountService) {
+        this.namingProvider = new FixedServiceNaming();
+        edgeAssureActivator = new EdgeAssureActivator(dataBroker, mountService);
+    }
+
+    @Override
+    public Optional<ActivationDriver> driverFor(GFcPort port, BuilderContext context) {
+        final ActivationDriver driver = new ActivationDriver() {
+            public GForwardingConstruct ctx;
+            public GFcPort aEnd;
+            public GFcPort zEnd;
+
+            @Override
+            public void commit() {
+                //ignore for the moment
+            }
+
+            @Override
+            public void rollback() {
+                //ignore for the moment
+            }
+
+            @Override
+            public void initialize(GFcPort from, GFcPort to, GForwardingConstruct ctx) {
+                this.zEnd = to;
+                this.aEnd = from;
+                this.ctx = ctx;
+            }
+
+            @Override
+            public void activate() {
+                String id = ctx.getUuid();
+                long mtu = 1500;
+                String outerName = namingProvider.getOuterName(id);
+                String innerName = namingProvider.getInnerName(id);
+
+                String aEndNodeName = aEnd.getLtpRefList().get(0).getValue().split(":")[0];
+                edgeAssureActivator.activate(aEndNodeName, outerName, innerName, aEnd, zEnd, mtu);
+
+            }
+
+            @Override
+            public void deactivate() {
+                String id = ctx.getUuid();
+                long mtu = 1500;
+                String outerName = namingProvider.getOuterName(id);
+                String innerName = namingProvider.getInnerName(id);
+
+                String aEndNodeName = aEnd.getLtpRefList().get(0).getValue().split(":")[0];
+                edgeAssureActivator.deactivate(aEndNodeName, outerName, innerName, aEnd, zEnd, mtu);
+            }
+
+            @Override
+            public int priority() {
+                return 0;
+            }
+        };
+
+        return Optional.of(driver);
+    }
+
+    @Override
+    public Optional<ActivationDriver> driverFor(GFcPort aPort, GFcPort zPort, BuilderContext context) {
+        return Optional.empty();
+    }
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/FixedServiceNaming.java b/impl/src/main/java/org/mef/nrp/impl/FixedServiceNaming.java
new file mode 100644 (file)
index 0000000..c7abdeb
--- /dev/null
@@ -0,0 +1,27 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+/**
+ * This is a placeholder class for implementing service naming when activating and deactivating MEF services.
+ * TODO: Implement a more robust naming provider.
+ */
+public class FixedServiceNaming implements ServiceNaming {
+
+    @Override
+    public String getOuterName(String id) {
+        return "EUR16-" + id;
+    }
+
+    @Override
+    public String getInnerName(String id) {
+        return "EUR16-p2p-" + id;
+    }
+
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/ForwardingConstructHelper.java b/impl/src/main/java/org/mef/nrp/impl/ForwardingConstructHelper.java
new file mode 100644 (file)
index 0000000..ceb2a54
--- /dev/null
@@ -0,0 +1,29 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GForwardingConstruct;
+
+public class ForwardingConstructHelper {
+
+    public static boolean isTheSameNode(GForwardingConstruct forwardingConstruct) {
+        String aHost = host(ltp(forwardingConstruct, 0));
+        String zHost = host(ltp(forwardingConstruct, 1));
+
+        return aHost != null && zHost != null && aHost.equals(zHost);
+    }
+
+    public static String ltp(GForwardingConstruct fc, int port) {
+        return fc.getFcPort().get(port).getLtpRefList().get(0).getValue();
+    }
+
+    public static String host(String ltp) {
+        return ltp.split(":")[0];
+    }
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/MountPointHelper.java b/impl/src/main/java/org/mef/nrp/impl/MountPointHelper.java
new file mode 100644 (file)
index 0000000..e96666e
--- /dev/null
@@ -0,0 +1,53 @@
+/*
+ * Copyright (c) 2016 Cisco Systems and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import org.opendaylight.controller.md.sal.binding.api.DataBroker;
+import org.opendaylight.controller.md.sal.binding.api.MountPoint;
+import org.opendaylight.controller.md.sal.binding.api.MountPointService;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.netconf.node.topology.rev150114.network.topology.topology.topology.types.TopologyNetconf;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.NetworkTopology;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.NodeId;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.TopologyId;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.Topology;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.TopologyKey;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.topology.Node;
+import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.topology.NodeKey;
+import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
+
+import com.google.common.base.Optional;
+
+public class MountPointHelper {
+
+    /*
+     * Find a node's NETCONF mount point and then retrieve its DataBroker.
+     *
+     * e.g.
+     * http://localhost:8080/restconf/config/network-topology:network-topology/
+     * topology/topology-netconf/node/<nodeName>/yang-ext:mount/
+     */
+    public static Optional<DataBroker> getDataBroker(MountPointService mountService, String nodeName) {
+        NodeId nodeId = new NodeId(nodeName);
+
+        InstanceIdentifier<Node> nodeInstanceId = InstanceIdentifier.builder(NetworkTopology.class)
+                .child(Topology.class, new TopologyKey(new TopologyId(TopologyNetconf.QNAME.getLocalName())))
+                .child(Node.class, new NodeKey(nodeId))
+                .build();
+
+        final Optional<MountPoint> nodeOptional = mountService.getMountPoint(nodeInstanceId);
+
+        if (!nodeOptional.isPresent()) {
+            return Optional.absent();
+        }
+
+        MountPoint nodeMountPoint = nodeOptional.get();
+        return Optional.of(nodeMountPoint.getService(DataBroker.class).get());
+    }
+
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/ResourceActivator.java b/impl/src/main/java/org/mef/nrp/impl/ResourceActivator.java
new file mode 100644 (file)
index 0000000..939b909
--- /dev/null
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+
+/**
+ * Device facing SPI for activating or deactivating a fragment of an NRP ForwardingConstruct on a single device.
+ */
+public interface ResourceActivator {
+
+    /**
+     * Activate a service fragment on the node identified by nodeName.
+     *
+     * @param nodeName the name of node in network topology
+     * @param outerName name of outer activation construct
+     * @param innerName name of inner activation construct
+     * @param flowPoint the fc-port to be activated
+     * @param neighbor the neighbor fc-port
+     * @param mtu the desired MTU for this forwarding construct
+     */
+    public void activate(String nodeName, String outerName, String innerName, GFcPort flowPoint, GFcPort neighbor, long mtu);
+
+    /**
+     * Deactivate a service fragment on the node identified by nodeName.
+     *
+     * @param nodeName the name of node in network topology
+     * @param outerName name of outer deactivation construct
+     * @param innerName name of inner deactivation construct
+     * @param flowPoint the fc-port to be deactivated
+     * @param neighbor the neighbor fc-port
+     * @param mtu the desired MTU for this forwarding construct
+     */
+    public void deactivate(String nodeName, String outerName, String innerName, GFcPort flowPoint, GFcPort neighbor, long mtu);
+}
diff --git a/impl/src/main/java/org/mef/nrp/impl/ServiceNaming.java b/impl/src/main/java/org/mef/nrp/impl/ServiceNaming.java
new file mode 100644 (file)
index 0000000..f42cdc7
--- /dev/null
@@ -0,0 +1,31 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.mef.nrp.impl;
+
+/**
+ * This SPI is used to create resource names when constructing device configuration.
+ */
+public interface ServiceNaming {
+
+    /**
+     * Return a resource name composed to include the provided id.
+     *
+     * @param id unique allocated id
+     * @return String name
+     */
+    public String getOuterName(String id);
+
+    /**
+     * Return a resource name composed to include the provided id.
+     *
+     * @param id unique allocated id
+     * @return String name
+     */
+    public String getInnerName(String id);
+}
diff --git a/impl/src/main/java/org/opendaylight/unimgr/impl/FCRouteChangeListener.java b/impl/src/main/java/org/opendaylight/unimgr/impl/FCRouteChangeListener.java
new file mode 100644 (file)
index 0000000..32b9dec
--- /dev/null
@@ -0,0 +1,127 @@
+/*
+ * Copyright (c) 2016 CableLabs and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.unimgr.impl;
+
+import java.util.Collection;
+
+import org.mef.nrp.impl.ActivationDriverRepoService;
+import org.opendaylight.controller.md.sal.binding.api.DataBroker;
+import org.opendaylight.controller.md.sal.binding.api.DataObjectModification;
+import org.opendaylight.controller.md.sal.binding.api.DataTreeChangeListener;
+import org.opendaylight.controller.md.sal.binding.api.DataTreeIdentifier;
+import org.opendaylight.controller.md.sal.binding.api.DataTreeModification;
+import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.FcRouteList;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.fcroutelist.FcRoute;
+import org.opendaylight.yangtools.concepts.ListenerRegistration;
+import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * NRP top level change model listener
+ * @author bartosz.michalik@amartus.com
+ */
+public class FCRouteChangeListener implements DataTreeChangeListener<FcRoute>, AutoCloseable {
+    private static final Logger LOG = LoggerFactory.getLogger(FCRouteChangeListener.class);
+    private final ListenerRegistration<FCRouteChangeListener> listener;
+    private final FcRouteActivatorService routeActivator;
+
+    private volatile ActivationDriverRepoService activationRepoService;
+
+    public FCRouteChangeListener(DataBroker dataBroker) {
+        final InstanceIdentifier<FcRoute> fwPath = getFwConstructsPath();
+        final DataTreeIdentifier<FcRoute> dataTreeIid = new DataTreeIdentifier<>(LogicalDatastoreType.CONFIGURATION, fwPath);
+        listener = dataBroker.registerDataTreeChangeListener(dataTreeIid, this);
+        this.routeActivator = new FcRouteActivatorService();
+
+        LOG.info("FCRouteChangeListener created and registered");
+    }
+
+    /**
+     * Basic Implementation of DataTreeChange Listener to execute add, update or remove command
+     * based on the data object modification type.
+     */
+    @Override
+    public void onDataTreeChanged(Collection<DataTreeModification<FcRoute>> collection) {
+        //TODO add lock for concurrency support
+        if(activationRepoService == null) {
+            //TODO improve comment
+            LOG.warn("ActivationDriverRepoService is not ready yet - ignoring request");
+            return;
+        }
+        for (final DataTreeModification<FcRoute> change : collection) {
+            final DataObjectModification<FcRoute> root = change.getRootNode();
+            switch (root.getModificationType()) {
+                case SUBTREE_MODIFIED:
+                    update(change);
+                    break;
+                case WRITE:
+                    //TO overcome whole subtree change event
+                    boolean update = change.getRootNode().getDataBefore() != null;
+
+                    if(update) {
+                        update(change);
+                    } else {
+                        add(change);
+                    }
+
+                    break;
+                case DELETE:
+                    remove(change);
+                    break;
+            }
+        }
+    }
+
+    public void add(DataTreeModification<FcRoute> newDataObject) {
+        //TODO: Refine the logged addition
+        LOG.debug("FcRoute add event received {}", newDataObject);
+        routeActivator.activate(newDataObject.getRootNode().getDataAfter());
+
+    }
+
+    public void remove(DataTreeModification<FcRoute> removedDataObject) {
+        //TODO: Refine the logged removal
+        LOG.debug("FcRoute remove event received {}", removedDataObject);
+        routeActivator.deactivate(removedDataObject.getRootNode().getDataBefore());
+
+    }
+
+    public void update(DataTreeModification<FcRoute> modifiedDataObject) {
+        //TODO: Refine the logged modification
+        LOG.debug("FcRoute update event received {}", modifiedDataObject);
+
+        //TODO for the moment transactional nature of this action is ignored :P
+        routeActivator.deactivate(modifiedDataObject.getRootNode().getDataBefore());
+        routeActivator.activate(modifiedDataObject.getRootNode().getDataAfter());
+    }
+
+    @Override
+    public void close() {
+        listener.close();
+    }
+
+    private InstanceIdentifier<FcRoute> getFwConstructsPath() {
+        final InstanceIdentifier<FcRoute> path = InstanceIdentifier
+                .builder(FcRouteList.class)
+                .child(FcRoute.class).build();
+
+        return path;
+    }
+
+    public void setActivationDriverRepoService(ActivationDriverRepoService service) {
+        this.activationRepoService = service;
+        routeActivator.setActivationRepoService(service);
+    }
+
+    public void unsetActivationDriverRepoService() {
+        this.activationRepoService = null;
+        routeActivator.unsetActivationRepoService();
+    }
+}
diff --git a/impl/src/main/java/org/opendaylight/unimgr/impl/FcRouteActivatorService.java b/impl/src/main/java/org/opendaylight/unimgr/impl/FcRouteActivatorService.java
new file mode 100644 (file)
index 0000000..8fa239b
--- /dev/null
@@ -0,0 +1,176 @@
+/*
+ * Copyright (c) 2016 Cisco Systems Inc and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+
+package org.opendaylight.unimgr.impl;
+
+import java.util.List;
+import java.util.Optional;
+import java.util.concurrent.locks.ReentrantReadWriteLock;
+
+import javax.annotation.Nonnull;
+
+import org.mef.nrp.impl.ActivationDriver;
+import org.mef.nrp.impl.ActivationDriverAmbiguousException;
+import org.mef.nrp.impl.ActivationDriverBuilder;
+import org.mef.nrp.impl.ActivationDriverNotFoundException;
+import org.mef.nrp.impl.ActivationDriverRepoService;
+import org.mef.nrp.impl.ActivationTransaction;
+import org.mef.nrp.impl.ForwardingConstructHelper;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GForwardingConstruct;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.fcroutelist.FcRoute;
+import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.g_forwardingconstruct.FcPort;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * @author bartosz.michalik@amartus.com
+ */
+public class FcRouteActivatorService {
+    private static final Logger LOG = LoggerFactory.getLogger(FcRouteActivatorService.class);
+    private ActivationDriverRepoService activationRepoService;
+    final private ReentrantReadWriteLock lock;
+
+    public FcRouteActivatorService() {
+        lock = new ReentrantReadWriteLock();
+    }
+
+    public void activate(@Nonnull FcRoute route) {
+        for(GForwardingConstruct fwdC : route.getForwardingConstruct()) {
+            Optional<ActivationTransaction> tx = prepareTransaction(fwdC);
+            if (tx.isPresent()) {
+                tx.get().activate();
+            } else {
+                LOG.warn("No transaction for this activation request {}", fwdC);
+            }
+        }
+    }
+
+    public void deactivate(@Nonnull FcRoute route) {
+        for(GForwardingConstruct fwdC : route.getForwardingConstruct()) {
+            Optional<ActivationTransaction> tx = prepareTransaction(fwdC);
+            if (tx.isPresent()) {
+                tx.get().deactivate();
+            } else {
+                LOG.warn("No transaction for this deactivation request {}", fwdC);
+            }
+        }
+    }
+
+    private Optional<ActivationTransaction> prepareTransaction(GForwardingConstruct fwdC) {
+        final List<FcPort> list = fwdC.getFcPort();
+        //TODO validate pre-condition
+        final GFcPort a = list.get(0);
+        final GFcPort z = list.get(1);
+
+        return ForwardingConstructHelper.isTheSameNode(fwdC) ? getTxForNode(a,z, fwdC) :
+                getTxForMultiNode(a,z, fwdC);
+    }
+
+    private Optional<ActivationTransaction> getTxForMultiNode(GFcPort a, GFcPort z, GForwardingConstruct fwdC) {
+        lock.readLock().lock();
+        try {
+            final ActivationDriverBuilder.BuilderContext ctx = new ActivationDriverBuilder.BuilderContext();
+            ActivationDriver activator = activationRepoService.getDriver(a, z, ctx);
+
+            activator.initialize(a, z, fwdC);
+            ActivationTransaction tx = new ActivationTransaction();
+            tx.addDriver(activator);
+            return Optional.of(tx);
+        } catch(ActivationDriverNotFoundException e) {
+            LOG.warn("No unique activation driver found for {} <-> {}", a, z);
+            return Optional.empty();
+        } catch(ActivationDriverAmbiguousException e) {
+            LOG.warn("Multiple activation driver found for {} <-> {}", z, a);
+            return Optional.empty();
+        } catch (Exception e) {
+            LOG.error("driver initialization exception", e);
+            return Optional.empty();
+        } finally {
+            lock.readLock().unlock();
+        }
+    }
+
+    private Optional<ActivationTransaction> getTxForNode(GFcPort a, GFcPort z, GForwardingConstruct fwdC) {
+        //1. find and initialize drivers
+        Optional<ActivationDriver> aActivator;
+        Optional<ActivationDriver> zActivator;
+        lock.readLock().lock();
+        try {
+
+            final ActivationDriverBuilder.BuilderContext ctx = new ActivationDriverBuilder.BuilderContext();
+            ctx.put(GForwardingConstruct.class.getName(), fwdC);
+
+            aActivator = findDriver(a, ctx);
+            zActivator = findDriver(z, ctx);
+
+            if (aActivator.isPresent() && zActivator.isPresent()) {
+                aActivator.get().initialize(a, z, fwdC);
+                zActivator.get().initialize(z, a, fwdC);
+            } else {
+                // ??? TODO improve comment for better traceability
+                LOG.error("drivers for both ends needed");
+                return Optional.empty();
+            }
+
+        } catch (Exception e) {
+            LOG.error("driver initialization exception",e);
+            return Optional.empty();
+        } finally {
+            lock.readLock().unlock();
+        }
+
+        final ActivationTransaction tx = new ActivationTransaction();
+        tx.addDriver(aActivator.get());
+        tx.addDriver(zActivator.get());
+
+        return Optional.of(tx);
+    }
+
+    protected Optional<ActivationDriver> findDriver(GFcPort port, ActivationDriverBuilder.BuilderContext fwdC) {
+        if(activationRepoService == null)  {
+            LOG.warn("Activation Driver repo is not initialized");
+            return Optional.empty();
+        }
+        try {
+            return Optional.ofNullable(activationRepoService.getDriver(port, fwdC));
+        } catch(ActivationDriverNotFoundException e) {
+            LOG.warn("No unique activation driver found for {}", port);
+            return Optional.empty();
+        } catch(ActivationDriverAmbiguousException e) {
+            LOG.warn("Multiple activation driver found for {}", port);
+            return Optional.empty();
+        }
+
+
+    }
+
+    public void setActivationRepoService(ActivationDriverRepoService activationRepoService) {
+        lock.writeLock().lock();
+        this.activationRepoService = activationRepoService;
+        lock.writeLock().unlock();
+    }
+
+    public void unsetActivationRepoService() {
+        lock.writeLock().lock();
+        this.activationRepoService = null;
+        lock.writeLock().unlock();
+    }
+
+    static final class Context {
+        final GFcPort a;
+        final GFcPort z;
+        final GForwardingConstruct fwC;
+
+        public Context(GFcPort a, GFcPort z, GForwardingConstruct fwC) {
+            this.a = a;
+            this.z = z;
+            this.fwC = fwC;
+        }
+    }
+}
index fd9701243e92d104495e56f8d74ce32609961ee1..fe0619dd9ec8f86d10b9c94950ed85d4a79e8002 100755 (executable)
@@ -9,6 +9,8 @@ package org.opendaylight.unimgr.impl;
 
 import java.util.List;
 
+import org.mef.nrp.impl.ActivationDriverRepoService;
+import org.mef.nrp.impl.ActivationDriverRepoServiceImpl;
 import org.opendaylight.controller.md.sal.binding.api.DataBroker;
 import org.opendaylight.controller.md.sal.binding.api.ReadWriteTransaction;
 import org.opendaylight.controller.md.sal.common.api.data.LogicalDatastoreType;
@@ -53,6 +55,7 @@ public class UnimgrProvider implements BindingAwareProvider, AutoCloseable, IUni
     private OvsNodeDataTreeChangeListener ovsListener;
     private UniDataTreeChangeListener uniListener;
     private ServiceRegistration<IUnimgrConsoleProvider> unimgrConsoleRegistration;
+    private FCRouteChangeListener fwConstructListener;
 
     public UnimgrProvider() {
         LOG.info("Unimgr provider initialized");
@@ -79,6 +82,7 @@ public class UnimgrProvider implements BindingAwareProvider, AutoCloseable, IUni
         uniListener.close();
         evcListener.close();
         ovsListener.close();
+        fwConstructListener.close();
     }
 
     @Override
@@ -129,7 +133,7 @@ public class UnimgrProvider implements BindingAwareProvider, AutoCloseable, IUni
                 transaction.cancel();
             }
         } catch (final Exception e) {
-            LOG.error("Error initializing unimgr topology {}",e);
+            LOG.error("Error initializing unimgr topology {}", e);
         }
     }
 
@@ -143,25 +147,31 @@ public class UnimgrProvider implements BindingAwareProvider, AutoCloseable, IUni
         LOG.info("UnimgrProvider Session Initiated");
 
         // Retrieve the data broker to create transactions
-        dataBroker =  session.getSALService(DataBroker.class);
+        dataBroker = session.getSALService(DataBroker.class);
         // Register the unimgr OSGi CLI
         final BundleContext context = FrameworkUtil.getBundle(this.getClass()).getBundleContext();
-        unimgrConsoleRegistration = context.registerService(IUnimgrConsoleProvider.class,this, null);
+        unimgrConsoleRegistration = context.registerService(IUnimgrConsoleProvider.class, this, null);
 
         // Register the data trees change listener
         uniListener = new UniDataTreeChangeListener(dataBroker);
         evcListener = new EvcDataTreeChangeListener(dataBroker);
         ovsListener = new OvsNodeDataTreeChangeListener(dataBroker);
 
+        ActivationDriverRepoService activationDriverRepoService = new ActivationDriverRepoServiceImpl();
+        context.registerService(ActivationDriverRepoService.class, activationDriverRepoService, null);
+
+        fwConstructListener = new FCRouteChangeListener(dataBroker);
+        fwConstructListener.setActivationDriverRepoService(activationDriverRepoService);
+
         // Initialize operational and default config data in MD-SAL data store
         initDatastore(LogicalDatastoreType.CONFIGURATION,
-                      UnimgrConstants.UNI_TOPOLOGY_ID);
+                UnimgrConstants.UNI_TOPOLOGY_ID);
         initDatastore(LogicalDatastoreType.OPERATIONAL,
-                      UnimgrConstants.UNI_TOPOLOGY_ID);
+                UnimgrConstants.UNI_TOPOLOGY_ID);
         initDatastore(LogicalDatastoreType.CONFIGURATION,
-                      UnimgrConstants.EVC_TOPOLOGY_ID);
+                UnimgrConstants.EVC_TOPOLOGY_ID);
         initDatastore(LogicalDatastoreType.OPERATIONAL,
-                      UnimgrConstants.EVC_TOPOLOGY_ID);
+                UnimgrConstants.EVC_TOPOLOGY_ID);
     }
 
     @Override
@@ -181,7 +191,7 @@ public class UnimgrProvider implements BindingAwareProvider, AutoCloseable, IUni
 
     @Override
     public boolean updateEvc(final InstanceIdentifier<Link> evcKey, final EvcAugmentation evc, final UniSource uniSource,
-            final UniDest uniDest) {
+                             final UniDest uniDest) {
         final InstanceIdentifier<?> sourceUniIid = uniSource.getUni();
         final InstanceIdentifier<?> destinationUniIid = uniDest.getUni();
         return EvcUtils.updateEvcNode(LogicalDatastoreType.CONFIGURATION, evcKey, evc, sourceUniIid,
@@ -198,7 +208,7 @@ public class UnimgrProvider implements BindingAwareProvider, AutoCloseable, IUni
             Node ovsdbNode;
             if (uni.getOvsdbNodeRef() != null) {
                 final OvsdbNodeRef ovsdbNodeRef = uni.getOvsdbNodeRef();
-                ovsdbNode= MdsalUtils.readNode(dataBroker,
+                ovsdbNode = MdsalUtils.readNode(dataBroker,
                         LogicalDatastoreType.OPERATIONAL, ovsdbNodeRef.getValue()).get();
 
                 UniUtils.updateUniNode(LogicalDatastoreType.OPERATIONAL, uniIID, uni, ovsdbNode, dataBroker);
index 0c07989555fa3dc8c3bb653d90d8f5cac21c9f4e..a695aed69547246584dc0853bba576af01befae7 100644 (file)
@@ -38,9 +38,9 @@ import org.opendaylight.yangtools.yang.binding.InstanceIdentifier.PathArgument;
  */
 public final class DataTreeModificationHelper {
 
-    public static final DataTreeModification<Node> getUniNode(Node node) {
-        DataTreeIdentifier<Node> uniDataTreeIid = new DataTreeIdentifier<>(LogicalDatastoreType.CONFIGURATION, getUniIid("10.10.1.3"));
-        DataObjectModification<Node> uniDataTreeObj = new DataObjectModification<Node>() {
+    public static final DataTreeModification<Node> getUniNode(final Node node) {
+        final DataTreeIdentifier<Node> uniDataTreeIid = new DataTreeIdentifier<>(LogicalDatastoreType.CONFIGURATION, getUniIid("10.10.1.3"));
+        final DataObjectModification<Node> uniDataTreeObj = new DataObjectModification<Node>() {
             @Override
             public Collection<DataObjectModification<? extends DataObject>> getModifiedChildren() {
                 // TODO Auto-generated method stub
@@ -114,9 +114,9 @@ public final class DataTreeModificationHelper {
         return uniNodeIid;
     }
 
-    public static final DataTreeModification<Link> getEvcLink(Link link) {
-        DataTreeIdentifier<Link> evcDataTreeIid = new DataTreeIdentifier<>(LogicalDatastoreType.CONFIGURATION, getEvcLinkIid("1"));
-        DataObjectModification<Link> evcDataTreeObj = new DataObjectModification<Link>() {
+    public static final DataTreeModification<Link> getEvcLink(final Link link) {
+        final DataTreeIdentifier<Link> evcDataTreeIid = new DataTreeIdentifier<>(LogicalDatastoreType.CONFIGURATION, getEvcLinkIid("1"));
+        final DataObjectModification<Link> evcDataTreeObj = new DataObjectModification<Link>() {
             @Override
             public Collection<DataObjectModification<? extends DataObject>> getModifiedChildren() {
                 // TODO Auto-generated method stub
@@ -169,12 +169,11 @@ public final class DataTreeModificationHelper {
             }
         };
         DataTreeModification<Link> evcLink = new DataTreeModification<Link>() {
-            
             @Override
             public DataTreeIdentifier<Link> getRootPath() {
                 return evcDataTreeIid;
             }
-            
+
             @Override
             public DataObjectModification<Link> getRootNode() {
                 return evcDataTreeObj;
index ea452fc8b6963bd124e9ffe8dc3d346039eb1dda..c3bbe9eb9f559dd5c0347621dc6ac85ef6728612 100644 (file)
@@ -59,8 +59,8 @@ public class EvcDataTreeChangeListenerTest {
         verify(evcDataTreeChangeListener, times(1)).update(any(DataTreeModification.class));
     }
 
-    private DataTreeModification<Link> getDataTreeLink(ModificationType modificationType) {
-        DataObjectModification<Link> evcDataObjModification = new DataObjectModification<Link>() {
+    private DataTreeModification<Link> getDataTreeLink(final ModificationType modificationType) {
+        final DataObjectModification<Link> evcDataObjModification = new DataObjectModification<Link>() {
             @Override
             public Collection<DataObjectModification<? extends DataObject>> getModifiedChildren() {
                 // TODO Auto-generated method stub
index 4f98d7dcb3c02f7bbbe825d0c6d500440d6fa4a1..40bf5716afcad8bce20ce7a15b3a08567951bd03 100644 (file)
@@ -60,8 +60,8 @@ public class UniDataTreeChangeListenerTest {
         verify(uniDataTreeChangeListener, times(1)).update(any(DataTreeModification.class));
     }
 
-    private DataTreeModification<Node> getDataTreeNode(ModificationType modificationType) {
-        DataObjectModification<Node> uniDataObjModification = new DataObjectModification<Node>() {
+    private DataTreeModification<Node> getDataTreeNode(final ModificationType modificationType) {
+        final DataObjectModification<Node> uniDataObjModification = new DataObjectModification<Node>() {
             @Override
             public Collection<DataObjectModification<? extends DataObject>> getModifiedChildren() {
                 // TODO Auto-generated method stub
index f910c5e6298e563bffcdd0f62b656a728c217c81..7ffca1e2eb9b20e40f568d6d36cab9d1f25b15fe 100644 (file)
@@ -37,4 +37,4 @@ and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
     </dependency>
   </dependencies>
 
-</project>
\ No newline at end of file
+</project>
index 1acea8e2bf20cef04ba7dc4b726ac81c028ec2b5..146d80c09c47801d6742840bffbfed86eea6cf07 100644 (file)
@@ -43,7 +43,6 @@ and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
       <artifactId>framework</artifactId>
       <type>kar</type>
     </dependency>
-
     <dependency>
       <groupId>${project.groupId}</groupId>
       <artifactId>unimgr-features</artifactId>
diff --git a/pom.xml b/pom.xml
index ce292db33b5f5fae6360446579c73187544dca33..9b5ba65d2a91cc8fb3e14e20bbb294bdbb7836ba 100644 (file)
--- a/pom.xml
+++ b/pom.xml
@@ -24,15 +24,7 @@ and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
   <prerequisites>
     <maven>3.1.1</maven>
   </prerequisites>
-  <modules>
-    <module>api</module>
-    <module>impl</module>
-    <module>cli</module>
-    <module>karaf</module>
-    <module>features</module>
-    <module>artifacts</module>
-    <module>it</module>
-  </modules>
+
   <!-- DO NOT install or deploy the repo root pom as it's only needed to initiate a build -->
   <build>
     <plugins>
@@ -53,6 +45,37 @@ and is available at http://www.eclipse.org/legal/epl-v10.html INTERNAL
     </plugins>
   </build>
 
+  <profiles>
+    <profile>
+      <id>models</id>
+      <modules>
+        <module>cisco-xrmodels</module>
+        <module>edgeassure-1000</module>
+      </modules>
+      <activation><activeByDefault>true</activeByDefault></activation>
+    </profile>
+    <profile>
+      <id>main</id>
+      <modules>
+        <module>api</module>
+        <module>impl</module>
+        <module>cisco-xr-driver</module>
+        <module>cli</module>
+        <module>karaf</module>
+        <module>features</module>
+        <module>artifacts</module>
+      </modules>
+      <activation><activeByDefault>true</activeByDefault></activation>
+    </profile>
+    <profile>
+      <id>test</id>
+      <modules>
+        <module>it</module>
+      </modules>
+      <activation><activeByDefault>true</activeByDefault></activation>
+    </profile>
+  </profiles>
+
   <scm>
     <connection>scm:git:ssh://git.opendaylight.org:29418/unimgr.git</connection>
     <developerConnection>scm:git:ssh://git.opendaylight.org:29418/unimgr.git</developerConnection>
diff --git a/restclient/README.md b/restclient/README.md
new file mode 100644 (file)
index 0000000..fba79b9
--- /dev/null
@@ -0,0 +1,11 @@
+# Sample REST client files
+
+* cisco-xr-lab-device.txt - add/remove a Cisco XR NETCONF device 
+
+* msea1000.postman_collection - utilities for Microsemi NETCONF device
+
+* nrp-fcroute.txt - add / remove MEF NRP FcRoute
+
+* nrp-fcspec.txt - add / remove MEF NRP FcSpec
+
+* unimgr.txt - utilities for existing unimgr YANG model
diff --git a/restclient/cisco-xr-lab-device.txt b/restclient/cisco-xr-lab-device.txt
new file mode 100644 (file)
index 0000000..d6e5aae
--- /dev/null
@@ -0,0 +1,67 @@
+# -*- restclient -*-
+
+# Settings
+:node = asr-101
+:addr = 50.196.141.39
+:deviceusername = <username>
+"devicepassword = <password>
+:host = http://localhost:8181
+:basic-auth := (format "Basic %s" (base64-encode-string (format "%s:%s" "admin" "admin")))
+
+# Create ASR 101
+POST :host/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules
+Authorization: :basic-auth
+Content-Type: application/xml
+<module xmlns="urn:opendaylight:params:xml:ns:yang:controller:config">
+   <type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">prefix:sal-netconf-connector</type>
+   <name>:node
+   </name>
+   <address xmlns="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">:addr
+   </address>
+   <port xmlns="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">830</port>
+   <username xmlns="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">:deviceusername</username>
+   <password xmlns="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">:devicepassword</password>
+   <tcp-only xmlns="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">false</tcp-only>
+   <event-executor xmlns="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">
+     <type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:controller:netty">prefix:netty-event-executor</type>
+     <name>global-event-executor</name>
+   </event-executor>
+   <binding-registry xmlns="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">
+     <type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding">prefix:binding-broker-osgi-registry</type>
+     <name>binding-osgi-broker</name>
+   </binding-registry>
+   <dom-registry xmlns="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">
+     <type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:controller:md:sal:dom">prefix:dom-broker-osgi-registry</type>
+     <name>dom-broker</name>
+   </dom-registry>
+   <client-dispatcher xmlns="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">
+     <type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:controller:config:netconf">prefix:netconf-client-dispatcher</type>
+     <name>global-netconf-dispatcher</name>
+   </client-dispatcher>
+   <processing-executor xmlns="urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf">
+     <type xmlns:prefix="urn:opendaylight:params:xml:ns:yang:controller:threadpool">prefix:threadpool</type>
+     <name>global-netconf-processing-executor</name>
+   </processing-executor>
+ </module>
+
+# Get node operational status
+GET :host/restconf/operational/network-topology:network-topology/topology/topology-netconf/node/:node/
+Authorization: :basic-auth
+
+# Get interface configuration
+GET :host/restconf/operational/network-topology:network-topology/topology/topology-netconf/node/:node/yang-ext:mount/Cisco-IOS-XR-ifmgr-cfg:interface-configurations/
+Authorization: :basic-auth
+Accept: application/xml
+
+# Get operational l2vpn xconnect groups
+GET :host/restconf/operational/network-topology:network-topology/topology/topology-netconf/node/:node/yang-ext:mount/Cisco-IOS-XR-l2vpn-cfg:l2vpn/database/xconnect-groups/xconnect-group/local
+Authorization: :basic-auth
+Accept: application/xml
+
+# Show
+GET :host/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules/module/odl-sal-netconf-connector-cfg:sal-netconf-connector/:node
+Authorization: :basic-auth
+
+# Delete
+DELETE :host/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules/module/odl-sal-netconf-connector-cfg:sal-netconf-connector/:node
+Authorization: :basic-auth
diff --git a/restclient/msea1000.postman_collection b/restclient/msea1000.postman_collection
new file mode 100644 (file)
index 0000000..918583a
--- /dev/null
@@ -0,0 +1,307 @@
+{
+       "id": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+       "name": "Microsemi EdgeAssure 1000 UniMgr",
+       "description": "OpenDaylight RestConf calls to manipulate EdgeAssure 1000 devices connected through NETCONF",
+       "order": [
+               "7d1252ca-3d92-3bfd-9a38-3135280f6bb3",
+               "b3af7953-99e9-2a8e-1789-c02066007566"
+       ],
+       "folders": [
+               {
+                       "id": "8215fc6a-6718-fff8-610d-75211d31ef92",
+                       "name": "EdgeAssure devices",
+                       "description": "",
+                       "order": [
+                               "91b453c0-3410-8b56-f55a-a3d50a59fa2c",
+                               "779a7bdc-58fd-ab5d-df2a-183c0674f4c7",
+                               "9e1b89f0-6287-92d2-3fc2-81adbb021f96",
+                               "8a04d6ac-43c8-c484-8ff7-9f2a3a8289db",
+                               "bf5339ef-8d5c-1779-b298-d5aa7966f907",
+                               "557f3b6e-ac15-8509-e925-148849504b8b",
+                               "244fc5b0-c6dd-1d4a-a7ec-f241dd3e70ce"
+                       ],
+                       "owner": "458733",
+                       "collectionId": "c261a7e5-030d-0bc6-68bd-95aa07dcc350"
+               },
+               {
+                       "id": "edac28d2-8818-6a4d-b79f-0fa42fb8a554",
+                       "name": "UNI-EVC",
+                       "description": "",
+                       "order": [
+                               "63aef004-5886-4d88-ca0e-153b234ba8c7",
+                               "660f2350-2a2b-e7fd-b6f9-78796a807a59",
+                               "5118b3a7-6043-87fb-498e-85abeca99ced",
+                               "577d3815-db1f-6f38-4ea2-c4e44e31b736"
+                       ],
+                       "owner": "458733"
+               }
+       ],
+       "timestamp": 1461934573487,
+       "owner": "458733",
+       "remoteLink": "",
+       "public": false,
+       "requests": [
+               {
+                       "id": "244fc5b0-c6dd-1d4a-a7ec-f241dd3e70ce",
+                       "headers": "Content-Type: application/xml\nAuthorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8181/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules/module/odl-sal-netconf-connector-cfg:sal-netconf-connector/eaglesim1",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "DELETE",
+                       "data": [],
+                       "dataMode": "raw",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1456241333278,
+                       "name": "Delete NCC eaglesim1 device",
+                       "description": "",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": [],
+                       "rawModeData": "",
+                       "folder": "8215fc6a-6718-fff8-610d-75211d31ef92"
+               },
+               {
+                       "id": "5118b3a7-6043-87fb-498e-85abeca99ced",
+                       "headers": "Authorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8080/restconf/config/network-topology:network-topology/topology/topology-netconf/node/eaglesim1/yang-ext:mount/msea-uni-evc-service:mef-services/uni/msea-uni-evc-service:evc/1",
+                       "pathVariables": {},
+                       "preRequestScript": "",
+                       "method": "GET",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "data": [],
+                       "dataMode": "params",
+                       "name": "Read eaglesim1 Uni-Evc-1",
+                       "description": "",
+                       "descriptionFormat": "html",
+                       "time": 1461921227058,
+                       "version": 2,
+                       "responses": [],
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "folder": "edac28d2-8818-6a4d-b79f-0fa42fb8a554"
+               },
+               {
+                       "id": "557f3b6e-ac15-8509-e925-148849504b8b",
+                       "headers": "Content-Type: application/xml\nAuthorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8181/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules/module/odl-sal-netconf-connector-cfg:sal-netconf-connector/eaglesim1",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "PUT",
+                       "data": [],
+                       "dataMode": "raw",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1459499516809,
+                       "name": "Edit NCC eaglenid1 device",
+                       "description": "Since a PUT is a replace operation, the whole configuration must be specified along with\nthe new values for username and password. This should result in a 2xx response and\nthe instance of netconf-connector called eaglesim1 will be reconfigured to use\nusername bob and password passwd.",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": [],
+                       "rawModeData": "<module xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:config\">\n<type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">prefix:sal-netconf-connector</type>\n<name>eaglesim1</name>\n<address xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">10.205.86.52</address>\n<port xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">830</port>\n<username xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">netconf</username>\n<password xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">N3tc0nf+</password>\n<tcp-only xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">false</tcp-only>\n<event-executor xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:netty\">prefix:netty-event-executor</type>\n    <name>global-event-executor</name>\n</event-executor>\n<binding-registry xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding\">prefix:binding-broker-osgi-registry</type>\n    <name>binding-osgi-broker</name>\n</binding-registry>\n<dom-registry xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:dom\">prefix:dom-broker-osgi-registry</type>\n    <name>dom-broker</name>\n</dom-registry>\n<client-dispatcher xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:config:netconf\">prefix:netconf-client-dispatcher</type>\n    <name>global-netconf-dispatcher</name>\n</client-dispatcher>\n<processing-executor xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:threadpool\">prefix:threadpool</type>\n    <name>global-netconf-processing-executor</name>\n</processing-executor>\n<keepalive-executor xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:threadpool\">prefix:scheduled-threadpool</type>\n    <name>global-netconf-ssh-scheduled-executor</name>\n</keepalive-executor>\n</module>",
+                       "folder": "8215fc6a-6718-fff8-610d-75211d31ef92"
+               },
+               {
+                       "id": "577d3815-db1f-6f38-4ea2-c4e44e31b736",
+                       "headers": "Authorization: Basic YWRtaW46YWRtaW4=\nContent-Type: application/json\n",
+                       "url": "http://localhost:8080/restconf/config/network-topology:network-topology/topology/topology-netconf/node/eaglesim1/yang-ext:mount/msea-uni-evc-service:mef-services/uni/msea-uni-evc-service:evc/2",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "DELETE",
+                       "data": [],
+                       "dataMode": "params",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1461934503690,
+                       "name": "Delete eaglesim1 Uni-Evc-2",
+                       "description": "This can delete an EVC 2 from the List, leaving others untouched",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": [],
+                       "folder": "edac28d2-8818-6a4d-b79f-0fa42fb8a554"
+               },
+               {
+                       "id": "63aef004-5886-4d88-ca0e-153b234ba8c7",
+                       "headers": "Authorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8080/restconf/config/network-topology:network-topology/topology/topology-netconf/node/eaglesim1/yang-ext:mount/msea-uni-evc-service:mef-services/uni",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "GET",
+                       "data": [],
+                       "dataMode": "params",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1461918277179,
+                       "name": "Read eaglesim1 Uni",
+                       "description": "",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": [],
+                       "folder": "edac28d2-8818-6a4d-b79f-0fa42fb8a554"
+               },
+               {
+                       "id": "660f2350-2a2b-e7fd-b6f9-78796a807a59",
+                       "headers": "Authorization: Basic YWRtaW46YWRtaW4=\nContent-Type: application/json\n",
+                       "url": "http://localhost:8080/restconf/config/network-topology:network-topology/topology/topology-netconf/node/eaglesim1/yang-ext:mount/msea-uni-evc-service:mef-services/uni/msea-uni-evc-service:evc/2",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "PUT",
+                       "data": [],
+                       "dataMode": "raw",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1461933519340,
+                       "name": "Create eaglesim1 Uni-Evc-2",
+                       "description": "This can add an EVC 2 to the List where none existed before",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": [],
+                       "rawModeData": "{    \n    \"evc\": [\n      {\n        \"evc-index\": 2,\n        \"name\": \"evc-2\",\n        \"evc-per-uni\": {\n          \"evc-per-uni-c\": {\n            \"tag-push\": {\n              \"outer-tag-vlan\": 3,\n              \"push-tag-type\": \"pushCtag\"\n            },\n            \"ce-vlan-map\": \"10\",\n            \"ingress-bwp-group-index\": 0\n          },\n          \"evc-per-uni-n\": {\n            \"ce-vlan-map\": \"11\",\n            \"ingress-bwp-group-index\": 0\n          }\n        }\n      }\n     ]\n}",
+                       "folder": "edac28d2-8818-6a4d-b79f-0fa42fb8a554"
+               },
+               {
+                       "id": "779a7bdc-58fd-ab5d-df2a-183c0674f4c7",
+                       "headers": "Content-Type: application/xml\nAuthorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8181/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules/module/odl-sal-netconf-connector-cfg:sal-netconf-connector/eaglesim1",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "GET",
+                       "data": [],
+                       "dataMode": "params",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1456241599751,
+                       "name": "Read NCC eaglesim1 device",
+                       "description": "",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": [],
+                       "folder": "8215fc6a-6718-fff8-610d-75211d31ef92"
+               },
+               {
+                       "id": "7d1252ca-3d92-3bfd-9a38-3135280f6bb3",
+                       "headers": "Content-Type: application/xml\nAuthorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8181/restconf/operational/network-topology:network-topology/",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "GET",
+                       "data": [],
+                       "dataMode": "params",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1456232127726,
+                       "name": "List Network Topology",
+                       "description": "",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": []
+               },
+               {
+                       "id": "8a04d6ac-43c8-c484-8ff7-9f2a3a8289db",
+                       "headers": "Content-Type: application/xml\nAuthorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8181/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "POST",
+                       "data": [],
+                       "dataMode": "raw",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1459499963363,
+                       "name": "Add NCC eaglenid1 device",
+                       "description": "",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": [],
+                       "rawModeData": "<module xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:config\">\n<type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">prefix:sal-netconf-connector</type>\n<name>eaglenid1</name>\n<address xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">10.205.86.33</address>\n<port xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">830</port>\n<username xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">netconf</username>\n<password xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">netconf</password>\n<tcp-only xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">false</tcp-only>\n<event-executor xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:netty\">prefix:netty-event-executor</type>\n    <name>global-event-executor</name>\n</event-executor>\n<binding-registry xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:binding\">prefix:binding-broker-osgi-registry</type>\n    <name>binding-osgi-broker</name>\n</binding-registry>\n<dom-registry xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:dom\">prefix:dom-broker-osgi-registry</type>\n    <name>dom-broker</name>\n</dom-registry>\n<client-dispatcher xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:config:netconf\">prefix:netconf-client-dispatcher</type>\n    <name>global-netconf-dispatcher</name>\n</client-dispatcher>\n<processing-executor xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:threadpool\">prefix:threadpool</type>\n    <name>global-netconf-processing-executor</name>\n</processing-executor>\n<keepalive-executor xmlns=\"urn:opendaylight:params:xml:ns:yang:controller:md:sal:connector:netconf\">\n    <type xmlns:prefix=\"urn:opendaylight:params:xml:ns:yang:controller:threadpool\">prefix:scheduled-threadpool</type>\n    <name>global-netconf-ssh-scheduled-executor</name>\n</keepalive-executor>\n</module>",
+                       "folder": "8215fc6a-6718-fff8-610d-75211d31ef92"
+               },
+               {
+                       "id": "91b453c0-3410-8b56-f55a-a3d50a59fa2c",
+                       "headers": "Authorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8080/restconf/config/network-topology:network-topology/topology/topology-netconf/node/eaglesim1/yang-ext:mount/",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "GET",
+                       "data": [],
+                       "dataMode": "params",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1461917632024,
+                       "name": "Read eaglesim1 Config Data",
+                       "description": "",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": [],
+                       "folder": "8215fc6a-6718-fff8-610d-75211d31ef92"
+               },
+               {
+                       "id": "9e1b89f0-6287-92d2-3fc2-81adbb021f96",
+                       "headers": "Authorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8181/restconf/operations/network-topology:network-topology/topology/topology-netconf/node/eaglesim1/yang-ext:mount/",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "GET",
+                       "data": [],
+                       "dataMode": "params",
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1459775903041,
+                       "name": "Operations (RPCs) eaglenid1",
+                       "description": "",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "folder": "8215fc6a-6718-fff8-610d-75211d31ef92"
+               },
+               {
+                       "id": "b3af7953-99e9-2a8e-1789-c02066007566",
+                       "headers": "Content-Type: application/xml\nAuthorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8181/restconf/config/network-topology:network-topology/topology/topology-netconf/node/controller-config/yang-ext:mount/config:modules",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "GET",
+                       "data": [],
+                       "dataMode": "params",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1456231765910,
+                       "name": "List NCC config",
+                       "description": "",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": []
+               },
+               {
+                       "id": "bf5339ef-8d5c-1779-b298-d5aa7966f907",
+                       "headers": "Content-Type: application/xml\nAccept: application/xml\nAuthorization: Basic YWRtaW46YWRtaW4=\n",
+                       "url": "http://localhost:8181/restconf/operations/network-topology:network-topology/topology/topology-netconf/node/eaglesim1/yang-ext:mount/ietf-netconf:validate",
+                       "preRequestScript": "",
+                       "pathVariables": {},
+                       "method": "POST",
+                       "data": [],
+                       "dataMode": "raw",
+                       "version": 2,
+                       "tests": "",
+                       "currentHelper": "normal",
+                       "helperAttributes": {},
+                       "time": 1459781550642,
+                       "name": "Validate Running  eaglenid1",
+                       "description": "",
+                       "collectionId": "2dfdf5fd-670e-fa0d-aeff-ab0de376b104",
+                       "responses": [],
+                       "rawModeData": "<input xmlns=\"urn:ietf:params:xml:ns:netconf:base:1.0\">\n  <source><running/></source>\n</input>",
+                       "folder": "8215fc6a-6718-fff8-610d-75211d31ef92"
+               }
+       ]
+}
\ No newline at end of file
diff --git a/restclient/nrp-fcroute.txt b/restclient/nrp-fcroute.txt
new file mode 100644 (file)
index 0000000..a7cec96
--- /dev/null
@@ -0,0 +1,122 @@
+# -*- restclient -*-
+# Settings
+:host = http://localhost:8181
+:basic-auth := (format "Basic %s" (base64-encode-string (format "%s:%s" "admin" "admin")))
+
+# Create FcRoute
+POST :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList
+Authorization: :basic-auth
+Content-Type: application/json
+{
+   "FcRoute": {
+       "id" : "new-route",
+       "ForwardingConstruct": [
+       {
+          "uuid": "an-original-name",
+          "FcPort": [ {
+                     "id": "a-end",
+                     "_ltpRefList": [ "host-a:a-end-ltp" ]
+                     }, {
+                     "id": "z-end",
+                     "_ltpRefList": [ "host-z:z-end-ltp" ]
+                     } ],
+          "forwardingDirection": "BIDIRECTIONAL",
+          "layerProtocolName": "funky-layer-protocol",
+          "_fcSpecRef": "nonexistent-fcspec"
+       }
+   ] }
+}
+
+# Delete FcRoute
+DELETE :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList/FcRoute/new-route
+Authentication: :basic-auth
+
+# List FcRoute
+GET :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList
+Authorization: :basic-auth
+
+# Create single-host FcRoute
+POST :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList
+Authorization: :basic-auth
+Content-Type: application/json
+{
+   "FcRoute": {
+       "id" : "single-host",
+       "ForwardingConstruct": [
+       {
+          "uuid": "single-host",
+          "FcPort": [ {
+                     "id": "a-end",
+                     "_ltpRefList": [ "asr-101:GigabitEthernet0/0/1/19" ]
+                     }, {
+                     "id": "z-end",
+                     "_ltpRefList": [ "asr-101:GigabitEthernet0/0/1/17" ]
+                     } ],
+          "forwardingDirection": "BIDIRECTIONAL",
+          "layerProtocolName": "funky-layer-protocol",
+          "_fcSpecRef": "nonexistent-fcspec"
+       }
+   ] }
+}
+
+# Delete FcRoute
+DELETE :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList/FcRoute/single-host
+Authentication: :basic-auth
+
+# Create two host FcRoute
+POST :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList
+Authorization: :basic-auth
+Content-Type: application/json
+{
+   "FcRoute": {
+       "id" : "two-host-pw",
+       "ForwardingConstruct": [
+       {
+          "uuid": "two-host",
+          "FcPort": [ {
+                     "id": "a-end",
+                     "_ltpRefList": [ "asr-102:GigabitEthernet0/0/1/17" ]
+                     }, {
+                     "id": "z-end",
+                     "_ltpRefList": [ "asr-103:GigabitEthernet0/0/0/19" ]
+                     } ],
+          "forwardingDirection": "BIDIRECTIONAL",
+          "layerProtocolName": "funky-layer-protocol",
+          "_fcSpecRef": "nonexistent-fcspec"
+       },
+       {
+          "uuid": "single-host",
+          "FcPort": [ {
+                     "id": "a-end",
+                     "_ltpRefList": [ "asr-101:GigabitEthernet0/0/1/19" ]
+                     }, {
+                     "id": "z-end",
+                     "_ltpRefList": [ "asr-101:GigabitEthernet0/0/1/17" ]
+                     } ],
+          "forwardingDirection": "BIDIRECTIONAL",
+          "layerProtocolName": "funky-layer-protocol",
+          "_fcSpecRef": "nonexistent-fcspec"
+       }
+   ] }
+}
+
+# Delete FcRoute
+DELETE :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList/FcRoute/two-host-pw
+Authentication: :basic-auth
+
+# Get all FcRoute
+GET :host/restconf/config/CoreModel-CoreNetworkModule-ObjectClasses:FcRouteList/
+Authentication: :basic-auth
+
+# Get l2vpn
+:node = asr-102
+GET :host/restconf/config/network-topology:network-topology/topology/topology-netconf/node/:node/yang-ext:mount/Cisco-IOS-XR-l2vpn-cfg:l2vpn/database/xconnect-groups/
+Authorization: :basic-auth
+Accept: application/xml
+
+# Delete p2p xconnect
+:group = EUR16-two-host
+:name = EUR16-p2p-two-host
+DELETE :host/restconf/config/network-topology:network-topology/topology/topology-netconf/node/:node/yang-ext:mount/Cisco-IOS-XR-l2vpn-cfg:l2vpn/database/xconnect-groups/xconnect-group/:group/p2p-xconnects/p2p-xconnect/:name
+Authorization: :basic-auth
+Accept: application/xml
diff --git a/restclient/nrp-fcspec.txt b/restclient/nrp-fcspec.txt
new file mode 100644 (file)
index 0000000..9df8e13
--- /dev/null
@@ -0,0 +1,18 @@
+# -*- restclient -*-
+# Settings
+:host = http://localhost:8181
+:basic-auth := (format "Basic %s" (base64-encode-string (format "%s:%s" "admin" "admin")))
+
+# Create FcSoec
+POST :host/restconf/config/CoreModel-CoreModelEnhancements-ProfilesTemplatesAndSpecificationsModule:FcSpecList
+Authorization: :basic-auth
+Content-Type: application/json
+{
+   "FcSpec" : {
+      "uuid": "an-original-name"
+   }
+}
+
+# Delete FcSpec
+
+# List FcSpec
diff --git a/restclient/unimgr.txt b/restclient/unimgr.txt
new file mode 100644 (file)
index 0000000..0bd96da
--- /dev/null
@@ -0,0 +1,61 @@
+# -*- restclient -*-
+# Settings
+:host = http://localhost:8181
+:basic-auth := (format "Basic %s" (base64-encode-string (format "%s:%s" "admin" "admin")))
+
+# Modules
+GET :host/restconf/modules
+Authorization: :basic-auth
+
+# Operational Network Topology
+GET :host/restconf/operational/network-topology:network-topology/
+Authorization: :basic-auth
+Accept: application/xml
+
+# Config Network Topology
+GET :host/restconf/config/network-topology:network-topology/
+Authorization: :basic-auth
+Accept: application/xml
+
+# Delete UNI
+DELETE :host/restconf/config/network-topology:network-topology/topology/unimgr:uni/node/uni:%2F%2F192.168.2.10
+Authorization: :basic-auth
+
+# Delete ovsdb:1
+DELETE :host/restconf/config/network-topology:network-topology/topology/ovsdb:1/
+Authorization: :basic-auth
+
+# New UNI
+POST :host/restconf/config/network-topology:network-topology/topology/unimgr:uni/
+Content-type: application/json
+Authorization: :basic-auth
+{
+  "node": [
+    {
+      "node-id": "uni://192.168.2.12",
+      "cl-unimgr-mef:type": "",
+      "cl-unimgr-mef:mtu-size": 0,
+      "cl-unimgr-mef:physical-medium": "UNI TypeFull Duplex 2 Physical Interface",
+      "cl-unimgr-mef:ip-address": "192.168.2.12",
+      "cl-unimgr-mef:mode": "Full Duplex",
+      "cl-unimgr-mef:speed": {
+        "speed-1G": 1
+      },
+      "cl-unimgr-mef:mac-layer": "IEEE 802.3-2005",
+      "cl-unimgr-mef:mac-address": "68:5b:35:bb:f8:3c"
+    }
+  ]
+}
+
+# Delete UNI
+DELETE :host/restconf/config/network-topology:network-topology/topology/unimgr:uni/node/uni:%2f%2f192.168.2.12
+Authorization: :basic-auth
+
+
+# OVSDB
+GET :host/restconf/ovsdb:ovsdb/
+Authorization: :basic-auth
+
+# Cisco ASR 101
+GET :host/restconf/operational/network-topology:network-topology/topology/topology-netconf/node/asr-101
+Authorization: :basic-auth
\ No newline at end of file