Package org.elasticsearch.index.query
Class CoordinatorRewriteContext
java.lang.Object
org.elasticsearch.index.query.QueryRewriteContext
org.elasticsearch.index.query.CoordinatorRewriteContext
Context object used to rewrite
QueryBuilder
instances into simplified version in the coordinator.
Instances of this object rely on information stored in the IndexMetadata
for certain indices.
Right now this context object is able to rewrite range queries that include a known timestamp field
(i.e. the timestamp field for DataStreams) into a MatchNoneQueryBuilder and skip the shards that
don't hold queried data. See IndexMetadata#getTimestampRange() for more details-
Field Summary
Fields inherited from class org.elasticsearch.index.query.QueryRewriteContext
client, nowInMillis
-
Constructor Summary
ConstructorDescriptionCoordinatorRewriteContext
(org.elasticsearch.xcontent.NamedXContentRegistry xContentRegistry, NamedWriteableRegistry writeableRegistry, Client client, LongSupplier nowInMillis, Index index, IndexLongFieldRange indexLongFieldRange, DateFieldMapper.DateFieldType timestampFieldType) -
Method Summary
Methods inherited from class org.elasticsearch.index.query.QueryRewriteContext
convertToSearchExecutionContext, executeAsyncActions, getWriteableRegistry, getXContentRegistry, hasAsyncActions, nowInMillis, registerAsyncAction
-
Constructor Details
-
CoordinatorRewriteContext
public CoordinatorRewriteContext(org.elasticsearch.xcontent.NamedXContentRegistry xContentRegistry, NamedWriteableRegistry writeableRegistry, Client client, LongSupplier nowInMillis, Index index, IndexLongFieldRange indexLongFieldRange, DateFieldMapper.DateFieldType timestampFieldType)
-
-
Method Details
-
getFieldType
-
convertToCoordinatorRewriteContext
- Overrides:
convertToCoordinatorRewriteContext
in classQueryRewriteContext
-