Broken pipe (Java, Apache Mina)

1k Views Asked by At

I have a problem using Apache Mina with flash (client/server game).

When user closes his browser process via task manager (or Flash player in IDE), server throws infinitely exceptions "Java.io.BrokenPipe".

Changing O/S TCP/IP settings (keep-alive) didn't work.

2

There are 2 best solutions below

0
On

The server is repeatedly try to write to the socket and ignoring the broken pipe exception. It should close its end of the socket in response to the exception.

0
On

when you receive the broken pipe exception in your IoHandler, you need to close the session. The remote peer connection is dead.