added a wait so that controller's signal handler waits for the jvm to ex...

...it after forwarding the signal. Josh, can you check if this approach is as per your original design?