fsk119 commented on code in PR #25674:
URL: https://github.com/apache/flink/pull/25674#discussion_r1855702405


##########
flink-kubernetes/src/main/java/org/apache/flink/kubernetes/entrypoint/KubernetesApplicationClusterEntrypoint.java:
##########
@@ -146,14 +148,15 @@ private static ArtifactFetchManager.Result 
fetchArtifacts(Configuration configur
             String targetDir = generateJarDir(configuration);
             ArtifactFetchManager fetchMgr = new 
ArtifactFetchManager(configuration, targetDir);
 
-            List<String> uris = configuration.get(PipelineOptions.JARS);
-            checkArgument(uris.size() == 1, "Should only have one jar");
+            List<String> uris =
+                    
configuration.getOptional(PipelineOptions.JARS).orElse(Collections.emptyList());
+            checkArgument(uris.size() <= 1, "Should only have at most one 
jar");

Review Comment:
   I think SQL Program is much similar to the Jar Program rather than Python 
Program: 
   * Python uses zip or py files to run the application, but SQL Program uses 
jar to run the applicaiton. 
   * Python Program has its own dependencies management through python.files, 
but SQL Program prefers to use deployment to upload files and use the 
PackagedProgram to build the required environment.
   
   Considering SQL Program is much like Jar Prograom, do we need to add a 
if-else branch for SQL Program, which may introduce some duplicate codes.
   
   On the other hand, I think it's possible that some users may put some jars 
in the image. The change can also reduce the cost for users to play with 
application mode(they don't need to upload files every time).
   
   



-- 
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: issues-unsubscr...@flink.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to