-->
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.  [ 3 posts ] 
Author Message
 Post subject: MBean restarting with each session
PostPosted: Tue Jun 22, 2004 12:37 pm 
Beginner
Beginner

Joined: Fri Sep 05, 2003 7:21 am
Posts: 27
Location: Sweden
Hi,

I have this strange situation - my JBoss MBean is restarting upon each opening of a net.sf.hibernate.Session.

hibernate-service.xml:
Code:
<mbean code="net.sf.hibernate.jmx.HibernateService" name="jboss.jca:service=Hibernate">
      <depends>jboss.jca:service=RARDeployer</depends>
      <depends>jboss.jca:service=LocalTxCM,name=cellmera/core/DataSource</depends>
      <attribute name="JndiName">java:/cellmera/core/HibernateFactory</attribute>
      <attribute name="Datasource">java:/cellmera/core/DataSource</attribute>
      <attribute name="Dialect">net.sf.hibernate.dialect.PostgreSQLDialect</attribute>
      <attribute name="MapResources">
com/gosa/cellmera/core/classes/User.hbm.xml
com/gosa/cellmera/core/classes/Role.hbm.xml
com/gosa/cellmera/core/classes/Permission.hbm.xml
      </attribute>
      <attribute name="TransactionStrategy">net.sf.hibernate.transaction.JTATransactionFactory</attribute>
      <attribute name="TransactionManagerLookupStrategy">net.sf.hibernate.transaction.JBossTransactionManagerLookup</attribute>
      <attribute name="UserTransactionName">java:/UserTransaction</attribute>
      <attribute name="ShowSql">true</attribute>
</mbean>


UserServiceBean.java:[code]

public void setSessionContext(SessionContext sessionContext) {
this.sessionContext = sessionContext;
try {
System.out.println("DEBUG: UserServiceBean s


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 22, 2004 9:55 pm 
Beginner
Beginner

Joined: Fri Sep 05, 2003 7:21 am
Posts: 27
Location: Sweden
Solved it.

Upgrading from 2.0.x, I had not added

Code:
<attribute name="CacheProvider">net.sf.ehcache.hibernate.Provider</attribute>


to the hibernate-service config. Adding this (along with ehcache.jar) solved the problem.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jun 23, 2004 12:51 pm 
Beginner
Beginner

Joined: Fri Sep 05, 2003 7:21 am
Posts: 27
Location: Sweden
Bummer.

It's back again.

I'll repost in the System Integration forum, as that probably is a more proper place to discuss it.


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

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.