Unhandled exception should not strand runner in STARTING state.
authorSanthosh Kumar Shanmugham <santhoshkumar.s@gmail.com>
Wed, 18 Jul 2018 22:23:27 +0000 (15:23 -0700)
committerSanthosh Kumar <sshanmugham@twitter.com>
Wed, 18 Jul 2018 22:23:27 +0000 (15:23 -0700)
commitf054e9b1095a7ecacbbc2fa72ce0a842a3297859
treeff71611ac49cd4b9234aeaad7cccd73092e5eef5
parentefe8656512373389771aff88c2141940f925ad58
Unhandled exception should not strand runner in STARTING state.

If the ThermoTaskRunner encounters an Exception when trying to
fork the process, it bubbles this up to the Executor which does
not handle execptions other than TaskError. This leads to the
executor leaving the task in STARTING state and we end up with
tasks that get stranded in this state.

Fix it so that any unknown expection that is thrown when starting
a runner leads to task failure and get marked as FAILED.

Testing Done:
./gradlew test
./pants test src/test/python/apache::

Reviewed at https://reviews.apache.org/r/67967/
src/main/python/apache/aurora/executor/aurora_executor.py
src/test/python/apache/aurora/executor/test_thermos_executor.py