java - How to depend on two different versions of a library? -


i using elasticsearch , jackrabbit (or...i trying too). jackrabbit seems depending on lucene 3.6.x , elasticsearch depending on 4.3.1. using maven , jboss 7.1.1. lucene 4.3.1 on classpath h*** breaking loose in log because jackrabbit requires older lucene.

how solve this?

you need take conflicting libraries wish use (elastic search , jackrabbit) , make both jboss as7 modules. jboss 7 modular classloading can "contain" each of them own dependencies separate module , expose application api use.

its bit complicated (full docs here) allow have each of them use own version of lucene - each packed module of theor dependency tree.

edit - there's more info on how export of module's content in te jboss modules documentation. want make sure dont export lucene out of of modules


Comments

Popular posts from this blog

How to logout from a login page in asp.net -

Stack level too deep error after upgrade to rails 3.2 and ruby 1.9.3 -