davidradl commented on code in PR #26396:
URL: https://github.com/apache/flink/pull/26396#discussion_r2028599285
##########
flink-table/flink-table-runtime/src/main/java/org/apache/flink/table/runtime/operators/process/ProcessTableOperator.java:
##########
@@ -331,12 +361,24 @@ private void setStateDescriptors() {
this.stateDescriptors = stateDescriptors;
}
- @SuppressWarnings("unchecked")
private void setStateHandles() {
final KeyedStateStore keyedStateStore = getKeyedStateStore();
- final ValueState<RowData>[] stateHandles = new
ValueState[stateDescriptors.length];
+ final State[] stateHandles = new State[stateDescriptors.length];
for (int i = 0; i < stateInfos.size(); i++) {
- stateHandles[i] = keyedStateStore.getState(stateDescriptors[i]);
Review Comment:
I am not understanding this for loop. I wonder if the comment might help.
- We loop on `stateInfos.size()` not does not refer to `stateInfos[i]` in
the loop. Would this be better : `for (StateDescriptor stateDescriptor:
stateDescriptors) {`
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]