Fix some Java gateway errors and inconsistencies
Delay for 3 seconds while restart the Java gateway
Add support for proxy host selection at agent registration time
Update docs, fix java agent init bug and make trappers count configurable