Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!
interp.load.cp(os.Path("/absolute/path/to/file.jar"))import $cp.`/absolute/path/to/file.jar`Maven Dependency¶
Notice that
%%(ininterp.load.ivy) and::(inimport $ivy...) automatically suffix the short version of the current Scala distribution (e.g.,_2.12) to the artifact name. For example, if your current Scala distribution is 2.12, then the following 2 statements are equivalent.interp.load.ivy("org.apache.spark" % "spark-core_2.12" % "2.3.1") interp.load.ivy("org.apache.spark" %% "spark-core" % "2.3.1")This is specific to Scala. You almost never need to use
%%or::when you add a Java library dependency.
import $ivy.`org.apache.spark:spark-sql_2.12:2.4.2`
import $ivy.`org.apache.spark::spark-sql:2.4.2` interp.load.ivy("org.apache.spark" % "spark-core_2.12" % "2.4.2")
interp.load.ivy("org.apache.spark" %% "spark-sql" % "2.4.2")