From b184f2d850fa7416211abef71319913321c1a5ff Mon Sep 17 00:00:00 2001 From: tallison Date: Fri, 21 Feb 2025 11:50:05 -0500 Subject: [PATCH] #1474 -- code style --- .../stormcrawler/opensearch/IndexCreation.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/external/opensearch/src/main/java/org/apache/stormcrawler/opensearch/IndexCreation.java b/external/opensearch/src/main/java/org/apache/stormcrawler/opensearch/IndexCreation.java index 02dc3a969..1f0e9e28d 100644 --- a/external/opensearch/src/main/java/org/apache/stormcrawler/opensearch/IndexCreation.java +++ b/external/opensearch/src/main/java/org/apache/stormcrawler/opensearch/IndexCreation.java @@ -20,7 +20,6 @@ import com.google.common.io.Resources; import java.io.IOException; import java.net.URL; - import org.opensearch.OpenSearchException; import org.opensearch.action.support.master.AcknowledgedResponse; import org.opensearch.client.RequestOptions; @@ -41,10 +40,11 @@ public static synchronized void checkOrCreateIndex( final boolean indexExists = client.indices().exists(new GetIndexRequest(indexName), RequestOptions.DEFAULT); log.info("Index '{}' exists? {}", indexName, indexExists); - //there's a possible check-then-update race condition - //createIndex intentionally catches and logs exceptions from OpenSearch + // there's a possible check-then-update race condition + // createIndex intentionally catches and logs exceptions from OpenSearch if (!indexExists) { - boolean created = IndexCreation.createIndex(client, indexName, boltType + ".mapping", log); + boolean created = + IndexCreation.createIndex(client, indexName, boltType + ".mapping", log); log.info("Index '{}' created? {} using {}", indexName, created, boltType + ".mapping"); } } @@ -58,8 +58,8 @@ public static synchronized void checkOrCreateIndexTemplate( new IndexTemplatesExistRequest(templateName), RequestOptions.DEFAULT); log.info("Template '{}' exists? {}", templateName, templateExists); - //there's a possible check-then-update race condition - //createTemplate intentionally catches and logs exceptions from OpenSearch + // there's a possible check-then-update race condition + // createTemplate intentionally catches and logs exceptions from OpenSearch if (!templateExists) { boolean created = IndexCreation.createTemplate(client, templateName, boltType + ".mapping", log);