peiyu created FLINK-41653:
-----------------------------
Summary: Produce the per-version dist from a line-parameterized
dist module
Key: FLINK-41653
URL: https://issues.apache.org/jira/browse/FLINK-41653
Project: Flink
Issue Type: Sub-task
Components: Flink CDC
Affects Versions: cdc-3.7.0
Reporter: peiyu
h2. Purpose
One dist module produces the distribution of whichever Flink line is being
built: {{flink-cdc-dist-flink-1.20}} / {{flink-cdc-dist-flink-2.2}} and the
{{flink-cdc-<version>-flink-<line>-bin}} tarball - the Paimon/Fluss artifact
shape, where the artifactId carries the line and the version string stays
clean. No per-line module clones, no gating properties.
h2. Changes
* New root property {{flink.line}} (default 1.20, {{flink2}} profile -> 2.2);
the dist artifactId becomes {{flink-cdc-dist-flink-${{{flink.line}}}}} and the
assembly finalName follows.
* The Yarn dist-jar lookup derives the Flink line at runtime from the running
jar's own name ({{flink-cdc-dist-flink-<ver>-*.jar}}, legacy names understood,
unidentifiable shapes fail loudly) instead of the build-time filtered resource:
a single build-time value cannot serve two same-generation releases, while
self-identifying jars always answer for themselves. Side effect: the composer
jar becomes generation-neutral.
* The dist additionally depends on the thin module
{{flink-cdc-flink-${{{flink.line}}}}} (compile), so a future thin-module class
wins the shade priority over the common module.
* Release script: two-line invocation + transition-period legacy-named
artifacts; update_version.sh, Dockerfile ARG, .gitignore
({{release-artifacts/}}), pipeline-e2e dist selection via a
{{flink.dist.artifactId}} property.
* Preserved as-is: the dist keeps its generation-specific guava dependency
(module-local, as today).
h2. Verification
Dual-generation builds; jar-level comparison of the dist fat jar against the
pre-refactor artifact of the matching line (class content identical, GAV
metadata aside); Yarn lookup unit tests (exact / generation mismatch /
ambiguity / legacy fallback); e2e via CI.
h2. Dependencies
After the compat-layer split (thin modules exist). Independent of the
reflection sub-task.
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)