hi,
I am using jboss 3.2.1 with jetty.
When I am trying to create a CMP Entity Bean, the transaction is timing out.
My method call is somewhat like this -
public void createA(HashMap aHash){
Set keySet=aHash.keySet();
Iterator ite=keySet.iterator();
while(ite.hasNext()){
Integer id=(Integer)ite.next();
// here I create a new entity
AHome.create(aHash.get(id));
Collection BList=BHome.findByA(id);
Iterator ite2=BList.iterator();
while(ite2.hasNext()){
BObject bobject=(BObject)ite2.next();
// here I update an entity
bobject.setStatus(2);
}
Collection CList=CHome.findByA(id);
Iterator ite3=CList.iterator();
while(ite3.hasNext()){
CObject cobject=(CObject)ite3.next();
// here I update an entity
cobject.setStatus(2);
}
}
}
All this happens inside a session bean method, which is marked with tx-attribute required. The entity beans are CMP 2.0 and all have a tx-attribute required.
I am using Optimistic Concurrency with version column.
How can I diagnose what is going wrong here ?
Raghu
Hi,
Do a thread dump and find out where it is hanging.
It smells like a transaction deadlock of some sort though.
Steve Coy