[ https://issues.apache.org/jira/browse/PIO-120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16157787#comment-16157787 ]
ASF GitHub Bot commented on PIO-120: ------------------------------------ GitHub user mars opened a pull request: https://github.com/apache/incubator-predictionio/pull/432 [PIO-120] Process hangs if Elasticsearch is not available during train Fixes [PIO-120](https://issues.apache.org/jira/browse/PIO-120) This changeset ensures that the process exits gracefully after ES connection error. You can merge this pull request into a Git repository by running: $ git pull https://github.com/mars/incubator-predictionio fix-es-hang-on-train Alternatively you can review and apply these changes as the patch at: https://github.com/apache/incubator-predictionio/pull/432.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #432 ---- commit f1c7337e246c9bd2bed5cc080efcf3dc81e4b055 Author: Mars Hall <m...@heroku.com> Date: 2017-09-07T21:38:46Z Graceful exit after ES connection error during train. ---- > Process hangs if Elasticsearch is not available during train > ------------------------------------------------------------ > > Key: PIO-120 > URL: https://issues.apache.org/jira/browse/PIO-120 > Project: PredictionIO > Issue Type: Bug > Components: Core > Affects Versions: 0.12.0-incubating > Reporter: Mars Hall > Assignee: Mars Hall > > I noticed that, when Elasticsearch is configured as meta storage, `pio train` > will hang with the following error unless Elasticsearch is on-line/available: > {code} > Exception in thread "main" java.net.ConnectException: Connection refused > at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) > at > sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:717) > at > org.apache.predictionio.shaded.org.apache.http.impl.nio.reactor.DefaultConnectingIOReactor.processEvent(DefaultConnectingIOReactor.java:171) > at > org.apache.predictionio.shaded.org.apache.http.impl.nio.reactor.DefaultConnectingIOReactor.processEvents(DefaultConnectingIOReactor.java:145) > at > org.apache.predictionio.shaded.org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor.execute(AbstractMultiworkerIOReactor.java:348) > at > org.apache.predictionio.shaded.org.apache.http.impl.nio.conn.PoolingNHttpClientConnectionManager.execute(PoolingNHttpClientConnectionManager.java:192) > at > org.apache.predictionio.shaded.org.apache.http.impl.nio.client.CloseableHttpAsyncClientBase$1.run(CloseableHttpAsyncClientBase.java:64) > at java.lang.Thread.run(Thread.java:745) > {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)