Hello devs,

I saw quite some examples when customers were confused about run​, and run-
application​ in the Flink CLI and I was wondering about the necessity of 
deploying
Application Mode (AM) jobs with a different command, than Session and Per-Job 
mode jobs.

I can see a point that YarnDeploymentTarget​ [1] and KubernetesDeploymentTarget​
[2] are part of their own maven modules and not known in flink-clients​, so the
deployment mode validations are happening during cluster deployment in their 
specific
ClusterDescriptor​ implementation [3]. Although these are implementation 
details that
IMO should not define user-facing APIs.

The command line setup is the same for both run​ and run-application​, so I 
think there
is a quite simple way to achieve a unified flink run​ experience, but I might 
missed
something so I would appreciate any inputs on this topic.

Based on my assumptions I think it would be possible to deprecate the run-
application​ in Flink 1.20 and remove it completely in Flink 2.0. I already put 
together a
PoC [4], and I was able to deploy AM jobs like this:

flink run --target kubernetes-application ...​

If others also agree with this, I would be happy to open a FLIP. WDYT?

Thanks,
Ferenc

[1] 
https://github.com/apache/flink/blob/master/flink-yarn/src/main/java/org/apache/flink/yarn/configuration/YarnDeploymentTarget.java
[2] 
https://github.com/apache/flink/blob/master/flink-kubernetes/src/main/java/org/apache/flink/kubernetes/configuration/KubernetesDeploymentTarget.java
[3] 
https://github.com/apache/flink/blob/48e5a39c9558083afa7589d2d8b054b625f61ee9/flink-kubernetes/src/main/java/org/apache/flink/kubernetes/KubernetesClusterDescriptor.java#L206
[4] 
https://github.com/ferenc-csaky/flink/commit/40b3e1b998c7a4273eaaff71d9162c9f1ee039c0

Reply via email to