james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Benoit Tellier <btell...@linagora.com>
Subject Re: Use of Lambdas in Cassandra with target.jdk 1.6 [unsigned]
Date Tue, 15 Mar 2016 02:11:55 GMT
Hi Bernd,

A huge +1, I would be so happy to see JDK 1.8 used everywhere in James.
It would allow us to write readable code based on streams everywhere.

For your information, some modules uses a JDK 1.8 :

 - backends/cassandra
 - mailbox/cassandra
 - mailbox/elasticsearch
 - server/data/data-cassandra
 - server/protocols/jmap*
 - mpt/impl/imap-mailbox/cassandra
 - mpt/impl/imap-mailbox/elasticsearch
 - mpt/impl/imap-mailbox/external
 - server/container/cassandra-guice
 - mpt/impl/smtp

You will find in the POM of those project :

 - a build desactivation for JDK older than 1.8. An empty jar will be
 - all the project dependencies included for JDK >= 1.8
 - disable animal sniffer for JDK >= 1.8

So lambas are never used with an other JDK than 1.8. But it means having
a JDK < 1.8 you can not run  ElasticSearch, Cassandra, JMAP, and Guice

By the way, Linagora CI triggers two builds upon our pull requests :

 - One in Java 6 + Spring
 - One in Java 8 + Guice

I would love to have some POM simplification, and build simplification here.


Le 14/03/2016 19:59, Bernd Waibel a écrit :
> Hello together,
> I am trying to compile "james-project", but I am just following Maven errors.
> At this point I did find something, I am not sure if I interpret this correctly.
> The Cassandra implementation uses Lambdas. E.g. in CassandraTableManager.
> The pom.xml of "james-project" does define a target jdk of 1.6:
>         <target.jdk>1.6</target.jdk>
> The pom.xml of backends-common and the pom.xml of backends-cassandra do not redefine
the target.jdk to another level.
> Lamdas (and the used stream objects) are new in JDK 1.8, so a JDK Target of 1.6 for Cassandra
do not seem to be meaningful.
> The Cassandra project should redefine the target.jdk to 1.8, cause it will not compile
with a lower level.
> I would suggest to change the JDK target level for the whole project to a up-to-date
JDK level.
> I personally would prefer to use JDK 1.8 for the whole james-project target.
> (This maybe should be split into 2 tickets).
> Best regards,
> Bernd Waibel

To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org

View raw message