@Internal public class StateMetadata extends Object
StreamExecNode
s that can generate stateful
operators. For ExecNodes that generates TwoInputStreamOperator
or MultipleInputStreamOperator
, there will be multiple
metadata describing information about each input's state.
The metadata describes the following attributes.
stateIndex
: annotates the state is from the i-th input, index based on zero
ttl
: annotates the state retention time for the i-th input's state, the time unit
is ms.
name
: annotates the state description, such as deduplicate-state, join-left-state.
Modifier and Type | Field and Description |
---|---|
static String |
FIELD_NAME_STATE_INDEX |
static String |
FIELD_NAME_STATE_NAME |
static String |
FIELD_NAME_STATE_TTL |
Constructor and Description |
---|
StateMetadata(int stateIndex,
Duration stateTtl,
String stateName) |
StateMetadata(int stateIndex,
String stateTtl,
String stateName) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
static List<StateMetadata> |
getMultiInputOperatorDefaultMeta(Map<Integer,Long> stateTtlFromHint,
ReadableConfig tableConfig,
String... stateNameList) |
static List<StateMetadata> |
getOneInputOperatorDefaultMeta(Long stateTtlFromHint,
ReadableConfig tableConfig,
String stateName) |
static List<StateMetadata> |
getOneInputOperatorDefaultMeta(ReadableConfig tableConfig,
String stateName) |
int |
getStateIndex() |
String |
getStateTtl() |
static List<Long> |
getStateTtlForMultiInputOperator(ExecNodeConfig config,
int inputNumOfOperator,
List<StateMetadata> stateMetadataList) |
static long |
getStateTtlForOneInputOperator(ExecNodeConfig config,
List<StateMetadata> stateMetadataList) |
int |
hashCode() |
public static final String FIELD_NAME_STATE_INDEX
public static final String FIELD_NAME_STATE_TTL
public static final String FIELD_NAME_STATE_NAME
public int getStateIndex()
public String getStateTtl()
public static List<StateMetadata> getOneInputOperatorDefaultMeta(ReadableConfig tableConfig, String stateName)
public static List<StateMetadata> getOneInputOperatorDefaultMeta(@Nullable Long stateTtlFromHint, ReadableConfig tableConfig, String stateName)
public static List<StateMetadata> getMultiInputOperatorDefaultMeta(Map<Integer,Long> stateTtlFromHint, ReadableConfig tableConfig, String... stateNameList)
public static long getStateTtlForOneInputOperator(ExecNodeConfig config, @Nullable List<StateMetadata> stateMetadataList)
public static List<Long> getStateTtlForMultiInputOperator(ExecNodeConfig config, int inputNumOfOperator, @Nullable List<StateMetadata> stateMetadataList)
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.