RE: SparkLauncher not notified about finished job - hangs infinitely.

2015-08-03 Thread Tomasz GuziaƂek
; user@spark.apache.org Subject: Re: SparkLauncher not notified about finished job - hangs infinitely. Tomasz: Please take a look at the Redirector class inside: ./launcher/src/test/java/org/apache/spark/launcher/SparkLauncherSuite.java FYI On Fri, Jul 31, 2015 at 10:02 AM, Elkhan Dadashov elkhan8

Re: SparkLauncher not notified about finished job - hangs infinitely.

2015-07-31 Thread Elkhan Dadashov
Nope, output stream of that subprocess should be spark.getInputStream() According to Oracle Doc https://docs.oracle.com/javase/8/docs/api/java/lang/Process.html#getOutputStream-- : public abstract InputStream https://docs.oracle.com/javase/8/docs/api/java/io/InputStream.html getInputStream()

Re: SparkLauncher not notified about finished job - hangs infinitely.

2015-07-31 Thread Elkhan Dadashov
Hi Tomasz, *Answer to your 1st question*: Clear/read the error (spark.getErrorStream()) and output (spark.getInputStream()) stream buffers before you call spark.waitFor(), it would be better to clear/read them with 2 different threads. Then it should work fine. As Spark job is launched as

Re: SparkLauncher not notified about finished job - hangs infinitely.

2015-07-31 Thread Ted Yu
Tomasz: Please take a look at the Redirector class inside: ./launcher/src/test/java/org/apache/spark/launcher/SparkLauncherSuite.java FYI On Fri, Jul 31, 2015 at 10:02 AM, Elkhan Dadashov elkhan8...@gmail.com wrote: Hi Tomasz, *Answer to your 1st question*: Clear/read the error