THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
*Note that this doc is only for the MVP (or V1) of this feature. More valid features and use cases can be added after MVP.
Public Interfaces
...
A new Maven module “flink-sql-client” with the SQL client
...
A new binary file for executing the SQL client in embedded mode
Code Block | ||
---|---|---|
| ||
enum TtlUpdateEvent {
// required, default option
OnCreate,
// optional
OnRead,
OnWrite,
OnReadWrite
}
enum TtlTimeCharacteristic {
EVENT_TIME,
PROCESSING_TIME
}
class TtlPolicy {
TtlUpdateEvent ttlEvent;
int ttl;
TtlTimeCharacteristics ttlTimeCharacteristics;
// ...
}
// ttl in sec
ttl = 5
// default TTL, using TtlPolicy.OnCreate
ttlPolicy1 = new TtlPolicy(ttl, TimeCharacteristic.EVENT_TIME)
// extended TTL, using TtlPolicy.OnCreate and TtlPolicy.onReadWrite
ttlPolicy2 = new TtlPolicy(ttl, TimeCharacteristic.PROCESSING_TIME, TtlEvent.OnReadWrite)
state1 = getRuntimeContext().getState(new ValueStateDescriptor<T>("x", ser, ttlPolicy1);
state2 = getRuntimeContext().getState(new ValueStateDescriptor<T>("y", ser, ttlPolicy2)); |
...
Proposed Changes
General Architecture
...