Class FieldCapsRequest
- All Implemented Interfaces:
JsonpSerializable
Get information about the capabilities of fields among multiple indices.
For data streams, the API returns field capabilities among the stream’s
backing indices. It returns runtime fields like any other field. For example,
a runtime field with a type of keyword is returned the same as any other
field that belongs to the keyword family.
- See Also:
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class co.elastic.clients.elasticsearch._types.RequestBase
RequestBase.AbstractBuilder<BuilderT extends RequestBase.AbstractBuilder<BuilderT>> -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final JsonpDeserializer<FieldCapsRequest>Json deserializer forFieldCapsRequeststatic final Endpoint<FieldCapsRequest,FieldCapsResponse, ErrorResponse> Endpoint "field_caps". -
Method Summary
Modifier and TypeMethodDescriptionfinal BooleanIf false, the request returns an error if any wildcard expression, index alias, or_allvalue targets only missing or closed indices.final List<ExpandWildcard>The type of index that wildcard patterns can match.fields()A list of fields to retrieve capabilities for.final Stringfilters()A comma-separated list of filters to apply to the response.final BooleanIftrue, missing or closed indices are not included in the response.final BooleanIf false, empty fields are not included in the response.final BooleanIf true, unmapped fields are included in the response.index()A comma-separated list of data streams, indices, and aliases used to limit the request.final QueryFilter indices if the provided query rewrites tomatch_noneon every shard.static FieldCapsRequestfinal StringSpecifies a subset of projects to target for the field-caps query using project metadata tags in a subset of Lucene query syntax.final Map<String,RuntimeField> Define ad-hoc runtime fields in the request similar to the way it is done in search requests.voidserialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) Serialize this object to JSON.protected voidserializeInternal(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) protected static voidtypes()A comma-separated list of field types to include.Methods inherited from class co.elastic.clients.elasticsearch._types.RequestBase
toString
-
Field Details
-
_DESERIALIZER
Json deserializer forFieldCapsRequest -
_ENDPOINT
Endpoint "field_caps".
-
-
Method Details
-
of
public static FieldCapsRequest of(Function<FieldCapsRequest.Builder, ObjectBuilder<FieldCapsRequest>> fn) -
allowNoIndices
If false, the request returns an error if any wildcard expression, index alias, or_allvalue targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targetingfoo*,bar*returns an error if an index starts with foo but no index starts with bar.API name:
allow_no_indices -
expandWildcards
The type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports comma-separated values, such asopen,hidden.API name:
expand_wildcards -
fields
A list of fields to retrieve capabilities for. Wildcard (*) expressions are supported.API name:
fields -
filters
A comma-separated list of filters to apply to the response.API name:
filters -
includeEmptyFields
If false, empty fields are not included in the response.API name:
include_empty_fields -
includeUnmapped
If true, unmapped fields are included in the response.API name:
include_unmapped -
index
A comma-separated list of data streams, indices, and aliases used to limit the request. Supports wildcards (*). To target all data streams and indices, omit this parameter or use * or _all.API name:
index -
indexFilter
Filter indices if the provided query rewrites tomatch_noneon every shard.IMPORTANT: The filtering is done on a best-effort basis, it uses index statistics and mappings to rewrite queries to
match_noneinstead of fully running the request. For instance a range query over a date field can rewrite tomatch_noneif all documents within a shard (including deleted documents) are outside of the provided range. However, not all queries can rewrite tomatch_noneso this API may return an index even if the provided filter matches no document.API name:
index_filter -
projectRouting
Specifies a subset of projects to target for the field-caps query using project metadata tags in a subset of Lucene query syntax. Allowed Lucene queries: the _alias tag and a single value (possibly wildcarded). Examples: _alias:my-project _alias:_origin _alias:pr Supported in serverless only.API name:
project_routing -
runtimeMappings
Define ad-hoc runtime fields in the request similar to the way it is done in search requests. These fields exist only as part of the query and take precedence over fields defined with the same name in the index mappings.API name:
runtime_mappings -
types
A comma-separated list of field types to include. Any fields that do not match one of these types will be excluded from the results. It defaults to empty, meaning that all field types are returned.API name:
types -
serialize
Serialize this object to JSON.- Specified by:
serializein interfaceJsonpSerializable
-
serializeInternal
-
setupFieldCapsRequestDeserializer
protected static void setupFieldCapsRequestDeserializer(ObjectDeserializer<FieldCapsRequest.Builder> op)
-