Class TimeRetentionPolicyConfig.Builder
java.lang.Object
org.elasticsearch.client.transform.transforms.TimeRetentionPolicyConfig.Builder
- Enclosing class:
- TimeRetentionPolicyConfig
public static class TimeRetentionPolicyConfig.Builder
extends java.lang.Object
-
Constructor Summary
Constructors Constructor Description Builder() -
Method Summary
Modifier and Type Method Description TimeRetentionPolicyConfigbuild()TimeRetentionPolicyConfig.BuildersetField(java.lang.String field)The time field used to calculate the age of a document.TimeRetentionPolicyConfig.BuildersetMaxAge(org.elasticsearch.common.unit.TimeValue maxAge)The max age, all documents that are older will be deleted.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
setField
The time field used to calculate the age of a document.- Parameters:
field- The field name to be used to execute the retention policy- Returns:
- The
TimeRetentionPolicyConfig.Builderwith the field set.
-
setMaxAge
The max age, all documents that are older will be deleted.- Parameters:
maxAge- The maximum age of a document- Returns:
- The
TimeRetentionPolicyConfig.Builderwith max age set.
-
build
-