docs: public void flush(String name) throws IOException {
          CloseableHttpClient client = HttpClients.createDefault();
          HttpPost method = new HttpPost(String.format("http://%s:%d/%s/_flush", host, port, name));
          try {
              CloseableHttpResponse resp = client.execute(method);
              int status = resp.getStatusLine().getStatusCode();
              if (status != HttpStatus.SC_OK) {
                  throw new IOException(resp.getStatusLine().getReasonPhrase());
              }
          } finally {
              method.releaseConnection();
          }
      }