Overhaul of start.sh script to be a bit more robust

The rewritten script gives each java application a bit more time to launch before giving up and exiting, and also implements a slightly better check (netcat) as to whether the application is actually accepting connections on the expected port.