trifork / erjang

A JVM-based Erlang VM
http://www.erjang.org
Apache License 2.0
726 stars 62 forks source link

Asych client connect timeout? #30

Open krestenkrab opened 14 years ago

krestenkrab commented 14 years ago

This shoudl not happen, as all out Sockets are created in non-blocking mode. Figure out why Java thinks it's a blockling connect -- which may cause time out exception. Non-blocking connect requests should fail by returning false.

unknown exception: java.net.ConnectException: Operation timed out
java.net.ConnectException: Operation timed out
at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:574)
at erjang.net.InetClientSocket.finishConnect(InetClientSocket.java:113)
at erjang.net.LazyInetSocket.finishConnect(LazyInetSocket.java:158)
at erjang.driver.tcp_inet.TCPINet.readyConnect(TCPINet.java:1364)
at erjang.driver.LockingDriverInstance.readyConnect(LockingDriverInstance.java:194)
at erjang.driver.EDriverTask$3.execute(EDriverTask.java:642)
at erjang.driver.EDriverTask.main_loop(EDriverTask.java:459)