bitbake: process: Further improve robustness against server shutdown
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 21 Aug 2014 09:27:10 +0000 (10:27 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sat, 23 Aug 2014 08:31:42 +0000 (09:31 +0100)
commitcdc29989070713f50fa0df92c125728d1fe373c3
tree0423493eca7307338eceff3ec199757c951082d6
parent6067f27c236c1b589615dd8d99d7d65934395382
bitbake: process: Further improve robustness against server shutdown

Currently, if an exception occurs in an event handler, the server shuts
down but the UI simply hangs. This happens in two places, firstly waiting
for events and secondly, sending events to a server which no longer exists.

The latter does time out, the former does not. These patches improve
both code sections to check if the main server process is alive and if not,
trigger things to shut down gracefully. This avoids the timeout in the
command sending case too.

This resolves various cases where the UI would simply hang indefintely.

(Bitbake rev: ac418e1112ff5f9c3157569316902f7a27fba4b4)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
bitbake/lib/bb/server/process.py