-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Hibernate Search + Play! Framework + JMS (activeMQ)
PostPosted: Thu Jan 29, 2015 11:41 am 
Newbie

Joined: Thu Jan 29, 2015 10:52 am
Posts: 2
We have successfully integrated the hibernate search with our Play application, working on a single server.
We ran into issues moving to a multiple app server environment with handling the index files synced between the servers.
After some research we decided to implement a JMS Master-Slave queue setup.

We have activeMQ running to accept tcp traffic on port 61616.
The issue we are running into is configuring our apps to connect to the JMS queue.

Our app server is configured as follows:

<persistence xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd" version="2.0">

<persistence-unit name="defaultPersistenceUnit" transaction-type="RESOURCE_LOCAL">
<provider>org.hibernate.ejb.HibernatePersistence</provider>
<non-jta-data-source>DefaultDS</non-jta-data-source>
<properties>
<property name="hibernate.dialect" value="org.hibernate.dialect.H2Dialect"/>
<property name="hibernate.hbm2ddl.auto" value="update" />
<property name="hibernate.show_sql" value="true" />
<property name="hibernate.format_sql" value="true" />
<property name="hibernate.ejb.naming_strategy" value="org.hibernate.cfg.DefaultComponentSafeNamingStrategy" />
<property name="hibernate.default_batch_fetch_size" value="400" />

<property name="hibernate.search.default.directory_provider" value="filesystem"/>
<property name="hibernate.search.default.indexBase" value="/var/lucene/indexes" />
<property name="hibernate.search.default.sourceBase" value="/var/lucene/source" />

<property name="hibernate.search.worker.backend" value="jms" />
<property name="hibernate.search.worker.jndi.class" value="org.apache.activemq.jndi.ActiveMQInitialContextFactory" />
<property name="hibernate.search.worker.jndi.url" value="tcp://{$server}:61616" />
<property name="hibernate.search.worker.jms.queue" value="java:comp/env/queue/hibernatesearch" />
<property name="hibernate.search.default.refresh" value="1800" />
<property name="hibernate.search.worker.jms.connection_factory" value="java:comp/env/jms/ConnectionFactory" />

</properties>
</persistence-unit>

Has anyone had experience running JMS with the play framework? Any insight will be helpful.
Thank you in advance.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.