[
https://issues.apache.org/jira/browse/FLINK-40904?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18129490#comment-18129490
]
Rui Fan edited comment on FLINK-40904 at 11/1/26, 1:22 PM:
-----------------------------------------------------------
Merged to master(2.4.0) via: 56dfbeb423a9884b4def84fa155ac21fc4e4a30e and
96f55807499550d89ddfb90d928811cd8cc09370
2.3.1 via: edf5916ce4e42ec80f4ce43b45aa1cd8eeeeaf84 and
3ccd4e92d7b4bd62143ecd8b86112fabde3edbfb
2.2.2 via: a3bc8b387b0a84add4146af34dcf3bc05f261f26 and
327e584b705036f8ccdb16bd144ba6a7b0d2b920
1.20.0 via: 6dedeca4010686dd4cfc83b5050625e6f3a04075 and
5e280bca97dbdc0196763fe7e21c812fb71e8483
was (Author: fanrui):
Merged to master(2.4.0) via: 56dfbeb423a9884b4def84fa155ac21fc4e4a30e and
96f55807499550d89ddfb90d928811cd8cc09370
2.3.1 via: edf5916ce4e42ec80f4ce43b45aa1cd8eeeeaf84 and
3ccd4e92d7b4bd62143ecd8b86112fabde3edbfb
2.2.2 via: a3bc8b387b0a84add4146af34dcf3bc05f261f26 and
327e584b705036f8ccdb16bd144ba6a7b0d2b920
1.20.0 via:
> FORWARD-to-REBALANCE downgrade compares producer parallelism with the number
> of subpartitions instead of the consumer parallelism
> ---------------------------------------------------------------------------------------------------------------------------------
>
> Key: FLINK-40904
> URL: https://issues.apache.org/jira/browse/FLINK-40904
> Project: Flink
> Issue Type: Bug
> Components: Runtime / Task
> Reporter: Rui Fan
> Assignee: Rui Fan
> Priority: Major
> Labels: pull-request-available
>
> FLINK-30213 replaces a ForwardPartitioner with a RebalancePartitioner in
> StreamTask when the producer and consumer parallelism of a FORWARD edge
> differ. It detects the mismatch by comparing the producer parallelism with
> ResultPartitionWriter#getNumberOfSubpartitions(), but on a POINTWISE edge
> that is the number of consumer subtasks connected to one producer subtask,
> not the consumer parallelism.
> This was found in
> https://github.com/apache/flink/pull/29272#discussion_r4088147465.
> The check is wrong in both directions:
> - False positive: equal parallelism > 1 (e.g. 4 -> 4) gives 1 subpartition
> per producer, so it is treated as a mismatch. This was harmless so far
> because a rebalance over a single channel behaves like forward.
> - False negative: with the DefaultScheduler and
> pipeline.jobvertex-parallelism-overrides, 2 -> 4 gives 2 subpartitions per
> producer, so the mismatch is not detected. The forward partitioner is kept,
> and half of the consumer subtasks receive no data.
> Fix: pass the parallelism of the consuming job vertices to the task via
> ResultPartitionDeploymentDescriptor, and use it for the check.
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)