I was able to skip this useless processing of cascades, by clearing the session 
(entitymanager.clear()) before returning. 

Using trace logging, i found out that the 9 seconds were all used to handle 
about 400 entities. Hibernate, i think you got a little problem here. Note: 
with trace logging enabled it took over 2 minutes.

2006-09-26 13:01:10,410 TRACE [org.hibernate.transaction.CacheSynchronization] 
transaction before completion callback
2006-09-26 13:01:10,410 TRACE [org.hibernate.jdbc.JDBCContext] before 
transaction completion
2006-09-26 13:01:10,410 TRACE [org.hibernate.impl.SessionImpl] before 
transaction completion
2006-09-26 13:01:10,410 TRACE [org.hibernate.ejb.AbstractEntityManagerImpl] 
automatically flushing session
2006-09-26 13:01:10,410 TRACE [org.hibernate.impl.SessionImpl] automatically 
flushing session
2006-09-26 13:01:10,410 TRACE 
[org.hibernate.event.def.AbstractFlushingEventListener] flushing session
2006-09-26 13:01:10,410 DEBUG 
[org.hibernate.event.def.AbstractFlushingEventListener] processing flush-time 
cascades
...
2006-09-26 13:03:49,101 TRACE 
[org.hibernate.event.def.AbstractFlushingEventListener] Processing unreferenced 
collections
2006-09-26 13:03:49,101 TRACE 
[org.hibernate.event.def.AbstractFlushingEventListener] Scheduling collection 
removes/(re)creates/updates
2006-09-26 13:03:49,101 DEBUG 
[org.hibernate.event.def.AbstractFlushingEventListener] Flushed: 0 insertions, 
0 updates, 0 deletions to 418 objects
2006-09-26 13:03:49,101 DEBUG 
[org.hibernate.event.def.AbstractFlushingEventListener] Flushed: 0 
(re)creations, 0 updates, 0 removals to 417 collections
2006-09-26 13:03:49,101 DEBUG [org.hibernate.pretty.Printer] listing entities:




View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3974187#3974187

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3974187
_______________________________________________
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to