[ 
https://issues.apache.org/jira/browse/FLINK-2161?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14585865#comment-14585865
 ] 

ASF GitHub Bot commented on FLINK-2161:
---------------------------------------

Github user tillrohrmann commented on a diff in the pull request:

    https://github.com/apache/flink/pull/805#discussion_r32415084
  
    --- Diff: 
flink-staging/flink-scala-shell/src/main/scala/org.apache.flink/api/scala/FlinkShell.scala
 ---
    @@ -44,6 +46,16 @@ object FlinkShell {
               c.copy (host = x)
           }  text("host specifies host name of running JobManager")
     
    +      opt[(String)] ('a',"addclasspath") action {
    +        case (x,c) =>
    +          val xArray = x.split(":")
    +          var extJarArray = new Array[String](xArray.length)
    +          for(i <- 0 to xArray.length - 1){
    +            extJarArray(i) = xArray(i)
    +          }
    --- End diff --
    
    Why do you copy `xArray` here? And why not simply calling `xArray.clone`?


> Flink Scala Shell does not support external jars (e.g. Gelly, FlinkML)
> ----------------------------------------------------------------------
>
>                 Key: FLINK-2161
>                 URL: https://issues.apache.org/jira/browse/FLINK-2161
>             Project: Flink
>          Issue Type: Improvement
>            Reporter: Till Rohrmann
>            Assignee: Nikolaas Steenbergen
>
> Currently, there is no easy way to load and ship external libraries/jars with 
> Flink's Scala shell. Assume that you want to run some Gelly graph algorithms 
> from within the Scala shell, then you have to put the Gelly jar manually in 
> the lib directory and make sure that this jar is also available on your 
> cluster, because it is not shipped with the user code. 
> It would be good to have a simple mechanism how to specify additional jars 
> upon startup of the Scala shell. These jars should then also be shipped to 
> the cluster.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to