Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SmokeTestWatcherWithSecurityIT: Retry if failures searching .watcher-history #43781

Merged
merged 3 commits into from
Jul 1, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import org.apache.http.util.EntityUtils;
import org.elasticsearch.client.Request;
import org.elasticsearch.client.Response;
import org.elasticsearch.client.ResponseException;
import org.elasticsearch.common.Strings;
import org.elasticsearch.common.settings.SecureString;
import org.elasticsearch.common.settings.Settings;
Expand Down Expand Up @@ -330,6 +331,10 @@ private ObjectPath getWatchHistoryEntry(String watchId, String state) throws Exc
String watchid = objectPath.evaluate("hits.hits.0._source.watch_id");
assertThat(watchid, is(watchId));
objectPathReference.set(objectPath);
} catch (ResponseException e) {
final String err = "Failed to perform search of watcher history";
logger.info(err, e);
fail(err);
}
});
return objectPathReference.get();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -216,8 +216,8 @@ private ObjectPath getWatchHistoryEntry(String watchId) throws Exception {
assertThat("watch_id for hit 0 in watcher history", foundWatchId, is(watchId));
objectPathReference.set(objectPath);
} catch (ResponseException e) {
final String err = "Failed to perform search of watcher history - " + e;
logger.info(err);
final String err = "Failed to perform search of watcher history";
logger.info(err, e);
fail(err);
}
});
Expand Down