在ws:outbound-gateway中处理404错误

时间:2017-06-18 14:34:47

标签: java web-services spring-integration

是否可以使用Spring集成4.3.5在ws:outbound-gateway am中处理404错误 错误如下,

  

[org.springframework.jms.listener.DefaultMessageListenerContainer](jmsIn.container-1)JMS消息侦听器的执行失败,并且未设置ErrorHandler:org.springframework.messaging.MessageHandlingException:消息处理程序中发生错误[ org.springframework.integration.ws.MarshallingWebServiceOutboundGateway#0];嵌套异常是org.springframework.ws.client.WebServiceTransportException:未找到[404]

1 个答案:

答案 0 :(得分:0)

向网关添加ExpressionEvaluatingRequestHandlerAdvice;它允许您处理错误,抛出不同的异常,或返回其他一些回复。

请参阅here for a general discussion about adding advices to endpoints