[erlang-questions] tcp keepalive option

AndrewJStone stondage123@REDACTED
Tue Dec 30 17:47:23 CET 2008


So,
Once again I have to answer my own question...

In case anyone is curious the answer is that when a TCP keepalive
timeout occurs you get a tcp_error message with Reason "etimedout"

-Andrew

On Dec 25, 3:18 am, Andrew Stone <stondage...@REDACTED> wrote:
> Hi,
>
> I'm currently trying to test code that sets the sockopt {keepalive, true} along with {active, true} in gen_tcp:listen, which is inherited by the connected socket. However, after much searching I am unable to figure out what happens when the actual connection times out.
>
> If a TCP keepalive timeout occurs, does the erlang process receive a {tcp_error, Sock, Reason} message or does it receive a {tcp_closed, Sock} message.
>
> Thanks,
> Andrew
>
> _______________________________________________
> erlang-questions mailing list
> erlang-questi...@REDACTED://www.erlang.org/mailman/listinfo/erlang-questions



More information about the erlang-questions mailing list