From 4148d6a39dcd999fbf1df9422d4d1b8f4d833e1d Mon Sep 17 00:00:00 2001 From: Siddhant Deshmukh Date: Mon, 16 Oct 2023 14:59:12 -0700 Subject: [PATCH] Minor fix Signed-off-by: Siddhant Deshmukh --- .../org/opensearch/action/search/SearchQueryCategorizer.java | 2 -- .../src/main/java/org/opensearch/common/util/FeatureFlags.java | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/server/src/main/java/org/opensearch/action/search/SearchQueryCategorizer.java b/server/src/main/java/org/opensearch/action/search/SearchQueryCategorizer.java index bfe96be3e05d1..83e4ecbc7750d 100644 --- a/server/src/main/java/org/opensearch/action/search/SearchQueryCategorizer.java +++ b/server/src/main/java/org/opensearch/action/search/SearchQueryCategorizer.java @@ -57,7 +57,6 @@ private void incrementQueryAggregationCounters(AggregatorFactories.Builder aggre private void incrementQueryTypeCounters(QueryBuilder topLevelQueryBuilder) { if (topLevelQueryBuilder == null) { - searchQueryCounters.skippedCounter.add(1); return; } QueryBuilderVisitor searchQueryVisitor = new SearchQueryCategorizingVisitor(searchQueryCounters); @@ -66,7 +65,6 @@ private void incrementQueryTypeCounters(QueryBuilder topLevelQueryBuilder) { private void logQueryShape(QueryBuilder topLevelQueryBuilder) { if (topLevelQueryBuilder == null) { - searchQueryCounters.skippedCounter.add(1); return; } QueryShapeVisitor shapeVisitor = new QueryShapeVisitor(); diff --git a/server/src/main/java/org/opensearch/common/util/FeatureFlags.java b/server/src/main/java/org/opensearch/common/util/FeatureFlags.java index 0fb5cbb18df19..4e9b417e3433b 100644 --- a/server/src/main/java/org/opensearch/common/util/FeatureFlags.java +++ b/server/src/main/java/org/opensearch/common/util/FeatureFlags.java @@ -59,7 +59,7 @@ public class FeatureFlags { * Gates the optimization of datetime formatters caching along with change in default datetime formatter. */ public static final String DATETIME_FORMATTER_CACHING = "opensearch.experimental.optimization.datetime_formatter_caching.enabled"; - + /** * Should store the settings from opensearch.yml. */