-->
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: Exception on ActionQueue with Listeners
PostPosted: Wed May 24, 2006 3:29 pm 
Regular
Regular

Joined: Wed Jan 11, 2006 12:49 pm
Posts: 64
Location: Campinas, Brazil
Hi, fellas
Maybe this problem is related with this other (unanswered) topic: http://forum.hibernate.org/viewtopic.php?t=955629. I am using JBoss 4.0.4.CR2 (shipped with Hibernate 3.2.0 CR2, right?). I have an entity post-persist/update callback method which does some processing, including changing some values on the target entity (a cascaded relationship from the entity upon which I call merge()). The reason I do not use the pre-persist/update callback is a bug that I have reported earlier this month (http://jira.jboss.com/jira/browse/HIBERNATE-36) but no response was given yet. Anyway, after all listeners return I get the following exception:
Code:
Stack trace until my business method:
java.lang.IndexOutOfBoundsException: Index: 1, Size: 0
   at java.util.ArrayList.RangeCheck(ArrayList.java:547)
   at java.util.ArrayList.get(ArrayList.java:322)
   at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:232)
   at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:140)
   at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:297)
   at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:27)
   at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:988)
   at org.hibernate.ejb.AbstractEntityManagerImpl.flush(AbstractEntityManagerImpl.java:271)
   at org.jboss.ejb3.entity.TransactionScopedEntityManager.flush(TransactionScopedEntityManager.java:204)
   at com.diaup.worldnet.negocio.comercial.contrato.ContratoServiceBean.salvar(ContratoServiceBean.java:101)


Just as a test I removed modifications I make in the post callback and the exception is not thrown. Any ideas on what is going on?

_________________
Henrique Sousa
Don't forget to rate useful responses


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.