Is there a way to configure Hibernate Search using the JBoss JMX service configuration (jboss-service.xml)?
I deploy my Hibernate app as a managed service (.har file) under JBoss 4.0.5.GA and as such the hibernate.cfg.xml file is not used. JBoss automatically configures the SessionFactory and places it in the JNDI tree on startup, based on the configuration supplied in the hibernate-service.xml file.
I have not been able to find any information on configuring Hibernate Search via the hibernate-service.xml file.
I need to be able to set the hibernate.search.default.directory_provider_url and hibernate.search.default.indexBase properties, and to configure the post-update, post-insert and post-delete event listeners (I am not using Hibernate Annotations or EntityManager).
At the moment the best I've been able to come up with is to set the directory_provider_url and indexBase properties via a hibernate.properties file, and manually add the 3 event listeners to the session when I open it. I think this is a hack and I don't like it. (I'm also getting some other errors now, and I don't know if they're related to this or something else - work in progress :P).
Is it possible to configure the event listeners in a hibernate.properties file instead? That would be a bit better than manually adding them (although not by much).
I am using:
Hibernate 3.2.4.GA
Hibernate Search 3.0.0.Beta4
JBoss 4.0.5.GA
|