}
override readFlow(FlowKey key) {
- val flowCfg = manager.getStaticFlow(key.id,key.node.toADNode());
+ val flowCfg = manager.getStaticFlow(String.valueOf(key.id), key.node.toADNode());
return flowCfg.toConfigurationFlow;
}
}
idleTimeout = source.idleTimeout
match = source.match
node = source.node
- key = new FlowKey(sourceCfg.name,node);
+ key = new FlowKey(Long.parseLong(sourceCfg.name),node);
return it.build();
}
static def toFlowConfig(Flow sourceCfg) {
val flow = toFlow(sourceCfg);
val it = new FlowConfig;
- name = sourceCfg.key.id
+ name = String.valueOf(sourceCfg.id);
node = sourceCfg.node.toADNode();
return it
static def toFlowConfig(InstanceIdentifier<?> identifier) {
val it = new FlowConfig()
val FlowKey key = ((identifier.path.get(2) as IdentifiableItem<Flow,FlowKey>).key)
- name = key.id;
+ name = String.valueOf(key.id);
node = key.node.toADNode();
return it;
Flow createSampleFlow(String name, NodeRef node) {
FlowBuilder ret = new FlowBuilder();
- FlowKey key = new FlowKey(name, node);
+ FlowKey key = new FlowKey(Long.parseLong(name), node);
ret.setKey(key);
return ret.build();
}
revision "2013-09-25" {
description "Initial revision of Port Inventory model";
}
-
+
+ typedef port-reason {
+ type enumeration {
+ enum add;
+ enum delete;
+ enum update;
+ }
+ }
typedef port-config {
type bits {
enum live;
}
}
-
typedef port-features {
type bits {
}
}
+ grouping flow-port-status {
+ leaf reason {
+ type port-reason;
+ }
+
+ uses flow-capable-port;
+ }
+
grouping flow-capable-port {
uses common-port;
}
}
- grouping ofp-port-mod {
+ grouping port-mod {
container port {
list port {
key "port-mod-order";
key "node id";
leaf id {
- type string;
+ type uint32;
}
uses flow:flow-entry;
}
key "id node";
leaf id {
- type string;
+ type uint32;
}
uses group-entry;
key "id node";
leaf id {
- type string;
+ type uint32;
}
uses meter-entry;
leaf node {
type inv:node-ref;
}
- uses port:ofp-port-mod;
+ uses port:port-mod;
}
container ports {
key "id node";
leaf id {
- type string;
+ type uint32;
}
uses port-entry;
key "id node";
leaf id {
- type string;
+ type uint32;
}
uses table-entry;
enum flow-mod-failed;
enum group-mod-failed;
enum port-mod-failed;
- enum table-mod-failed;
- enum meter-mod-failed;
+ enum table-mod-failed;
enum queue-op-failed;
enum switch-config-failed;
enum role-request-failed;
+ enum meter-mod-failed;
enum table-features-failed;
- enum experimenter;
+ enum experimenter {
+ value "65535";
+ }
}
}
notification node-error-notification {
uses error:error-message;
+ uses tr:transaction-aware;
}
notification node-experimenter-error-notification {
uses error:experimenter-error-message;
+ uses tr:transaction-aware;
}
}
\ No newline at end of file
grouping node-port {
uses "inv:node-context-ref";
- uses port-type:ofp-port-mod;
+ uses port-type:flow-port-status;
}
/** Base configuration structure **/
uses "inv:node-context-ref";
container original-port {
- uses port-type:ofp-port-mod;
+ uses port-type:port-mod;
}
container updated-port {
- uses port-type:ofp-port-mod;
+ uses port-type:port-mod;
}
}
private static final QName FLOW_ID_QNAME = QName.create(Flow.QNAME, "id");
private static final QName FLOW_NODE_QNAME = QName.create(Flow.QNAME, "node");
- private static final String FLOW_ID = "foo";
+ private static final long FLOW_ID = 1234;
private static final String NODE_ID = "node:1";
private static final NodeKey NODE_KEY = new NodeKey(new NodeId(NODE_ID));