Re: Scala version compatibility
i think it will work then assuming the callsite hasnt changed between scala versions On Mon, Apr 6, 2020 at 5:09 PM Andrew Melo wrote: > Hello, > > On Mon, Apr 6, 2020 at 3:31 PM Koert Kuipers wrote: > >> actually i might be wrong about this. did you declare scala to be a >> provided dependency? so scala is not in your fat/uber jar? if so then maybe >> it will work. >> > > I declare spark to be a provided dependency, so Scala's not included in my > artifact except for this single callsite. > > Thanks > Andrew > > >> On Mon, Apr 6, 2020 at 4:16 PM Andrew Melo wrote: >> >>> >>> >>> On Mon, Apr 6, 2020 at 3:08 PM Koert Kuipers wrote: >>> yes it will >>> Ooof, I was hoping that wasn't the case. I guess I need to figure out >>> how to get Maven to compile/publish jars with different >>> dependencies/artifactIDs like how sbt does? (or re-implement the >>> functionality in java) >>> >>> Thanks for your help, >>> Andrew >>> >>> On Mon, Apr 6, 2020 at 3:50 PM Andrew Melo wrote: > Hello all, > > I'm aware that Scala is not binary compatible between revisions. I > have some Java code whose only Scala dependency is the transitive > dependency through Spark. This code calls a Spark API which returns a > Seq, which I then convert into a List with > JavaConverters.seqAsJavaListConverter. Will this usage cause binary > incompatibility if the jar is compiled in one Scala version and executed > in > another? > > I tried grokking > https://docs.scala-lang.org/overviews/core/binary-compatibility-of-scala-releases.html, > and wasn't quite able to make heads or tails of this particular case. > > Thanks! > Andrew > > >
Re: Scala version compatibility
Hello, On Mon, Apr 6, 2020 at 3:31 PM Koert Kuipers wrote: > actually i might be wrong about this. did you declare scala to be a > provided dependency? so scala is not in your fat/uber jar? if so then maybe > it will work. > I declare spark to be a provided dependency, so Scala's not included in my artifact except for this single callsite. Thanks Andrew > On Mon, Apr 6, 2020 at 4:16 PM Andrew Melo wrote: > >> >> >> On Mon, Apr 6, 2020 at 3:08 PM Koert Kuipers wrote: >> >>> yes it will >>> >>> >> Ooof, I was hoping that wasn't the case. I guess I need to figure out how >> to get Maven to compile/publish jars with different >> dependencies/artifactIDs like how sbt does? (or re-implement the >> functionality in java) >> >> Thanks for your help, >> Andrew >> >> >>> On Mon, Apr 6, 2020 at 3:50 PM Andrew Melo >>> wrote: >>> Hello all, I'm aware that Scala is not binary compatible between revisions. I have some Java code whose only Scala dependency is the transitive dependency through Spark. This code calls a Spark API which returns a Seq, which I then convert into a List with JavaConverters.seqAsJavaListConverter. Will this usage cause binary incompatibility if the jar is compiled in one Scala version and executed in another? I tried grokking https://docs.scala-lang.org/overviews/core/binary-compatibility-of-scala-releases.html, and wasn't quite able to make heads or tails of this particular case. Thanks! Andrew
Re: Scala version compatibility
actually i might be wrong about this. did you declare scala to be a provided dependency? so scala is not in your fat/uber jar? if so then maybe it will work. On Mon, Apr 6, 2020 at 4:16 PM Andrew Melo wrote: > > > On Mon, Apr 6, 2020 at 3:08 PM Koert Kuipers wrote: > >> yes it will >> >> > Ooof, I was hoping that wasn't the case. I guess I need to figure out how > to get Maven to compile/publish jars with different > dependencies/artifactIDs like how sbt does? (or re-implement the > functionality in java) > > Thanks for your help, > Andrew > > >> On Mon, Apr 6, 2020 at 3:50 PM Andrew Melo wrote: >> >>> Hello all, >>> >>> I'm aware that Scala is not binary compatible between revisions. I have >>> some Java code whose only Scala dependency is the transitive dependency >>> through Spark. This code calls a Spark API which returns a Seq, which >>> I then convert into a List with >>> JavaConverters.seqAsJavaListConverter. Will this usage cause binary >>> incompatibility if the jar is compiled in one Scala version and executed in >>> another? >>> >>> I tried grokking >>> https://docs.scala-lang.org/overviews/core/binary-compatibility-of-scala-releases.html, >>> and wasn't quite able to make heads or tails of this particular case. >>> >>> Thanks! >>> Andrew >>> >>> >>>
Re: Scala version compatibility
On Mon, Apr 6, 2020 at 3:08 PM Koert Kuipers wrote: > yes it will > > Ooof, I was hoping that wasn't the case. I guess I need to figure out how to get Maven to compile/publish jars with different dependencies/artifactIDs like how sbt does? (or re-implement the functionality in java) Thanks for your help, Andrew > On Mon, Apr 6, 2020 at 3:50 PM Andrew Melo wrote: > >> Hello all, >> >> I'm aware that Scala is not binary compatible between revisions. I have >> some Java code whose only Scala dependency is the transitive dependency >> through Spark. This code calls a Spark API which returns a Seq, which >> I then convert into a List with >> JavaConverters.seqAsJavaListConverter. Will this usage cause binary >> incompatibility if the jar is compiled in one Scala version and executed in >> another? >> >> I tried grokking >> https://docs.scala-lang.org/overviews/core/binary-compatibility-of-scala-releases.html, >> and wasn't quite able to make heads or tails of this particular case. >> >> Thanks! >> Andrew >> >> >>
Re: Scala version compatibility
Those who followed best practices in software development would start with a clean environment I.e. installation of operating system. Then install development tools keeping a record of version numbers. So that at the time of deployment unforeseen errors are avoided by duplicating development environment , test environment , final client runtime environment. That is now the purpose of docker. So if you want run same source code or byte code in different environments then you should run it. If you can programme and ask this question then you should know how to. On Mon, 6 Apr 2020, 20:50 Andrew Melo, wrote: > Hello all, > > I'm aware that Scala is not binary compatible between revisions. I have > some Java code whose only Scala dependency is the transitive dependency > through Spark. This code calls a Spark API which returns a Seq, which > I then convert into a List with > JavaConverters.seqAsJavaListConverter. Will this usage cause binary > incompatibility if the jar is compiled in one Scala version and executed in > another? > > I tried grokking > https://docs.scala-lang.org/overviews/core/binary-compatibility-of-scala-releases.html, > and wasn't quite able to make heads or tails of this particular case. > > Thanks! > Andrew > > >
Re: Scala version compatibility
yes it will On Mon, Apr 6, 2020 at 3:50 PM Andrew Melo wrote: > Hello all, > > I'm aware that Scala is not binary compatible between revisions. I have > some Java code whose only Scala dependency is the transitive dependency > through Spark. This code calls a Spark API which returns a Seq, which > I then convert into a List with > JavaConverters.seqAsJavaListConverter. Will this usage cause binary > incompatibility if the jar is compiled in one Scala version and executed in > another? > > I tried grokking > https://docs.scala-lang.org/overviews/core/binary-compatibility-of-scala-releases.html, > and wasn't quite able to make heads or tails of this particular case. > > Thanks! > Andrew > > >
Scala version compatibility
Hello all, I'm aware that Scala is not binary compatible between revisions. I have some Java code whose only Scala dependency is the transitive dependency through Spark. This code calls a Spark API which returns a Seq, which I then convert into a List with JavaConverters.seqAsJavaListConverter. Will this usage cause binary incompatibility if the jar is compiled in one Scala version and executed in another? I tried grokking https://docs.scala-lang.org/overviews/core/binary-compatibility-of-scala-releases.html, and wasn't quite able to make heads or tails of this particular case. Thanks! Andrew