leonardBang commented on a change in pull request #11830:
URL: https://github.com/apache/flink/pull/11830#discussion_r527353379
##########
File path:
flink-table/flink-table-runtime-blink/src/main/java/org/apache/flink/table/runtime/dataview/StateListView.java
##########
@@ -76,7 +77,14 @@ public void addAll(List<EE> list) throws Exception {
@Override
public boolean remove(EE value) throws Exception {
- List<EE> list = (List<EE>) getListState().get();
+ // the getListState().get() not always returns List object
+ // copy values to ArrayList for removing
+ Iterator<EE> iterator = getListState().get().iterator();
Review comment:
`getListState().get()` may return null object, add a null check?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]