A broker can only handle one tx at a time.
To avoid conflicts with multiple users opening broker transactions in parallel you simply have to use one broker per user request.
please study the literature and tutorials on ojb + struts best practices: http://db.apache.org/ojb/links.html
cheers, Thomas
Denis Avdic wrote:
Hi,
I am using OJB with Struts and I have a number of actions that use persistence broker calls to retrieve and store data.
Now, if I have a number of users using the application, all users share the same broker. Thus I get collisions where one user would begin a transaction then another would begin a transaction (and get an exception) and then first user would commit transaction, and when the second user would try to commit transaction I get an error.
What can I do to fix this, is there anything in the configuration I can do, or does anyone have a trick for this?
my broker is a regular broker I get by calling PersistenceBrokerFactory.defaultPersistenceBroker();
TIA,
Denis
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
