Thesharing edited a comment on pull request #15314: URL: https://github.com/apache/flink/pull/15314#issuecomment-804025086
It's worth noting that although after the optimization the complexity is O(N), the time cost on RegionPartitionReleaseStrategy#filterReleasablePartitions is still a bit long. As illustrated in the figure below, we can see that most of time is spent on `HashMap.get`. ![Illustration](https://user-images.githubusercontent.com/6576831/111989779-2e45c880-8b4d-11eb-93e8-ed2ecb31729a.png) -- 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: us...@infra.apache.org