public void flush() { Assert.isTrue(writeInitialized, "Cannot flush non-initialized write operation"); bulkProcessor.flush(); }
/** * Flushes and closes the bulk processor to further writes. */ @Override public void close() { try { if (!hadWriteErrors) { flush(); } else { if (LOG.isDebugEnabled()) { LOG.debug("Dirty close; ignoring last existing write batch..."); } } if (requiresRefreshAfterBulk && executedBulkWrite) { // refresh batch restClient.refresh(resource); if (LOG.isDebugEnabled()) { LOG.debug(String.format("Refreshing index [%s]", resource)); } } } finally { for (IBulkWriteErrorHandler handler : documentBulkErrorHandlers) { handler.close(); } } }
public void flush() { Assert.isTrue(writeInitialized, "Cannot flush non-initialized write operation"); bulkProcessor.flush(); }
public void flush() { Assert.isTrue(writeInitialized, "Cannot flush non-initialized write operation"); bulkProcessor.flush(); }
public void flush() { Assert.isTrue(writeInitialized, "Cannot flush non-initialized write operation"); bulkProcessor.flush(); }
/** * Flushes and closes the bulk processor to further writes. */ @Override public void close() { try { if (!hadWriteErrors) { flush(); } else { if (LOG.isDebugEnabled()) { LOG.debug("Dirty close; ignoring last existing write batch..."); } } if (requiresRefreshAfterBulk && executedBulkWrite) { // refresh batch restClient.refresh(resource); if (LOG.isDebugEnabled()) { LOG.debug(String.format("Refreshing index [%s]", resource)); } } } finally { for (IBulkWriteErrorHandler handler : documentBulkErrorHandlers) { handler.close(); } } }
/** * Flushes and closes the bulk processor to further writes. */ @Override public void close() { try { if (!hadWriteErrors) { flush(); } else { if (LOG.isDebugEnabled()) { LOG.debug("Dirty close; ignoring last existing write batch..."); } } if (requiresRefreshAfterBulk && executedBulkWrite) { // refresh batch restClient.refresh(resource); if (LOG.isDebugEnabled()) { LOG.debug(String.format("Refreshing index [%s]", resource)); } } } finally { for (IBulkWriteErrorHandler handler : documentBulkErrorHandlers) { handler.close(); } } }
/** * Flushes and closes the bulk processor to further writes. */ @Override public void close() { try { if (!hadWriteErrors) { flush(); } else { if (LOG.isDebugEnabled()) { LOG.debug("Dirty close; ignoring last existing write batch..."); } } if (requiresRefreshAfterBulk && executedBulkWrite) { // refresh batch restClient.refresh(resource); if (LOG.isDebugEnabled()) { LOG.debug(String.format("Refreshing index [%s]", resource)); } } } finally { for (IBulkWriteErrorHandler handler : documentBulkErrorHandlers) { handler.close(); } } }