Unable to load class InfinispanDirectoryProvider
mundi Feb 10, 2016 5:42 AMHello,
I'm trying to create a project in wildfly 10 using infinispan as second cache for hibernate.
When deploying my project I get the error
Caused by: org.hibernate.search.engine.service.classloading.spi.ClassLoadingException: Unable to load class [org.infinispan.hibernate.search.spi.InfinspanDirectoryProvider
So I added the depency to my pom file
<dependency> <groupId>org.infinispan</groupId> <artifactId>infinispan-directory-provider</artifactId> <version>8.1.0.Final</version> </dependency>
But this leads to the following error:
11:37:48,876 ERROR [org.jboss.msc.service.fail] (ServerService Thread Pool -- 26) MSC000001: Failed to start service jboss.persistenceunit."accident-w
ildfly10-DVLP.war#accident": org.jboss.msc.service.StartException in service jboss.persistenceunit."accident-wildfly10-DVLP.war#accident": java.lang.L
inkageError: loader constraint violation in interface itable initialization: when resolving method "org.infinispan.lucene.logging.Log_$logger.customIn
terceptorMissingClass()Lorg/infinispan/commons/CacheConfigurationException;" the class loader (instance of org/jboss/modules/ModuleClassLoader) of the
current class, org/infinispan/lucene/logging/Log_$logger, and the class loader (instance of org/jboss/modules/ModuleClassLoader) for interface org/in
finispan/util/logging/Log have different Class objects for the type org/infinispan/commons/CacheConfigurationException used in the signature
at org.jboss.as.jpa.service.PersistenceUnitServiceImpl$1$1.run(PersistenceUnitServiceImpl.java:172)
at org.jboss.as.jpa.service.PersistenceUnitServiceImpl$1$1.run(PersistenceUnitServiceImpl.java:117)
at org.wildfly.security.manager.WildFlySecurityManager.doChecked(WildFlySecurityManager.java:667)
at org.jboss.as.jpa.service.PersistenceUnitServiceImpl$1.run(PersistenceUnitServiceImpl.java:182)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
at org.jboss.threads.JBossThread.run(JBossThread.java:320)
Caused by: java.lang.LinkageError: loader constraint violation in interface itable initialization: when resolving method "org.infinispan.lucene.loggin
g.Log_$logger.customInterceptorMissingClass()Lorg/infinispan/commons/CacheConfigurationException;" the class loader (instance of org/jboss/modules/Mod
uleClassLoader) of the current class, org/infinispan/lucene/logging/Log_$logger, and the class loader (instance of org/jboss/modules/ModuleClassLoader
) for interface org/infinispan/util/logging/Log have different Class objects for the type org/infinispan/commons/CacheConfigurationException used in t
he signature
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:344)
at org.jboss.logging.Logger$1.run(Logger.java:2554)
at java.security.AccessController.doPrivileged(Native Method)
at org.jboss.logging.Logger.getMessageLogger(Logger.java:2529)
at org.jboss.logging.Logger.getMessageLogger(Logger.java:2516)
at org.infinispan.util.logging.LogFactory.getLog(LogFactory.java:21)
at org.infinispan.lucene.impl.DirectoryBuilderImpl.<clinit>(DirectoryBuilderImpl.java:25)
at org.infinispan.lucene.directory.DirectoryBuilder.newDirectoryInstance(DirectoryBuilder.java:25)
at org.infinispan.hibernate.search.spi.InfinispanDirectoryProvider.start(InfinispanDirectoryProvider.java:117)
at org.hibernate.search.indexes.spi.DirectoryBasedIndexManager.initialize(DirectoryBasedIndexManager.java:108)
at org.hibernate.search.indexes.impl.IndexManagerHolder.createIndexManager(IndexManagerHolder.java:256)
at org.hibernate.search.indexes.impl.IndexManagerHolder.createIndexManager(IndexManagerHolder.java:513)
at org.hibernate.search.indexes.impl.IndexManagerHolder.createIndexManagers(IndexManagerHolder.java:482)
at org.hibernate.search.indexes.impl.IndexManagerHolder.buildEntityIndexBinding(IndexManagerHolder.java:91)
at org.hibernate.search.spi.SearchIntegratorBuilder.initDocumentBuilders(SearchIntegratorBuilder.java:358)
at org.hibernate.search.spi.SearchIntegratorBuilder.buildNewSearchFactory(SearchIntegratorBuilder.java:199)
at org.hibernate.search.spi.SearchIntegratorBuilder.buildSearchIntegrator(SearchIntegratorBuilder.java:117)
at org.hibernate.search.hcore.impl.HibernateSearchSessionFactoryObserver.sessionFactoryCreated(HibernateSearchSessionFactoryObserver.java:75)
at org.hibernate.internal.SessionFactoryObserverChain.sessionFactoryCreated(SessionFactoryObserverChain.java:35)
at org.hibernate.internal.SessionFactoryImpl.<init>(SessionFactoryImpl.java:530)
at org.hibernate.boot.internal.SessionFactoryBuilderImpl.__build(SessionFactoryBuilderImpl.java:444)
at org.hibernate.boot.internal.SessionFactoryBuilderImpl.build(SessionFactoryBuilderImpl.java)
at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:879)
at org.jboss.as.jpa.hibernate5.TwoPhaseBootstrapImpl.__build(TwoPhaseBootstrapImpl.java:44)
at org.jboss.as.jpa.hibernate5.TwoPhaseBootstrapImpl.build(TwoPhaseBootstrapImpl.java)
at org.jboss.as.jpa.service.PersistenceUnitServiceImpl$1$1.run(PersistenceUnitServiceImpl.java:154)
... 7 more
So there seems to be a "crash" of the signature of "CacheConfigurationException" in this modul?
Am I missing something? Can anyone help?
Thanks in advance