docs: private HttpURLConnection createNewConnectionIfBulkSizeReached(HttpURLConnection connection, int entriesWritten) throws IOException {
          if (entriesWritten % bulkSize == 0) {
              closeConnection(connection);
              return openConnection("/_bulk", "POST");
          }
  
          return connection;
      }