[hibernate-dev] HSearch + Tika bridge using Wildfly modules

Brett Meyer brmeyer at redhat.com
Fri May 29 23:36:31 EDT 2015


Sanne, I might still be missing something.  Artificer's war does not include any Hibernate ORM, Hibernate Search, or Tika jars.  For Wildfly 8.2, the war's jboss-deployment-structure.xml includes:

<module name="org.hibernate.search.orm" /> (includes tika-parsers-1.6.jar)
<module name="org.apache.tika" slot="1.6"/>
(Also using the org.hibernate module, but that's implicitly added by Wildfly.)

I understand what you're saying about the ORM classloader, but the above still didn't work.  I'm admittedly a little fuzzy on WF module classloading, but I'm wondering if that's not actually making its way into the ORM classloader, even though my war is the persistence unit.

However:

What *does* work is adding '<module name="org.apache.tika" slot="1.6"/>' directly in org.hibernate.search.engine's module.xml.

Apologies if 1.) I'm missing something and/or 2.) that's expected.  I can certainly tweak org.hibernate.search.engine's module.xml with our installer, but that's obviously less than desirable.  Any idea what we might be missing that would allow us to get that to work from the app itself?

Thanks for the help!

----- Original Message -----
> From: "Sanne Grinovero" <sanne at hibernate.org>
> To: "Brett Meyer" <brmeyer at redhat.com>
> Cc: "Hibernate.org" <hibernate-dev at lists.jboss.org>
> Sent: Friday, May 29, 2015 11:00:12 AM
> Subject: Re: HSearch + Tika bridge using Wildfly modules
> 
> Hi Brett,
> we don't include all existing analysers and extensions within the
> WildFly modules. In particular the Apache Tika libraries have a huge
> amount of dependencies, you should choose the ones you need depending
> on what kind of media you intend to parse.
> 
> Include any extension in your "application", we use the Hibernate ORM
> classloader to lookup for extensions so these should be discoverable
> if they are visible to the same classloader having your entities and
> other extensions.
> 
> Sanne
> 
> On 29 May 2015 at 15:28, Brett Meyer <brmeyer at redhat.com> wrote:
> > Hey Sanne!  Artificer has '<module name="org.hibernate.search.orm"
> > services="export" />' defined in its jboss-deployment-structure
> > dependencies.  But, when we try to use it, the following happens.
> >
> > Caused by: java.lang.ClassNotFoundException: org.apache.tika.parser.Parser
> > from [Module "org.hibernate.search.engine:main" from local module loader
> > @6cf76647 (finder: local module finder @665bf734 (roots:
> > /home/brmeyer/IdeaProjects/artificer/installer/target/wildfly-8.2.0.Final/modules,/home/brmeyer/IdeaProjects/artificer/installer/target/wildfly-8.2.0.Final/modules/system/layers/base))]
> >
> > One of our entities uses the built-in TikaBridge.  I figured the search.orm
> > module would bring the necessary Tika jars in with it.  Is there something
> > else we need to add?
> 


More information about the hibernate-dev mailing list