Lucene Directory Cache with FileStore
teacurran Jul 17, 2015 2:33 PMI have the following configuration which is working in WildFly 8 with Hibernate Search:
<cache-container name="hibernateSearch" default-cache="LuceneIndexesData"> <transport lock-timeout="330000"/> <replicated-cache name="LuceneIndexesMetadata" mode="SYNC" remote-timeout="330000"> <locking striping="false" acquire-timeout="330000" concurrency-level="500"/> <transaction mode="NONE"/> <eviction strategy="NONE" max-entries="-1"/> <expiration max-idle="-1"/> <state-transfer enabled="true" timeout="480000"/> <file-store preload="true" purge="false" passivation="false" relative-to="jboss.home.dir" path="standalone/data/infinispan-file-store"> <write-behind/> </file-store> <indexing index="NONE"/> </replicated-cache> <replicated-cache name="LuceneIndexesData" mode="SYNC" remote-timeout="25000"> <locking striping="false" acquire-timeout="330000" concurrency-level="500"/> <transaction mode="NONE"/> <eviction strategy="NONE" max-entries="-1"/> <expiration max-idle="-1"/> <state-transfer enabled="true" timeout="480000"/> <file-store preload="true" purge="false" passivation="false" relative-to="jboss.home.dir" path="standalone/data/infinispan-file-store"> <write-behind/> </file-store> <indexing index="NONE"/> </replicated-cache> <replicated-cache name="LuceneIndexesLocking" mode="SYNC" remote-timeout="25000"> <locking striping="false" acquire-timeout="330000" concurrency-level="500"/> <transaction mode="NONE"/> <eviction strategy="NONE" max-entries="-1"/> <expiration max-idle="-1"/> <state-transfer enabled="true" timeout="480000"/> <indexing index="NONE"/> </replicated-cache> </cache-container>
When if I try to run this same configuration on WildFly 9 it gives the following exception:
20:57:31,021 ERROR [org.jboss.msc.service.fail] (ServerService Thread Pool -- 23) MSC000001: Failed to start service jboss.persistenceunit."application-1.0-SNAPSHOT-exploded.war#searchexperiment": org.jboss.msc.service.StartException in service jboss.persistenceunit."application-1.0-SNAPSHOT-exploded.war#searchexperiment": org.hibernate.search.exception.SearchException: HSEARCH000103: Unable to initialize IndexManager named 'com.wirelust.experiment.hibernatesearch.model.City' 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:665) 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: org.hibernate.search.exception.SearchException: HSEARCH000103: Unable to initialize IndexManager named 'com.wirelust.experiment.hibernatesearch.model.City' at org.hibernate.search.indexes.impl.IndexManagerHolder.createIndexManager(IndexManagerHolder.java:260) 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:66) at org.hibernate.internal.SessionFactoryObserverChain.sessionFactoryCreated(SessionFactoryObserverChain.java:52) at org.hibernate.internal.SessionFactoryImpl.<init>(SessionFactoryImpl.java:588) at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1859) at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl$4.perform(EntityManagerFactoryBuilderImpl.java:857) at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl$4.perform(EntityManagerFactoryBuilderImpl.java:850) at org.hibernate.boot.registry.classloading.internal.ClassLoaderServiceImpl.withTccl(ClassLoaderServiceImpl.java:425) at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:849) at org.jboss.as.jpa.hibernate4.TwoPhaseBootstrapImpl.build(TwoPhaseBootstrapImpl.java:44) at org.jboss.as.jpa.service.PersistenceUnitServiceImpl$1$1.run(PersistenceUnitServiceImpl.java:154) ... 7 more Caused by: org.infinispan.commons.marshall.NotSerializableException: Object of type class org.infinispan.lucene.FileListCacheKey expected to be marshallable
This error only happens when using file-store.
Is this not supported for Lucene File System anymore?
Or is is there something specific I have to do to configure it?
Is this a question for the Hibernate Search team and not the Infinispan team?