[JBoss Tools] - Eclipse works, Run doesn't?
by Matt Stockbridge
Matt Stockbridge [https://community.jboss.org/people/mstockbr] created the discussion
"Eclipse works, Run doesn't?"
To view the discussion, visit: https://community.jboss.org/message/744399#744399
--------------------------------------------------------------
I've run into an interesting (read: "agrivating") problem: I can run an instance of JBoss with my .ear just fine from Eclipse using the JBoss tools, but if I try to deploy it by throwing what's in the deploy folder in the Eclipse project into the default/deploy folder in JBoss and running using run.conf.bat I run into some rather nasty JMS problems with one of four queues:
10:50:51,750 ERROR [org.hornetq.ra.HornetQRASessionFactoryImpl] Could not create session: javax.jms.IllegalStateException: Only allowed one session per connection. See the J2EE spec, e.g. J2EE1.4 Section 6.6
at org.hornetq.ra.HornetQRASessionFactoryImpl.allocateConnection(HornetQRASessionFactoryImpl.java:816) [:6.1.0.Final]
This, of course, doesn't happen in Eclipse using the JBoss tools. There is literally nothing else (as far as applications not provided by JBoss) on the server. This has worked in the past, but due to the fact that the project in question is being developed quickly and without much support for infrastructure (read: There's one person on it and no supporting resources) determining what's gone wrong is less about rolling back (which might work, but, since I haven't identified the actual problem, might not) and more about process of elimination.
So, why would launching from Eclipse using the tools prevent the above error? Why would that error happen in the first place if the only things referencing the queue are one bean that sends messages in and one that takes them out (a paradigm that works for the other three queues without producing the error)? And, possibly the most unanswerable, why would it previously have worked and not be working now?
I know the typical response is to post everything. I can't do that. But I can post parts. I'm using vanilla JBoss 6.1.0 Final, Eclipse Java EE IDE Indigo SR1, JBoss Seam Tools for Eclipse 3.3.0.v20120302-2019-H81-Beta1, and Java 7.
I've got four queues, in addition to DLQ and ExpiryQueue:
components.xml
<component class="org.jboss.seam.jms.ManagedQueueSender" name="dispatchQueueSender">
<property name="queueJndiName">/queue/RnD/dispatch</property>
</component>
<component class="org.jboss.seam.jms.ManagedQueueSender" name="scheduleQueueSender">
<property name="queueJndiName">/queue/RnD/schedule</property>
</component>
<component class="org.jboss.seam.jms.ManagedQueueSender" name="registerQueueSender">
<property name="queueJndiName">/queue/RnD/register</property>
</component>
<component class="org.jboss.seam.jms.ManagedQueueSender" name="resultsQueueSender">
<property name="queueJndiName">/queue/RnD/results</property>
</component>
hornetq-jms.xml
<queue name="DnR Dispatch">
<entry name="/queue/RnD/dispatch"/>
</queue>
<queue name="DnR Scheduling">
<entry name="/queue/RnD/schedule"/>
</queue>
<queue name="DnR Registration">
<entry name="/queue/RnD/register"/>
</queue>
<queue name="DnR Results">
<entry name="/queue/RnD/results"/>
</queue>
I'm using hibernate in my project with MySQL, and everything is configured as an .ear (with ejb's and a .war inside).
Any thoughts?
-M.
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/744399#744399]
Start a new discussion in JBoss Tools at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
13 years, 8 months
[Snowdrop] - Destroy-method not getting called when JBossAS is shutdown
by Zemian Deng
Zemian Deng [https://community.jboss.org/people/saltnlight5] created the discussion
"Destroy-method not getting called when JBossAS is shutdown"
To view the discussion, visit: https://community.jboss.org/message/750867#750867
--------------------------------------------------------------
Hi there,
I have successfully deployed the snowdrop into JBossAS 7.1.1.FINAL, and I can deploy a simple spring application with jboss-spring.xml as this:
<bean id="helloService" class="deng.HelloService" init-method="start" destroy-method="stop">
</bean>
My HelloService is a simple one like this:
package deng;
import org.slf4j.*;
import java.util.concurrent.atomic.*;
public class HelloService {
private static Logger logger = LoggerFactory.getLogger(HelloService.class);
private AtomicBoolean started = new AtomicBoolean(false);
public boolean isStarted() { return started.get(); }
public void start() { started.set(true); logger.info("started."); }
public void stop() { started.set(false); logger.info("stopped."); }
}
When I package this into my.jar, the server deployed it fine. However when I shutdwon the server with CTRL+C (or with CLI), the stop() is never called. Is this a bug?
Thanks,
Zemian Deng
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/750867#750867]
Start a new discussion in Snowdrop at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
13 years, 8 months
[jBPM] - Human Task , task table deleted every time, when I restart the jbpm-install demo application..
by Sam Mano
Sam Mano [https://community.jboss.org/people/artist123] created the discussion
"Human Task , task table deleted every time, when I restart the jbpm-install demo application.."
To view the discussion, visit: https://community.jboss.org/message/750764#750764
--------------------------------------------------------------
*+Hi,+*
*+I try to install jbpm5.3 installer, afer some persistence related fixes, It is working fine.+*
*+but I have one problem, each time when I stop and start the demo.db, all the records in task table get deleted, even though some reserved data is there it deletes all.+*
*+please advise me, how to prevent this, below is my task service persistence.xml...........+*
+*thanks,*+
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<persistence version="1.0"
xsi:schemaLocation=" http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence
http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd
http://java.sun.com/xml/ns/persistence/orm http://java.sun.com/xml/ns/persistence/orm http://java.sun.com/xml/ns/persistence/orm_1_0.xsd http://java.sun.com/xml/ns/persistence/orm_1_0.xsd"
xmlns:orm=" http://java.sun.com/xml/ns/persistence/orm http://java.sun.com/xml/ns/persistence/orm"
xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance http://www.w3.org/2001/XMLSchema-instance"
xmlns=" http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence">
<persistence-unit name="org.jbpm.task">
<provider>org.hibernate.ejb.HibernatePersistence</provider>
<non-jta-data-source>java:jboss/datasources/taskDS</non-jta-data-source>
<mapping-file>META-INF/Taskorm.xml</mapping-file>
<class>org.jbpm.task.Attachment</class>
<class>org.jbpm.task.BooleanExpression</class>
<class>org.jbpm.task.Comment</class>
<class>org.jbpm.task.Content</class>
<class>org.jbpm.task.Deadline</class>
<class>org.jbpm.task.Delegation</class>
<class>org.jbpm.task.EmailNotification</class>
<class>org.jbpm.task.EmailNotificationHeader</class>
<class>org.jbpm.task.Escalation</class>
<class>org.jbpm.task.Group</class>
<class>org.jbpm.task.I18NText</class>
<class>org.jbpm.task.Notification</class>
<class>org.jbpm.task.OnAllSubTasksEndParentEndStrategy</class>
<class>org.jbpm.task.OnParentAbortAllSubTasksEndStrategy</class>
<class>org.jbpm.task.PeopleAssignments</class>
<class>org.jbpm.task.Reassignment</class>
<class>org.jbpm.task.Status</class>
<class>org.jbpm.task.SubTasksStrategy</class>
<class>org.jbpm.task.Task</class>
<class>org.jbpm.task.TaskData</class>
<class>org.jbpm.task.User</class>
<properties>
<!--
<property name="hibernate.dialect" value="org.hibernate.dialect.H2Dialect"/>
-->
<property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect"/>
<property name="hibernate.max_fetch_depth" value="3"/>
<property name="hibernate.hbm2ddl.auto" value="update" />
<property name="hibernate.show_sql" value="false" />
<!-- for AS7 -->
<property name="hibernate.transaction.manager_lookup_class" value="org.jbpm.integration.console.JBPMTransactionManager" />
<!-- for AS5 -->
<!-- <property name="hibernate.transaction.manager_lookup_class" value="org.hibernate.transaction.JBossTransactionManagerLookup" /> -->
</properties>
</persistence-unit>
</persistence>
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/750764#750764]
Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
13 years, 8 months