How to handle conflicting dependencies (old guava and Play 2.6.x)

56 views
Skip to first unread message

georgi....@upnetix.com

unread,
Mar 8, 2018, 7:05:52 AM3/8/18
to Play Framework

I'm upgrading the Play Framework version from 2.5.x to 2.6.x on a project that uses Apache Ignite.

Play 2.5.x depnded on Guava 19.0, while Play 2.6.x depends on Guava 22.0. Apache Ignite depends on Guava 16.0 (and there is no update in sight). Guava 16.0 and Guava 22.0 are a bad mix, so when SBT evicts Guava 16.0 in favor of Guava 22.0 Apache Ignite throws an exception :

java.lang.NoSuchMethodError: com.google.common.util.concurrent.MoreExecutors.sameThreadExecutor()Lcom/google/common/util/concurrent/ListeningExecutorService;


I'm wondering what the best approach to handling a case like this would be. I need to have both versions on my classpath, so Apache Ignite can use Guava 16.0, while the rest of the project can use Guava 22.0.


My best guess right now is that I should move the Apache Ignite logic to a sub-project and use sbt-assembly to shade the guava 16 dependency into an unmanaged jar.


Reply all
Reply to author
Forward
0 new messages