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 TimeRetentionPolicyConfig
build()
TimeRetentionPolicyConfig.Builder
setField(java.lang.String field)
The time field used to calculate the age of a document.TimeRetentionPolicyConfig.Builder
setMaxAge(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.Builder
with 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.Builder
with max age set.
-
build
-