fredia commented on code in PR #24740: URL: https://github.com/apache/flink/pull/24740#discussion_r1590503035
########## flink-runtime/src/main/java/org/apache/flink/runtime/asyncprocessing/AsyncExecutionController.java: ########## @@ -104,15 +105,21 @@ public class AsyncExecutionController<K> implements StateRequestHandler { public AsyncExecutionController( MailboxExecutor mailboxExecutor, - StateExecutor stateExecutor, + AsyncKeyedStateBackend asyncKeyedStateBackend, int maxParallelism, int batchSize, long bufferTimeout, int maxInFlightRecords) { this.keyAccountingUnit = new KeyAccountingUnit<>(maxInFlightRecords); this.mailboxExecutor = mailboxExecutor; this.stateFutureFactory = new StateFutureFactory<>(this, mailboxExecutor); - this.stateExecutor = stateExecutor; + if (asyncKeyedStateBackend != null) { Review Comment: Would it be better to put the initialization of the `state executor` in the `StreamOperator`? ########## flink-streaming-java/src/main/java/org/apache/flink/streaming/api/operators/StreamingRuntimeContext.java: ########## @@ -242,6 +248,25 @@ private KeyedStateStore checkPreconditionsAndGetKeyedStateStore( return keyedStateStore; } + // TODO: Reconstruct this after StateManager is ready in FLIP-410. Review Comment: How about renaming it to `getValueState()`? BTW, when the user provides the stateDescriptorV2, this method is used, and when the user provides the stateDescriptorV1, the old `getState` is used, right? Can stateDescriptorV2 and stateDescriptorV1 coexist? ########## flink-state-backends/flink-statebackend-forst/src/main/java/org/apache/flink/state/forst/ForStKeyedStateBackendBuilder.java: ########## @@ -54,7 +59,14 @@ public class ForStKeyedStateBackendBuilder<K> protected final Logger logger = LoggerFactory.getLogger(getClass()); + private static final int KEY_SERIALIZER_BUFFER_START_SIZE = 32; + + private static final int VALUE_SERIALIZER_BUFFER_START_SIZE = 128; Review Comment: Why is 128 chosen here? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org