[jboss-user] [EJB/JBoss] - Commit Option D and ctx locks
pcarrollnf
do-not-reply at jboss.com
Mon Oct 15 15:05:00 EDT 2007
I have a one to many relationship configured. I know that the foreign key column in my many table has to allow for NULL values according to the EJB spec. As far as I know an INSERT occurs that populates the row except for the foreign key value. Then an UPDATE occurs populating the foreign key. I also have commit-option d configured for these 2 entity beans with a cache refresh of 5 minutes. When I perform several inserts into the many table, it appears that, at times, the UPDATE to populate the foreign key does not occur leaving the foreign key value NULL. I believe it is due to the fact that the cache is refreshing at the same time the UPDATE is being attempted. I see a few Unable to passivate due to ctx lock, id=32901 warnings around the time this occurs. By reducing the cache refresh time, I can more easily reproduce the issue.
Should I be using a different commit-option? Is there a way I can catch the fact that the foreign key value is never comitted to the database? I am using JBoss 3.2.0. Thanks.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4095378#4095378
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4095378
More information about the jboss-user
mailing list