Class StateTtlConfig
- java.lang.Object
-
- org.apache.flink.api.common.state.StateTtlConfig
-
- All Implemented Interfaces:
Serializable
@PublicEvolving public class StateTtlConfig extends Object implements Serializable
Configuration of state TTL logic.Note: The map state with TTL currently supports
null
user values only if the user value serializer can handlenull
values. If the serializer does not supportnull
values, it can be wrapped withNullableSerializer
at the cost of an extra byte in the serialized form.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
StateTtlConfig.Builder
Builder for theStateTtlConfig
.static class
StateTtlConfig.CleanupStrategies
TTL cleanup strategies.static class
StateTtlConfig.IncrementalCleanupStrategy
Configuration of cleanup strategy while taking the full snapshot.static class
StateTtlConfig.RocksdbCompactFilterCleanupStrategy
Configuration of cleanup strategy using custom compaction filter in RocksDB.static class
StateTtlConfig.StateVisibility
This option configures whether expired user value can be returned or not.static class
StateTtlConfig.TtlTimeCharacteristic
This option configures time scale to use for ttl.static class
StateTtlConfig.UpdateType
This option value configures when to update last access timestamp which prolongs state TTL.
-
Field Summary
Fields Modifier and Type Field Description static StateTtlConfig
DISABLED
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StateTtlConfig.CleanupStrategies
getCleanupStrategies()
StateTtlConfig.StateVisibility
getStateVisibility()
Duration
getTimeToLive()
StateTtlConfig.TtlTimeCharacteristic
getTtlTimeCharacteristic()
StateTtlConfig.UpdateType
getUpdateType()
boolean
isEnabled()
static StateTtlConfig.Builder
newBuilder(Duration ttl)
String
toString()
-
-
-
Field Detail
-
DISABLED
public static final StateTtlConfig DISABLED
-
-
Method Detail
-
getUpdateType
@Nonnull public StateTtlConfig.UpdateType getUpdateType()
-
getStateVisibility
@Nonnull public StateTtlConfig.StateVisibility getStateVisibility()
-
getTimeToLive
public Duration getTimeToLive()
-
getTtlTimeCharacteristic
@Nonnull public StateTtlConfig.TtlTimeCharacteristic getTtlTimeCharacteristic()
-
isEnabled
public boolean isEnabled()
-
getCleanupStrategies
@Nonnull public StateTtlConfig.CleanupStrategies getCleanupStrategies()
-
newBuilder
public static StateTtlConfig.Builder newBuilder(Duration ttl)
-
-