Find the first available port if setPort(0)

on continuous integration server, they are many jobs they launch Spark servers ... we want to find a random available port to launch new server.