log at ERROR level for fulltext query without index
Fulltext queries cannot be handled by traversal, so we need to highlight prominently when a fulltext query has been issues but no appropriate index can be found.
@@ -1201,7 +1201,13 @@ public class QueryImpl implements Query {
}
if (potentiallySlowTraversalQuery || bestIndex == null) {
+ // Log error for fulltext queries without index, since these cannot return results
+ if(!filter.getFulltextConditions().isEmpty()) {
+ LOG.error("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);
