Hello All, We have a akka application running in production in a non clustered mode ( doesn't akka clustering ). We are trying to dockerize this application and running into an issue. We are using docker host networking and for various other reasons we are not yet ready to use other types of networking.
Application binds to 0.0.0.0 interface on port 9080 and does a simple http healthcheck on itself. This healthcheck is failing because we are seeing a connection reset error. We are seeing this only inside docker container. During startup time application gets bound to 0:0:0:0:0:0:0:0:9080. 2018-04-13T08:29:54.921-0700 [INFO ] - Bound to /0:0:0:0:0:0:0:0:9080 Any help is appreciated. akka logs: 2018-04-13T08:34:25.311-0700 [DEBUG] akka.io.TcpListener [15:34: 25.311UTC] - New connection accepted 2018-04-13T08:34:25.312-0700 [DEBUG] akka.io.SelectionHandler [15:34: 25.312UTC] - now supervising Actor[akka: //appname/system/IO-TCP/selectors/$d/12#394551476] 2018-04-13T08:34:25.312-0700 [DEBUG] akka.io.TcpIncomingConnection [15:34: 25.312UTC] - started (akka.io.TcpIncomingConnection@1dafecc7) 2018-04-13T08:34:25.312-0700 [DEBUG] akka.io.TcpIncomingConnection [15:34: 25.312UTC] - now watched by Actor[akka: //appname/system/IO-TCP/selectors/$d#992175932] 2018-04-13T08:34:25.312-0700 [DEBUG] akka.io.TcpIncomingConnection [15:34: 25.312UTC] - now watched by Actor[akka: //appname/user/IO-HTTP/listener-0/88#-1187840999] 2018-04-13T08:34:25.313-0700 [DEBUG] akka.io.SelectionHandler [15:34: 25.313UTC] - now supervising Actor[akka: //appname/system/IO-TCP/selectors/$h/11#789402148] 2018-04-13T08:34:25.313-0700 [DEBUG] akka.io.TcpOutgoingConnection [15:34: 25.313UTC] - started (akka.io.TcpOutgoingConnection@62c77639) 2018-04-13T08:34:25.313-0700 [DEBUG] akka.io.TcpOutgoingConnection [15:34: 25.313UTC] - now watched by Actor[akka: //appname/system/IO-TCP/selectors/$h#227381172] 2018-04-13T08:34:25.313-0700 [DEBUG] akka.io.TcpOutgoingConnection [15:34: 25.313UTC] - Attempting connection to [/0.0.0.0:9080] 2018-04-13T08:34:25.313-0700 [DEBUG] akka.io.TcpListener [15:34: 25.313UTC] - New connection accepted 2018-04-13T08:34:25.313-0700 [DEBUG] akka.io.TcpOutgoingConnection [15:34: 25.313UTC] - Connection established to [/0.0.0.0:9080] 2018-04-13T08:34:25.314-0700 [DEBUG] akka.io.TcpOutgoingConnection [15:34: 25.314UTC] - now watched by Actor[akka: //appname/user/IO-HTTP/group-0/52#1518564728] 2018-04-13T08:34:25.314-0700 [DEBUG] akka.io.SelectionHandler [15:34: 25.314UTC] - now supervising Actor[akka: //appname/system/IO-TCP/selectors/$h/12#1641348988] 2018-04-13T08:34:25.314-0700 [DEBUG] akka.io.TcpIncomingConnection [15:34: 25.314UTC] - started (akka.io.TcpIncomingConnection@65bac45) 2018-04-13T08:34:25.314-0700 [DEBUG] akka.io.TcpIncomingConnection [15:34: 25.314UTC] - now watched by Actor[akka: //appname/system/IO-TCP/selectors/$h#227381172] 2018-04-13T08:34:26.327-0700 [DEBUG] akka.io.TcpIncomingConnection [15:34: 26.327UTC] - now watched by Actor[akka: //appname/user/IO-HTTP/listener-0/89#-1079090421] 2018-04-13T08:34:26.327-0700 [DEBUG] akka.io.TcpIncomingConnection [15:34: 26.327UTC] - stopped 2018-04-13T08:34:26.327-0700 [DEBUG] akka.io.TcpOutgoingConnection [15:34: 26.327UTC] - Closing connection due to IO error java.io.IOException: Connection reset by peer 2018-04-13T08:34:26.327-0700 [DEBUG] akka.io.TcpOutgoingConnection [15:34: 26.327UTC] - stopped 2018-04-13T08:34:26.328-0700 [DEBUG] akka.io.TcpIncomingConnection [15:34: 26.328UTC] - stopped Spray logs: 2018-04-13T08:35:39.168-0700 - Dispatching GET request to http://10.4.4.178:9080/admin/health to handler Actor[akka://appname/system/IO-TCP/selectors/$b/20#-595408603] 2018-04-13T08:35:45.296-0700 - Dispatching GET request to http://10.4.4.178:9080/admin/health to handler Actor[akka://appname/system/IO-TCP/selectors/$d/19#721242322] 2018-04-13T08:35:51.372-0700 - Dispatching GET request to http://10.4.4.178:9080/admin/health to handler Actor[akka://appname/system/IO-TCP/selectors/$c/16#1510321611] 2018-04-13T08:35:57.436-0700 - Dispatching GET request to http://10.4.4.178:9080/admin/health to handler Actor[akka://appname/system/IO-TCP/selectors/$g/22#1994752981] 2018-04-13T08:36:03.622-0700 - Dispatching GET request to http://10.4.4.178:9080/admin/health to handler Actor[akka://appname/system/IO-TCP/selectors/$f/20#-1450294853] Healthcheck logs: 2018-04-13T08:32:53.356-0700 [INFO ] - [BEGIN] Health check 2018-04-13T08:32:53.356-0700 [DEBUG] - Memory : SUCCESS 2018-04-13T08:32:54.378-0700 [DEBUG] - HTTP : FAILURE, spray.can. Http$ConnectionException: ErrorClosed(Connection reset by peer) 2018-04-13T08:32:54.378-0700 [ERROR] - spray.can.Http$ConnectionException: ErrorClosed(Connection reset by peer) at spray.can.client.HttpHostConnectionSlot.reportDisconnection( HttpHostConnectionSlot.scala:228) at spray.can.client.HttpHostConnectionSlot$$anonfun$connected$1.applyOrElse (HttpHostConnectionSlot.scala:161) at akka.actor.Actor$class.aroundReceive(Actor.scala:465) at spray.can.client.HttpHostConnectionSlot.aroundReceive( HttpHostConnectionSlot.scala:33) at akka.actor.ActorCell.receiveMessage(ActorCell.scala:516) at akka.actor.ActorCell.invoke_aroundBody0(ActorCell.scala:487) at akka.actor.ActorCell$AjcClosure1.run(ActorCell.scala:1) at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149 ) at akka.instrumentation.ActorCellInstrumentation.aroundBehaviourInvoke( ActorCellInstrumentation.scala:66) at akka.actor.ActorCell.invoke(ActorCell.scala:483) at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:238) at akka.dispatch.Mailbox.run(Mailbox.scala:220) at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec( AbstractDispatcher.scala:393) at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260) at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool. java:1339) at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979) at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread. java:107) 2018-04-13T08:32:54.378-0700 [INFO ] - [END ] Status: Failed (1022 ms) Versions: akka - 2.3.0 spray - 1.3.2 running on alpine linux inside a docker container. Any pointers would help. Thanks in advance. -- ***************************************************************************************************** ** New discussion forum: https://discuss.akka.io/ replacing akka-user google-group soon. ** This group will soon be put into read-only mode, and replaced by discuss.akka.io ** More details: https://akka.io/blog/news/2018/03/13/discuss.akka.io-announced ***************************************************************************************************** >>>>>>>>>> >>>>>>>>>> Read the docs: http://akka.io/docs/ >>>>>>>>>> Check the FAQ: >>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user --- You received this message because you are subscribed to the Google Groups "Akka User List" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/akka-user. For more options, visit https://groups.google.com/d/optout.
