Chenxiao Mao created SPARK-26813:
------------------------------------

             Summary: Consolidate java version across language compilers and 
build tools
                 Key: SPARK-26813
                 URL: https://issues.apache.org/jira/browse/SPARK-26813
             Project: Spark
          Issue Type: Improvement
          Components: Build
    Affects Versions: 2.4.0
            Reporter: Chenxiao Mao


The java version here means versions of javac source, javac target, scalac 
target. They could be consolidated as a single version (currently 1.8)
|| ||javac||scalac||
|source|1.8|2.12/2.11|
|target|1.8|1.8|

The current issues are as follows
 * Maven defines a single property to specify java version (java.version) while 
SBT build defines different properties for javac (javacJVMVersion) and scalac 
(scalacJVMVersion). SBT should use a single property as Maven does.
 * For SBT build, both javac options and scalac options related to java version 
are provided. For Maven build, scala-maven-plugin compiles both Java and Scala 
code. However, javac options related to java version (-source, -target) are 
provided while scalac options related to java version (-target:TARGET) are not 
provided, which means scalac will depend on the default options (jvm-1.8). It's 
better for Maven build to explicitly provide scalac options as well.
 * Furthermore, it's even better for SBT to refer to java.version defined by 
Maven. This is possible since we've already been using sbt-pom-reader.

 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to