I'm having a hard time getting infinispan to work as the directory provider. First I tried with a multi-node setup. But the requirement for 'preferIpv4' thoroughly broke a component that my app leverages(which btw, I don't think its Hibernate Search's place to enforce that value, I've gotten jgroups to work just fine with ipv6 without it). I temporarily tore the ipv6 dependent component out just for testing, but then with 'preferIpv4' all I got were jgroups errors along the lines of: 'NAKACK dropped message from XYZ not in table'
Then I tried to configure infinispan using a jgroups file I've used in other environments that sets up a UDP channel, but then I ran into:
viewtopic.php?f=9&t=1012338Which is an NPE in JGroups on what should have been a statically initialized field. This error doesn't occur when I don't specify a file and the defaults are used. Something about maven + tomcat + infinispan loading a config file tickles this issue.
Then I tried to go even simpler and tried to use Infinispan with HSearch on just a single node, with all of the defaults. Now I'm getting a bunch of the following errors:
org.apache.lucene.index.MergePolicy$MergeException: java.lang.IndexOutOfBoundsException: Index: 55, Size: 40
at org.apache.lucene.index.ConcurrentMergeScheduler.handleMergeException(ConcurrentMergeScheduler.java:517)
at org.hibernate.search.backend.impl.lucene.overrides.ConcurrentMergeScheduler.handleMergeException(ConcurrentMergeScheduler.java:49)
at org.apache.lucene.index.ConcurrentMergeScheduler$MergeThread.run(ConcurrentMergeScheduler.java:482)
Caused by: java.lang.IndexOutOfBoundsException: Index: 55, Size: 40
java.io.FileNotFoundException: Error loading medatada for index file: _n.cfs|M|Location
at org.infinispan.lucene.InfinispanDirectory.openInput(InfinispanDirectory.java:300)
at org.apache.lucene.store.Directory.openInput(Directory.java:139)
at org.apache.lucene.index.CompoundFileReader.<init>(CompoundFileReader.java:66)
After indexing with all of these errors I'm getting lots of duplicate documents per entity.
HSearch Config:
indexing mode: async
async worker thread pool size: 1
directory provider: infinispan
backend provider: lucene
Environment info:
RHEL 4
Apache Maven 2.2.1
Java version: 1.6.0_21
Maven dependency tree, which I've scrubbed for conflicting Jgroups and Lucene jars
Code:
[INFO] | +- org.hibernate:hibernate-entitymanager:jar:3.6.7.Final:compile
[INFO] | | +- org.hibernate:hibernate-core:jar:3.6.7.Final:compile
[INFO] | | | \- antlr:antlr:jar:2.7.6:compile
[INFO] | | +- cglib:cglib:jar:2.2:compile
[INFO] | | \- org.hibernate.javax.persistence:hibernate-jpa-2.0-api:jar:1.0.1.Final:compile
[INFO] | +- org.hibernate:hibernate-validator:jar:4.1.0.Final:compile
[INFO] | +- org.hibernate:hibernate-search:jar:3.4.1.Final:compile
[INFO] | | +- org.hibernate:hibernate-search-analyzers:jar:3.4.1.Final:compile
[INFO] | | | +- org.apache.lucene:lucene-analyzers:jar:3.1.0:compile
[INFO] | | | \- org.apache.solr:solr-analysis-extras:jar:3.1.0:compile
[INFO] | | | +- org.apache.solr:solr-core:jar:3.1.0:compile
[INFO] | | | | +- org.apache.solr:solr-solrj:jar:3.1.0:compile
[INFO] | | | | +- org.apache.lucene:lucene-highlighter:jar:3.1.0:compile
[INFO] | | | | +- org.apache.lucene:lucene-memory:jar:3.1.0:compile
[INFO] | | | | +- org.apache.lucene:lucene-misc:jar:3.1.0:compile
[INFO] | | | | +- org.apache.lucene:lucene-spatial:jar:3.1.0:compile
[INFO] | | | | +- org.apache.lucene:lucene-spellchecker:jar:3.1.0:compile
[INFO] | | | | \- org.apache.solr:solr-commons-csv:jar:3.1.0:compile
[INFO] | | | +- org.apache.lucene:lucene-smartcn:jar:3.1.0:compile
[INFO] | | | \- org.apache.lucene:lucene-stempel:jar:3.1.0:compile
[INFO] | | +- org.hibernate:hibernate-commons-annotations:jar:3.2.0.Final:compile
[INFO] | | \- org.apache.lucene:lucene-core:jar:3.1.0:compile
[INFO] | +- org.hibernate:hibernate-search-infinispan:jar:3.4.1.Final:compile
[INFO] | | \- org.infinispan:infinispan-lucene-directory:jar:4.2.1.FINAL:compile
[INFO] | | \- org.infinispan:infinispan-core:jar:4.2.1.FINAL:compile
[INFO] | | +- org.jgroups:jgroups:jar:2.12.0.CR5:compile
[INFO] | | +- org.jboss.marshalling:river:jar:1.2.3.GA:compile
[INFO] | | +- org.jboss.marshalling:marshalling-api:jar:1.2.3.GA:compile
[INFO] | | \- org.rhq.helpers:rhq-pluginAnnotations:jar:3.0.1:compile
[INFO] | | \- i18nlog:i18nlog:jar:1.0.10:compile
[INFO] | +- org.hibernate:hibernate-envers:jar:3.6.4.Final:compile
[INFO] | | \- org.hibernate:hibernate-tools:jar:3.2.0.ga:compile
[INFO] | | +- org.beanshell:bsh:jar:2.0b4:compile
[INFO] | | +- freemarker:freemarker:jar:2.3.8:compile
[INFO] | | \- org.hibernate:jtidy:jar:r8-20060801:compile
Hoping one or more of these issues someone has dealt with before, or has an idea of what else to try.
TIA