Class PutComponentTemplateRequest.Builder
java.lang.Object
org.opensearch.client.util.ObjectBuilderBase
org.opensearch.client.opensearch._types.RequestBase.AbstractBuilder<PutComponentTemplateRequest.Builder>
org.opensearch.client.opensearch.cluster.PutComponentTemplateRequest.Builder
- All Implemented Interfaces:
CopyableBuilder<PutComponentTemplateRequest.Builder,,PutComponentTemplateRequest> MutableBuilder<PutComponentTemplateRequest.Builder,,PutComponentTemplateRequest> ObjectBuilder<PutComponentTemplateRequest>
- Enclosing class:
PutComponentTemplateRequest
public static class PutComponentTemplateRequest.Builder
extends RequestBase.AbstractBuilder<PutComponentTemplateRequest.Builder>
implements CopyableBuilder<PutComponentTemplateRequest.Builder,PutComponentTemplateRequest>
Builder for
PutComponentTemplateRequest.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionallowAutoCreate(Boolean value) This setting overrides theaction.auto_create_indexcluster setting.build()Builds aPutComponentTemplateRequest.The amount of time to wait for a response from the cluster manager node.clusterManagerTimeout(Time value) The amount of time to wait for a response from the cluster manager node.copy()Create a new builderCopyableBuilderthat is a copy of this one.Whentrue, this request cannot replace or update existing component templates.Deprecated.masterTimeout(Time value) Deprecated.API name:_metaAPI name:_metaRequired - The name of the component template to create.protected PutComponentTemplateRequest.Builderself()Required - API name:templatetemplate(IndexState value) Required - API name:templateA duration.A duration.API name:versionMethods inherited from class org.opensearch.client.opensearch._types.RequestBase.AbstractBuilder
errorTrace, humanMethods inherited from class org.opensearch.client.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _listCopy, _mapCopy, _mapPut, _mapPutAllMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.opensearch.client.util.MutableBuilder
applyMutation
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
copy
Description copied from interface:CopyableBuilderCreate a new builderCopyableBuilderthat is a copy of this one.- Specified by:
copyin interfaceCopyableBuilder<PutComponentTemplateRequest.Builder,PutComponentTemplateRequest> - Returns:
- a new builder instance.
-
self
- Specified by:
selfin classRequestBase.AbstractBuilder<PutComponentTemplateRequest.Builder>
-
allowAutoCreate
This setting overrides theaction.auto_create_indexcluster setting. When set totruein a component template, indexes are automatically created using that template. When set tofalse, data streams matching the component template must always be explicitly created.API name:
allow_auto_create -
clusterManagerTimeout
@Nonnull public final PutComponentTemplateRequest.Builder clusterManagerTimeout(@Nullable Time value) The amount of time to wait for a response from the cluster manager node. For more information about supported time units, see Common parameters.API name:
cluster_manager_timeout -
clusterManagerTimeout
@Nonnull public final PutComponentTemplateRequest.Builder clusterManagerTimeout(Function<Time.Builder, ObjectBuilder<Time>> fn) The amount of time to wait for a response from the cluster manager node. For more information about supported time units, see Common parameters.API name:
cluster_manager_timeout -
create
Whentrue, this request cannot replace or update existing component templates.API name:
create -
masterTimeout
@Deprecated @Nonnull public final PutComponentTemplateRequest.Builder masterTimeout(@Nullable Time value) Deprecated.A duration. Units can benanos,micros,ms(milliseconds),s(seconds),m(minutes),h(hours) andd(days). Also accepts0without a unit and-1to indicate an unspecified value.API name:
master_timeout -
masterTimeout
@Deprecated @Nonnull public final PutComponentTemplateRequest.Builder masterTimeout(Function<Time.Builder, ObjectBuilder<Time>> fn) Deprecated.A duration. Units can benanos,micros,ms(milliseconds),s(seconds),m(minutes),h(hours) andd(days). Also accepts0without a unit and-1to indicate an unspecified value.API name:
master_timeout -
meta
API name:_metaAdds all elements of
maptometa. -
meta
API name:_metaAdds an entry to
meta. -
name
Required - The name of the component template to create. OpenSearch includes the following built-in component templates:logs-mappings,logs-settings,metrics-mappings,metrics-settings,synthetics-mapping, andsynthetics-settings. OpenSearch uses these templates to configure backing indexes for its data streams. If you want to overwrite one of these templates, set the replacement templateversionto a higher value than the current version. If you want to disable all built-in component and index templates, setstack.templates.enabledtofalseusing the Cluster Update Settings API.API name:
name -
template
Required - API name:template -
template
@Nonnull public final PutComponentTemplateRequest.Builder template(Function<IndexState.Builder, ObjectBuilder<IndexState>> fn) Required - API name:template -
timeout
A duration. Units can benanos,micros,ms(milliseconds),s(seconds),m(minutes),h(hours) andd(days). Also accepts0without a unit and-1to indicate an unspecified value.API name:
timeout -
timeout
@Nonnull public final PutComponentTemplateRequest.Builder timeout(Function<Time.Builder, ObjectBuilder<Time>> fn) A duration. Units can benanos,micros,ms(milliseconds),s(seconds),m(minutes),h(hours) andd(days). Also accepts0without a unit and-1to indicate an unspecified value.API name:
timeout -
version
API name:version -
build
Builds aPutComponentTemplateRequest.- Specified by:
buildin interfaceObjectBuilder<PutComponentTemplateRequest>- Throws:
NullPointerException- if some of the required fields are null.
-