QPID-6111: [Java Broker] Ensure that when the REF is shutdown sufficient time is allowed - bug fix used Math.min rather than Math.max.

Also:
* reduced the default envSetupTimeout from 15mins to 3mins.
* log a warning if environment re-creation takes longer than 25% of the allowed timeout
* whilst restarting, recheck the REF state to avoid needlessly recreating the environment if restart is no longer required (most likely owning to close)

git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1627305 13f79535-47bb-0310-9956-ffa450edef68