Apache camel 同一应用程序中的CXFRS和CXF终结点冲突
我有一个应用程序,在Camel上下文中,我为发布RESTAPI定义了一个CXFRS端点。驼峰路线的一个片段:Apache camel 同一应用程序中的CXFRS和CXF终结点冲突,apache-camel,cxf,cxfrs,Apache Camel,Cxf,Cxfrs,我有一个应用程序,在Camel上下文中,我为发布RESTAPI定义了一个CXFRS端点。驼峰路线的一个片段: from("cxfrs:http://localhost:18080?resourceClasses=com.example.RestService&bindingStyle=SimpleConsumer&providers=#jsonProvider") .toD("direct:${header.operationName}"); 我
from("cxfrs:http://localhost:18080?resourceClasses=com.example.RestService&bindingStyle=SimpleConsumer&providers=#jsonProvider")
.toD("direct:${header.operationName}");
我还需要发布一个单独的SOAP服务(但托管在同一个应用程序中)。CXF端点的bean定义是:
<!-- setting up a Camel CXF web-service -->
<cxf:cxfEndpoint id="orderEndpoint"
address="http://localhost:9000/order/"
serviceClass="camelinaction.order.OrderEndpoint"
wsdlURL="wsdl/order.wsdl">
</cxf:cxfEndpoint>
当同时加载这两个应用程序时,SOAP服务将工作,而REST服务将不工作。端口18080处的连接被拒绝。这可以通过删除SOAP服务的端点来解决。我怀疑通过连接两个端点,SOAP端点正在覆盖REST端点所需的默认值。是否有需要手动配置的内容,以便在同一上下文中使用CXF和CXFRS