[
https://issues.apache.org/jira/browse/FLINK-40677?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18116093#comment-18116093
]
David Peacock commented on FLINK-40677:
---------------------------------------
The operator side is already correct — {{FlinkConfigBuilder}} omits
{{pipeline.jars}} when there is no {{jarURI}}. The fix needed is FLINK-33926 in
the bundled client.
Upgrading that client is not a straight bump: 2.1.3 and 2.3.0 both fail a clean
compile of {{flink-kubernetes-standalone}} (11 errors) and move savepoint keys
to {{execution.state-recovery.*}}.
FLINK-33926 also patches {{KubernetesApplicationClusterEntrypoint}}, which
ships in the runtime image, so the image needs the fix too. It landed in 2.0.1,
not 2.0.0, and {{FlinkVersion}} has no patch granularity — so a {{v2_0}} floor
would admit a 2.0.0 image that passes the client check and then fails at
JobManager startup.
I backported FLINK-33926 onto 1.20.4 and ran a patched operator against kind,
with one frozen {{FlinkDeployment}} and one image across all phases.
Classpath-only submission reaches RUNNING and checkpoints, ordinary-JAR
submission is unaffected, and savepoint migration in both directions works. The
persisted JobGraph shows {{userJars=0}} with no BLOB keys, so no JAR is
redistributed.
> Native application submission without jarURI fails in bundled Flink client
> --------------------------------------------------------------------------
>
> Key: FLINK-40677
> URL: https://issues.apache.org/jira/browse/FLINK-40677
> Project: Flink
> Issue Type: Bug
> Components: Kubernetes Operator
> Reporter: David Peacock
> Priority: Major
>
> [FLINK-33926|https://issues.apache.org/jira/browse/FLINK-33926] supports
> running native Kubernetes applications from the image’s system classpath
> without a submitted JAR. The operator’s older bundled client still blocks
> this path, even when the target runtime contains the fix.
> *Setup:* downstream Operator {{{}1.15-SNAPSHOT{}}}, embedded Flink client
> {{{}1.20.1{}}}, target runtime based on Flink {{{}2.3.0{}}}.
> With the application in {{{}/opt/flink/lib{}}}, an explicit
> {{{}job.entryClass{}}}, and no {{job.jarURI}} or inherited
> {{{}pipeline.jars{}}}, the client fails before JobManager creation:
> * Absent {{{}pipeline.jars{}}}: {{NullPointerException}} in
> {{KubernetesUtils.checkJarFileForApplicationMode()}} at
> {{{}configuration.get(PipelineOptions.JARS).stream(){}}}.
> * Empty list: {{{}IllegalArgumentException: Should only have one jar{}}}.
> Reproduced through the real upstream {{1.20.1}} native descriptor with
> Kubernetes calls stubbed.
> *Expected:* classpath-only submission for compatible runtimes, avoiding
> redistribution of an application JAR already present in the image.
> Could the operator consume fixed client code, with regression coverage
> through the real native descriptor?
--
This message was sent by Atlassian Jira
(v8.20.10#820010)