-
Notifications
You must be signed in to change notification settings - Fork 673
Parallelise sanity checks in order to speed them up. #2699
Conversation
e88744b
to
75ee528
Compare
for host in $HOSTS; do | ||
for other in $HOSTS; do | ||
[ $host = $other ] || run_on $host $PING $other | ||
if [ "$host" != "$other" ]; then | ||
echo $(run_on $host $PING $other) & |
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
echo "# weave version" | ||
docker inspect -f {{.Created}} weaveworks/weave:${WEAVE_VERSION:-latest} | ||
weave_on $host version | ||
check_docker $host & |
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
done | ||
done | ||
for pid in $pids; do wait $pid; done | ||
unset pids |
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
@@ -6,10 +6,17 @@ set -e | |||
|
|||
whitely echo Ping each host from the other | |||
|
|||
function check_ping() { |
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
This comment was marked as abuse.
This comment was marked as abuse.
Sorry, something went wrong.
aa30872
to
5c5ab18
Compare
Sample output on CircleCI:
|
4e42de9
to
6a073cc
Compare
Example of artifact files': https://circleci.com/gh/weaveworks/weave/7509#artifacts/containers/0 |
…ously set values.
…s artifact files under CircleCLI). This should make it easier to find and access relevant debugging information without polluting STDOUT and without any risk of log interleaving. See also: - https://weaveworks.slack.com/archives/net/p1482154505001192 - https://weaveworks.slack.com/archives/net/p1482254780001493
6a073cc
to
f73fb53
Compare
All changes made as requested. Unless I missed something, for some reason GitHub thinks there is still something outstanding.
… when running smoke tests in CircleCI. Previously sanity checks' output was redirected to /tmp and then copied to $CIRCLE_ARTIFACTS, which is more "moving pieces".
Sanity checks' output still gets properly redirected, but now under |
Time spent running the sanity checks becomes a blocker when trying to ramp up the number of test servers, given ping check is
O(n^2)
and docker check isO(n)
. This change makes it closer to "perceived"O(1)
.This is a pre-change refactoring for the #2647 and #2648 work.