camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jaishankar <jayashankar....@wipro.com>
Subject Re: Handle SOAP fault message
Date Tue, 29 Jul 2014 08:06:26 GMT
Hi arnaudeprez,
I'm not able to catch in catch block of code.
I dont know how to implement with other two methods.
*Here is my code*
private void invokeTransactionBegin(Exchange exchange)   {
				if (exchange == null) {
					return;
				}
				ProducerTemplate producerTemplate =
exchange.getContext().createProducerTemplate();
				OperationContext operationContext = new OperationContext();
				operationContext.set..
				exchange.getIn().setHeader(CxfConstants.OPERATION_NAMESPACE,"---");
				exchange.getIn().setHeader(CxfConstants.OPERATION_NAME, "begin");
				exchange.getIn().setBody(operationContext);
				try {
					producerTemplate.start();
				} catch (Exception e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}
				try {
					Exchange exchangenew =
producerTemplate.send("cxf:bean:TransactionBegin", exchange);
					 
					MessageContentsList contents =
exchangenew.getOut().getBody(MessageContentsList.class);
 
					LOG.info("transactionID  " + contents.get(0));
				} catch (Exception exception) {
					LOG.info("Handle Soap fault " + exception.getMessage());
				} 
				try {
					producerTemplate.stop();
				} catch (Exception e) {				
					LOG.info("Exception " + e.getMessage());
				}				 
			}

In the exchangenew I'm getting Soapfault response and its not catching in
catch block of code. 
Please look into the code and give me response ASAP.



--
View this message in context: http://camel.465427.n5.nabble.com/Handle-SOAP-fault-message-tp5754549p5754563.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Mime
View raw message