Added dynamic ports for the servers.
Added reconnection code to workers.
Split server into upload/distribution servers.
Merge pull request #38 from filinep/master

Stability fixes