Skip to content

Commit

Permalink
fixing esql test
Browse files Browse the repository at this point in the history
  • Loading branch information
masseyke committed Jan 3, 2024
1 parent 3c0b545 commit 1ba3f7c
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,12 @@ private void createRemoteIndex(int numDocs) throws Exception {
BulkRequestBuilder bulk = client(REMOTE_CLUSTER).prepareBulk("test").setRefreshPolicy(WriteRequest.RefreshPolicy.IMMEDIATE);
try {
for (int i = 0; i < numDocs; i++) {
bulk.add(new IndexRequest().source("foo", i));
IndexRequest indexRequest = new IndexRequest().source("foo", i);
try {
bulk.add(indexRequest);
} finally {
indexRequest.decRef();
}
}
bulk.get();
} finally {
Expand Down

0 comments on commit 1ba3f7c

Please sign in to comment.