Class PutTemplateRequest
java.lang.Object
co.elastic.clients.elasticsearch._types.RequestBase
co.elastic.clients.elasticsearch.indices.PutTemplateRequest
- All Implemented Interfaces:
ElasticsearchCommonRequest
,JsonpSerializable
@JsonpDeserializable public final class PutTemplateRequest extends RequestBase implements JsonpSerializable
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
PutTemplateRequest.Builder
Builder forPutTemplateRequest
.Nested classes/interfaces inherited from class co.elastic.clients.elasticsearch._types.RequestBase
RequestBase.AbstractBuilder<BuilderT extends RequestBase.AbstractBuilder<BuilderT>>
-
Field Summary
Fields Modifier and Type Field Description static JsonpDeserializer<PutTemplateRequest>
_DESERIALIZER
Json deserializer forPutTemplateRequest
static Endpoint<PutTemplateRequest,PutTemplateResponse,ElasticsearchError>
ENDPOINT
Endpoint "indices.put_template
". -
Constructor Summary
Constructors Constructor Description PutTemplateRequest(PutTemplateRequest.Builder builder)
PutTemplateRequest(java.util.function.Function<PutTemplateRequest.Builder,PutTemplateRequest.Builder> fn)
-
Method Summary
Modifier and Type Method Description java.util.Map<java.lang.String,Alias>
aliases()
Aliases for the index.java.lang.Boolean
create()
If true, this request cannot replace or update existing index templates.java.lang.Boolean
flatSettings()
API name:flat_settings
java.lang.Boolean
includeTypeName()
Whether a type should be returned in the body of the mappings.java.util.List<java.lang.String>
indexPatterns()
Array of wildcard expressions used to match the names of indices during creation.TypeMapping
mappings()
Mapping for fields in the index.java.lang.String
masterTimeout()
Period to wait for a connection to the master node.java.lang.String
name()
Required - The name of the templatejava.lang.Integer
order()
Order in which Elasticsearch applies this template if index matches multiple templates.void
serialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
Serialize this object to JSON.protected void
serializeInternal(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
java.util.Map<java.lang.String,JsonData>
settings()
Configuration options for the index.protected static void
setupPutTemplateRequestDeserializer(DelegatingDeserializer<PutTemplateRequest.Builder> op)
java.lang.String
timeout()
API name:timeout
java.lang.Long
version()
Version number used to manage index templates externally.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details
-
_DESERIALIZER
Json deserializer forPutTemplateRequest
-
ENDPOINT
Endpoint "indices.put_template
".
-
-
Constructor Details
-
PutTemplateRequest
-
PutTemplateRequest
public PutTemplateRequest(java.util.function.Function<PutTemplateRequest.Builder,PutTemplateRequest.Builder> fn)
-
-
Method Details
-
name
public java.lang.String name()Required - The name of the templateAPI name:
name
-
create
@Nullable public java.lang.Boolean create()If true, this request cannot replace or update existing index templates.API name:
create
-
flatSettings
@Nullable public java.lang.Boolean flatSettings()API name:flat_settings
-
includeTypeName
@Nullable public java.lang.Boolean includeTypeName()Whether a type should be returned in the body of the mappings.API name:
include_type_name
-
masterTimeout
@Nullable public java.lang.String masterTimeout()Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error.API name:
master_timeout
-
timeout
@Nullable public java.lang.String timeout()API name:timeout
-
aliases
Aliases for the index.API name:
aliases
-
indexPatterns
@Nullable public java.util.List<java.lang.String> indexPatterns()Array of wildcard expressions used to match the names of indices during creation.API name:
index_patterns
-
mappings
Mapping for fields in the index.API name:
mappings
-
order
@Nullable public java.lang.Integer order()Order in which Elasticsearch applies this template if index matches multiple templates.Templates with lower 'order' values are merged first. Templates with higher 'order' values are merged later, overriding templates with lower values.
API name:
order
-
settings
Configuration options for the index.API name:
settings
-
version
@Nullable public java.lang.Long version()Version number used to manage index templates externally. This number is not automatically generated by Elasticsearch.API name:
version
-
serialize
Serialize this object to JSON.- Specified by:
serialize
in interfaceJsonpSerializable
-
serializeInternal
-
setupPutTemplateRequestDeserializer
protected static void setupPutTemplateRequestDeserializer(DelegatingDeserializer<PutTemplateRequest.Builder> op)
-