Package org.elasticsearch.index.query
Class CoordinatorRewriteContext
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
ConstructorsConstructorDescriptionCoordinatorRewriteContext(org.elasticsearch.common.xcontent.NamedXContentRegistry xContentRegistry, NamedWriteableRegistry writeableRegistry, Client client, nowInMillis, Index index, IndexLongFieldRange indexLongFieldRange, DateFieldMapper.DateFieldType timestampFieldType)
-
Method Summary
Modifier and TypeMethodDescriptionfieldName)
Methods inherited from class org.elasticsearch.index.query.QueryRewriteContext
convertToSearchExecutionContext, executeAsyncActions, getWriteableRegistry, getXContentRegistry, hasAsyncActions, nowInMillis, registerAsyncAction
Methods inherited from class java.lang.
, , , , , , , , , ,
-
Constructor Details
-
CoordinatorRewriteContext
public CoordinatorRewriteContext(org.elasticsearch.common.xcontent.NamedXContentRegistry xContentRegistry, NamedWriteableRegistry writeableRegistry, Client client, nowInMillis, Index index, IndexLongFieldRange indexLongFieldRange, DateFieldMapper.DateFieldType timestampFieldType)
-
-
Method Details
-
getFieldType
@Nullable public fieldName) -
convertToCoordinatorRewriteContext
- Overrides:
convertToCoordinatorRewriteContext
in classQueryRewriteContext
-