Add wait logic for gateload and seriesly

Change-Id: I6b85ef0e45ad64a84a8f5b9549c646d963fd9ff6
Reviewed-on: http://review.couchbase.org/37150
Tested-by: buildbot <build@couchbase.com>
Reviewed-by: Pavel Paulau <pavel.paulau@gmail.com>