opendaylight:从 java 应用程序获取流量统计信息失败
opendaylight : getting flow statistics from a java applicaton fails
我正在尝试从 java opendaylight 应用程序(运行 作为 karaf 功能)读取流量统计信息。
我在我的 Java 应用程序中看到以下异常(运行ning 作为 opendaylight 功能):
java.util.concurrent.ExecutionException: org.opendaylight.controller.md.sal.dom.api.DOMRpcImplementationNotAvailableException:
No implementation of RPC AbsoluteSchemaPath{path=[(urn:opendaylight:flow:statistics?revision=2013-08-19)get-aggregate-flow-statistics-from-flow-table-for-given-match]} available
我的容器中安装了以下功能:
karaf> feature:list | grep openflow
odl-openflowplugin-app-forwardingrules-manager | 0.5.1 | | Started | odl-openflowplugin-app-forwardingrules-manager | OpenDaylight :: Openflow Plugin :: Application -
odl-openflowplugin-nxm-extensions | 0.5.1 | | Started | odl-openflowplugin-nxm-extensions | OpenDaylight :: Openflow Plugin :: Nicira Extensi
odl-openflowplugin-nsf-model | 0.5.1 | | Started | odl-openflowplugin-nsf-model | OpenDaylight :: OpenflowPlugin :: NSF :: Model
odl-openflowplugin-app-config-pusher | 0.5.1 | | Started | odl-openflowplugin-app-config-pusher | OpenDaylight :: Openflow Plugin :: Application -
odl-openflowplugin-southbound | 0.5.1 | | Started | openflowplugin-0.5.1 | OpenDaylight :: Openflow Plugin :: Li southbound
odl-openflowjava-protocol | 0.5.1 | | Started | odl-openflowjava-0.5.1 | ODL :: o openflowjava :: odl-openflowjava-protocol
odl-openflowplugin-app-topology | 0.5.1 | | Started | odl-openflowplugin-app-topology | OpenDaylight :: Openflow Plugin :: Application -
odl-openflowplugin-flow-services | 0.5.1 | | Started | odl-openflowplugin-flow-services | OpenDaylight :: Openflow Plugin :: Flow Services
odl-openflowplugin-app-reconciliation-framework | 0.5.1 | | Started | odl-openflowplugin-app-reconciliation-framework | OpenDaylight :: Openflow Plugin :: Application -
当我发出以下 REST RPC 调用时,在 opendaylight 中调用了什么服务?
curl -v -u admin:admin -X GET http://localhost:8181/restconf/operational/opendaylight-inventory:nodes/node/openflow:1/table/0
我的目标是从 opendaylight java 应用程序(运行ning 作为容器中的一项服务)做同样的事情,但我不知道该怎么做。
不确定我是否采用了正确的方法。
谢谢,Ranga
找出答案(ODL 的氮释放)。异常中的错误消息令人困惑。方法如下:
在下面的代码片段中,节点的类型是 InstanceIdentifier
InstanceIdentifier outNode = node.firstIdentifierOf(Node.class);
NodeRef nodeRef = new NodeRef(outNode);
GetFlowStatisticsInputBuilder inputBuilder = new GetFlowStatisticsInputBuilder();
inputBuilder.setFlowName(flow.getFlowName());
inputBuilder.setMatch(flow.getMatch());
inputBuilder.setTableId(flow.getTableId());
inputBuilder.setInstructions(flow.getInstructions());
inputBuilder.setNode(nodeRef);
GetFlowStatisticsOutput output = directStatisticsService
.getFlowStatistics(inputBuilder.build()).get().getResult();
希望这对某人有所帮助。
我正在尝试从 java opendaylight 应用程序(运行 作为 karaf 功能)读取流量统计信息。
我在我的 Java 应用程序中看到以下异常(运行ning 作为 opendaylight 功能):
java.util.concurrent.ExecutionException: org.opendaylight.controller.md.sal.dom.api.DOMRpcImplementationNotAvailableException:
No implementation of RPC AbsoluteSchemaPath{path=[(urn:opendaylight:flow:statistics?revision=2013-08-19)get-aggregate-flow-statistics-from-flow-table-for-given-match]} available
我的容器中安装了以下功能:
karaf> feature:list | grep openflow
odl-openflowplugin-app-forwardingrules-manager | 0.5.1 | | Started | odl-openflowplugin-app-forwardingrules-manager | OpenDaylight :: Openflow Plugin :: Application -
odl-openflowplugin-nxm-extensions | 0.5.1 | | Started | odl-openflowplugin-nxm-extensions | OpenDaylight :: Openflow Plugin :: Nicira Extensi
odl-openflowplugin-nsf-model | 0.5.1 | | Started | odl-openflowplugin-nsf-model | OpenDaylight :: OpenflowPlugin :: NSF :: Model
odl-openflowplugin-app-config-pusher | 0.5.1 | | Started | odl-openflowplugin-app-config-pusher | OpenDaylight :: Openflow Plugin :: Application -
odl-openflowplugin-southbound | 0.5.1 | | Started | openflowplugin-0.5.1 | OpenDaylight :: Openflow Plugin :: Li southbound
odl-openflowjava-protocol | 0.5.1 | | Started | odl-openflowjava-0.5.1 | ODL :: o openflowjava :: odl-openflowjava-protocol
odl-openflowplugin-app-topology | 0.5.1 | | Started | odl-openflowplugin-app-topology | OpenDaylight :: Openflow Plugin :: Application -
odl-openflowplugin-flow-services | 0.5.1 | | Started | odl-openflowplugin-flow-services | OpenDaylight :: Openflow Plugin :: Flow Services
odl-openflowplugin-app-reconciliation-framework | 0.5.1 | | Started | odl-openflowplugin-app-reconciliation-framework | OpenDaylight :: Openflow Plugin :: Application -
当我发出以下 REST RPC 调用时,在 opendaylight 中调用了什么服务?
curl -v -u admin:admin -X GET http://localhost:8181/restconf/operational/opendaylight-inventory:nodes/node/openflow:1/table/0
我的目标是从 opendaylight java 应用程序(运行ning 作为容器中的一项服务)做同样的事情,但我不知道该怎么做。
不确定我是否采用了正确的方法。
谢谢,Ranga
找出答案(ODL 的氮释放)。异常中的错误消息令人困惑。方法如下:
在下面的代码片段中,节点的类型是 InstanceIdentifier
InstanceIdentifier outNode = node.firstIdentifierOf(Node.class); NodeRef nodeRef = new NodeRef(outNode);
GetFlowStatisticsInputBuilder inputBuilder = new GetFlowStatisticsInputBuilder();
inputBuilder.setFlowName(flow.getFlowName());
inputBuilder.setMatch(flow.getMatch());
inputBuilder.setTableId(flow.getTableId());
inputBuilder.setInstructions(flow.getInstructions());
inputBuilder.setNode(nodeRef);
GetFlowStatisticsOutput output = directStatisticsService
.getFlowStatistics(inputBuilder.build()).get().getResult();
希望这对某人有所帮助。