调用soap / rest服务时,我们正面临java.lang.StackOverflowError。 问题是没有看到任何下游异常/错误,而是看到日志中的紧密连接,然后收到stackoverflow错误。
DEBUG testDmlcContainer-1 org.apache.http.impl.conn.DefaultManagedHttpClientConnection:79 - http-outgoing-17:关闭连接 2017-01-25 00:50:15,861 DEBUG testDmlcContainer-1 org.springframework.integration.gateway.GatewayProxyFactoryBean $ MethodInvocationGateway:339 - 网关sendAndReceive发生故障:;嵌套异常是java.lang.IllegalStateException:无法处理消息 2017-01-25 00:50:15,862 DEBUG provDmlcContainer-1 org.springframework.integration.channel.DirectChannel:277 - preSend on channel'testErrorChannel',message:ErrorMessage [payload = org.springframework.messaging.MessageHandlingException :;嵌套异常是java.lang.IllegalState 例外:无法处理消息,
下面的部分在递归中被调用,导致stackoverflow
org.springframework.integration.handler.AbstractMessageHandler.handleMessage(AbstractMessageHandler.java:78) 在org.springframework.integration.dispatcher.AbstractDispatcher.tryOptimizedDispatch(AbstractDispatcher.java:116) 在org.springframework.integration.dispatcher.UnicastingDispatcher.doDispatch(UnicastingDispatcher.java:101) 在org.springframework.integration.dispatcher.UnicastingDispatcher.dispatch(UnicastingDispatcher.java:97) 在org.springframework.integration.channel.AbstractSubscribableChannel.doSend(AbstractSubscribableChannel.java:77) 在org.springframework.integration.channel.AbstractMessageChannel.send(AbstractMessageChannel.java:286) 在org.springframework.integration.channel.AbstractMessageChannel.send(AbstractMessageChannel.java:245) 在org.springframework.messaging.core.GenericMessagingTemplate.doSend(GenericMessagingTemplate.java:115) 在org.springframework.messaging.core.GenericMessagingTemplate.doSend(GenericMessagingTemplate.java:45) 在org.springframework.messaging.core.AbstractMessageSendingTemplate.send(AbstractMessageSendingTemplate.java:95) 在org.springframework.integration.handler.AbstractMessageProducingHandler.sendOutput(AbstractMessageProducingHandler.java:231) 在org.springframework.integration.handler.AbstractMessageProducingHandler.produceOutput(AbstractMessageProducingHandler.java:154) 在org.springframework.integration.handler.AbstractMessageProducingHandler.sendOutputs(AbstractMessageProducingHandler.java:102) at org.springframework.integration.handler.AbstractReplyProducingMessageHandler.handleMessageInternal(AbstractReplyProducingMessageHan) dler.java:105)