java - Is a TCP inbound gateway automatically closed by Spring? -


i'm using spring tcp-inbound-gateway listen socket connections on server side.

i wonder if socket connection automatically closed after response end client? not find in spring docu: http://docs.spring.io/spring-integration/reference/htmlsingle/#ip-endpoint-reference

<ip:tcp-inbound-gateway id="gateway"     connection-factory="factory"     request-channel="channel" /> 

further question: how can specify timeout socket connection should kept alive? , close socket if response not send client within time interval?

set single-use="true" on connectionfactory , close socket after sending reply.

use so-timeout set timeout socket option , socket closed after inactivity. see reply-timeout on inbound gateway.

see configuration section of reference manual attributes , meaning.


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -