[JBoss-user] [Persistence & CMP/JBoss] - Re: Locking behaviour unclear

2004-11-18 Thread PhilC
In the situation where 2 transactions set a unidirectional relationship on the same object, the second transaction will lock-up until it timeout. maybe this is the normal CMP behaviour, but it seems like this operation should be possible. The case I'm working on has 2 Tx happen that execute on

[JBoss-user] [Persistence & CMP/JBoss] - Re: Locking behaviour unclear

2004-10-05 Thread tjodolf
So, this would mean that this quote from your documentation is not correct? ÂWhen a bean is marked as read-only, it never takes part in a transaction. This means it is never transactionally locked View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3850411#3850411

[JBoss-user] [Persistence & CMP/JBoss] - Re: Locking behaviour unclear

2004-08-12 Thread loubyansky
A CMR getter does not lock its value. The instances are locked when you iterate through the CMR collection and invoke methods on instances. This intended behaviour for the standard container configuration. Mark CMP getters as read-only. View the original post : http://www.jboss.org/index.html?m

[JBoss-user] [Persistence & CMP/JBoss] - Re: Locking behaviour unclear

2004-08-11 Thread PhilC
Woops I pressed Submit too fast... I would also like to know how easy or dificult this is to change. This feature cause lots of deadlock in my application because the related beans get locked everytime a call to getValueObject is processed. (My value objects contain related beans) I realize that

[JBoss-user] [Persistence & CMP/JBoss] - Re: Locking behaviour unclear

2004-08-11 Thread PhilC
Anybody home? Locking blind-side of unidirectional relationships when calling getter method and ignoring read-only tags for relationship methods. I would like to get a brief summary of why this is the way it is? View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=38

[JBoss-user] [Persistence & CMP/JBoss] - Re: Locking behaviour unclear

2004-07-10 Thread loubyansky
Seems like you are right. Theoretically locking the 'blind' side is not required in this case unless the blind side has a foreign key which is modified. In fact, uni- and bidirectional relationships are managed in the same way. And the blind side still holds the state of the relationship as part

[JBoss-user] [Persistence & CMP/JBoss] - Re: Locking behaviour unclear

2004-07-09 Thread SilvioMatthes
Hello Alexey, thank you for your answer. I understand the lock of the other side (user) if this relation would be bidirectional. But its unidirectional, so from user there is no connection to document. So is the lock really needed, even for unidirectional relations? Silvio View the original p

[JBoss-user] [Persistence & CMP/JBoss] - Re: Locking behaviour unclear

2004-07-09 Thread loubyansky
When you modify one side of the relationship, we have to modify the other one. For that we need a lock. Since you are using pessimistic locking, the lock is pessimistic. In read-only case, locking still happends but only for the duration of the method invocation, not the tx. View the original po