-
1. Re: BindingoperationInfo error while routing from one webservice to another
mlabrot Mar 15, 2011 4:09 PM (in response to tjain2011)You may need to set CxfConstants.OPERATION_NAMESPACE and CxfConstants.OPERATION_NAME thusly:
from("somewhere")
.setHeader(CxfConstants.OPERATION_NAMESPACE).constant(myNamespace)
.setHeader(CxfConstants.OPERATION_NAME).constant(myOperation)
.to("cxf://http://myremoteserver...")
-
2. Re: BindingoperationInfo error while routing from one webservice to another
tjain2011 Mar 15, 2011 4:24 PM (in response to mlabrot)That did not work.
still the same exception
java.lang.IllegalArgumentException: BindingOperationInfo must be specified
here it is what i am doing... take a look
from("cxf:bean:releasePOEndpoint").handleFault()
.to("log:incoming?showAll=true")
.process(new Processor() {
public void process(Exchange exchange) throws Exception {
logger.info(" cxf:bean:releasePOEndpoint processing exchange in camel");
BindingOperationInfo boi = (BindingOperationInfo) exchange.getProperty(BindingOperationInfo.class.toString());
if (boi != null) {
logger.info("boi.isUnwrapped" + boi.isUnwrapped());
}
if (exchange != null){
Message in = exchange.getIn();
logger.info("#####Exchange headers"+in.getHeaders().toString());
logger.info("#####Exchange body"+in.getBody().toString());
Object[] msgList = exchange.getIn().getBody(Object[].class);
ReleasePurchaseOrderRequestType poRequest = (ReleasePurchaseOrderRequestType)msgList[0];
logger.info("#####purchase OrderID"+ poRequest.getPurchaseOrderId());
exchange.getOut().setBody(in.getBody());
}
}
})
.setHeader(CxfConstants.OPERATION_NAMESPACE).constant("http://company.com/pehz/wsdl/purchase_order_service.v1_0")
.setHeader(CxfConstants.OPERATION_NAME).constant("releasePurchaseOrder")
.to("cxf:bean:PurchaseOrderLifeEndpoint?defaultOperationName=releasePurchaseOrder&dataFormat=POJO")