Skip to content

Commit

Permalink
Merge pull request #467 from blackfor/OAK-9670
Browse files Browse the repository at this point in the history
OAK-9670 : log at WARN level for fulltext query without index
  • Loading branch information
thomasmueller committed Jan 18, 2022
2 parents f876ad8 + ba48f54 commit 8bd1b14
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1201,7 +1201,13 @@ private SelectorExecutionPlan getBestSelectorExecutionPlan(
}

if (potentiallySlowTraversalQuery || bestIndex == null) {
LOG.debug("no proper index was found for filter {}", filter);
// Log warning for fulltext queries without index, since these cannot return results
if(!filter.getFulltextConditions().isEmpty()) {
LOG.warn("Fulltext query without index for filter {}; no results will be returned", filter);
} else {
LOG.debug("no proper index was found for filter {}", filter);
}

StatisticsProvider statisticsProvider = getSettings().getStatisticsProvider();
if (statisticsProvider != null) {
HistogramStats histogram = statisticsProvider.getHistogram(INDEX_UNAVAILABLE, StatsOptions.METRICS_ONLY);
Expand Down

0 comments on commit 8bd1b14

Please sign in to comment.