-->
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.  [ 2 posts ] 
Author Message
 Post subject: Commit at the end of a transaction gets progressively slower
PostPosted: Sat Jun 13, 2009 10:04 pm 
Newbie

Joined: Sat Jun 13, 2009 9:39 pm
Posts: 2
I am using hibernate 3.2.4.sp1, postgres 8.3.7 and Seam 2.1.

I am experiencing a very strange behavior with our application in terms of transaction commit, and I am not able to pinpoint what is causing this. Not even sure if it is hibernate or postgres.

I kick off a an asynchronous job (SLSB annotated with @Asynchronous) from a web request. This method is also annotated with tx not-supported (@TransactionAttribute(TransactionAttributeType.NOT_SUPPORTED)

This method, in a loop, calls another SLSB method which is annotated with tx requires-new. This second bean creates and persists a lot of new entities per call.

The second bean takes that same amount of time per invocation (since it is creating the same number of entities per invocation), however, the entity manager gets progressively slower in committing after the method finishes.

My understanding is that every new ejb transaction gets a brand new EntityManager setup (with out any baggage from previous transaction).

What is going wrong here?. How do I debug this issue.

Thanks in advance
Vijay Gorla


Top
 Profile  
 
 Post subject: Re: Commit at the end of a transaction gets progressively slower
PostPosted: Mon Jun 15, 2009 8:32 pm 
Newbie

Joined: Sat Jun 13, 2009 9:39 pm
Posts: 2
sorry ... my bad
given the complexity of the code, I didn't realize bean2 is actually calling bean3 (SFSB with required tx attribute) to do the actual persisting, which explains why the entitymanager is slowing down.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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:
cron
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.