gunjanaggarwal1 opened a new pull request, #30005: URL: https://github.com/apache/flink/pull/30005
## What is the purpose of the change Backport of [FLINK-39140](https://issues.apache.org/jira/browse/FLINK-39140) to `release-1.20`. `UnalignedCheckpointRescaleWithMixedExchangesITCase` emits `Long` records. At 8 bytes per record a single buffer holds thousands of them, so the aligned exchanges in these DAGs (forward and rescale exchanges do not support unaligned checkpoints) have to drain a very large number of records before a barrier can pass. That makes the test slow and unstable. On `master` this was fixed by switching the records to 100-character `String`s, which cuts the record count per buffer and shortens the time needed to drain backpressured buffers. This PR brings that commit (`02e36182d4a`) to `release-1.20`. FLINK-39140 consists of four commits on `master`. The `MAX_RETAINED_CHECKPOINTS` one (`17581beed0c`) is already on `release-1.20` as `1263b16bc6d`; this PR backports the remaining commit that touches this test. The other two (`ffd01f74c6d`, `abfc3012ba4`) affect `UnalignedCheckpointRescaleITCase` / `UnalignedCheckpointITCase` and are not part of this PR. ## Brief change log - Add `RECORD_LENGTH = 100` and generate 100-character random `a`-`z` `String` records in `createSource()` instead of emitting the sequence index; the source type information changes from `Types.LONG` to `Types.STRING`. - Switch the five DAG builders and their `KeySelector`s from `Long` to `String`. - Make `SleepingCoMap` generic over `T`. The cherry-pick had one conflict, in `createSource()`: on `master` the `DataGeneratorSource` is wrapped in an anonymous subclass (`Types.STRING) {}`), which comes from a later change that is not on `release-1.20`. The `release-1.20` form (`Types.STRING);`) is kept, so this PR contains only the record type change. The rest of the commit applied unchanged. ## Verifying this change This change is test-only and is covered by the existing `UnalignedCheckpointRescaleWithMixedExchangesITCase` tests. - 100 runs of `UnalignedCheckpointRescaleWithMixedExchangesITCase` on this PR's commit, in Flink's CI Docker image on 5 machines x 20 runs, 0 failures: https://github.com/gunjanaggarwal1/flink/actions/runs/43909562866 - 100 runs of the same test with the same change on the `master`-side branch, 5 machines x 20 runs, 0 failures: https://github.com/gunjanaggarwal1/flink/actions/runs/43168924324 - Locally on `release-1.20` with JDK 21: all 5 parameterized cases pass (`Tests run: 5, Failures: 0, Errors: 0, Skipped: 0`), and `spotless:check` and `checkstyle:check` are clean for `flink-tests`. ## Does this pull request potentially affect one of the following parts: - Dependencies (does it add or upgrade a dependency): no - The public API, i.e., is any changed class annotated with `@Public(Evolving)`: no - The serializers: no - The runtime per-record code paths (performance sensitive): no - Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn, ZooKeeper: no - The S3 file system connector: no ## Documentation - Does this pull request introduce a new feature? no - If yes, how is the feature documented? not applicable --- ##### Was generative AI tooling used to co-author this PR? - [X] Yes (please specify the tool below) Generated-by: Claude Code 2.1.301 (Claude Opus 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]
