public static void removeAllDocument() {
int count = 0;
while (true) {
List<String> docIds = new ArrayList<String>();
// Return a set of document IDs.
GetRequest request = GetRequest.newBuilder()
.setReturningIdsOnly(true).build();
GetResponse<Document> response = INDEX.getRange(request);
if (response.getResults().isEmpty()) {
break;
}