Spring integration 如何在Spring集成中处理TCP超时?
我有一个使用spring集成的spring引导应用程序。我必须在我的项目中测试超时情况。因此,我将so超时设置为1 在该项目中,我定义了一个TCP连接工厂,如下所示:Spring integration 如何在Spring集成中处理TCP超时?,spring-integration,Spring Integration,我有一个使用spring集成的spring引导应用程序。我必须在我的项目中测试超时情况。因此,我将so超时设置为1 在该项目中,我定义了一个TCP连接工厂,如下所示: <int-ip:tcp-connection-factory id="tcpClientFactory" type="client" host="hos
<int-ip:tcp-connection-factory id="tcpClientFactory"
type="client"
host="host"
port="port"
so-timeout="1"
so-keep-alive="true"
single-use="false"
lookup-host="false"
serializer="messageSerializer"
deserializer="messageSerializer"/>
但我不知道如何使用Spring集成处理超时情况。当超时发生时,我如何处理它?若主机在超时范围内不返回消息,我如何处理它
messageserializer通过Spring Integration Framework中的ArrayLength HeaderSerializer进行扩展。仅显示连接工厂是不够的-您需要显示正在使用它的适配器或网关。