DEV-91: more robust java process handling