1996fanrui opened a new pull request, #29846: URL: https://github.com/apache/flink/pull/29846
## What is the purpose of the change Backport of #28985 to release-2.2. ## Verifying this change - `./mvnw -pl flink-state-backends/flink-statebackend-forst -am -Pskip-webui-build -Dtest='ForStGeneralMultiGetOperationTest' -Dsurefire.failIfNoSpecifiedTests=false package` (JDK 17): BUILD SUCCESS, `Tests run: 4, Failures: 0, Errors: 0, Skipped: 0 -- in org.apache.flink.state.forst.ForStGeneralMultiGetOperationTest` - `./mvnw -q -pl flink-state-backends/flink-statebackend-forst spotless:check checkstyle:check` (JDK 17): passed - Read `ForStGeneralMultiGetOperation` on release-2.2: it is identical to the file before the fix on master, so the per-batch `ReadOptions` leak exists on this branch. ## Difference from the original | Original commit | Conflict | Byte-identical | Changes | | --- | --- | --- | --- | | 0edbffc538a | No | Yes | None | ## Notes - The original change adds no new test; the existing `ForStGeneralMultiGetOperationTest` covers the code path. No test asserts the native leak itself. - The change touches the per-record state access path. On the Jira, the original author confirmed it is safe to backport: it only closes the per-batch `ReadOptions` after the synchronous `multiGetAsList` call, with no change to state format, checkpoints, configuration, or API. ##### Was generative AI tooling used to co-author this PR? <!-- If generative AI tooling has been used in the process of authoring this PR, please change the checkbox below to `[X]` followed by the name of the tool, and uncomment the "Generated-by" line. See the ASF Generative Tooling Guidance for details: https://www.apache.org/legal/generative-tooling.html You are responsible for the quality and correctness of every change in this PR regardless of the tooling used. Low-effort AI-generated PRs will be closed. See AGENTS.md for the full guidance. --> - [X] Yes (please specify the tool below) Generated-by: Claude Code (Claude Opus 5.5) -- 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]
