I suggest also reading: Principles of Transaction Processing Operating Systems: Design and Implementation Links to the books in Amazon.com attached You'll find here some other solutions to aviod deadlocks, such as resource locking graphs, semaphore algorithms, etc However, deadlocks don't ocurr in Orion (AFAIK), but they're trapped and some/all of the offending transactions fail... Like it's supposed to! This is the exception that orion throws, that is, a possible deadlock is detected, and the system prevents it by rollbacking a transaction; However, taking a closer look to the error, I notice it's thrown in ejbPassivate, thus, you must be acquiring a reference to a bean within a Stateful Session Bean... IMHO, a possible design error... Try to avoid Stateful SB whenever possible; they're long lived and almost never get destroyed, thus, locks acquired within actually will block sucesive calls on the same entities indefinetly My 2c (that's 4c so far), JP -----Original Message----- From: Juan Lorandi (Chile) [mailto:[EMAIL PROTECTED]] Sent: Martes, 14 de Noviembre de 2000 13:21 To: Orion-Interest Subject: RE: DeadlockException This is a problem I've faced before... It Orion, protecting your data consistency (I LOVE THIS SERVER!!!!!) You'll see, the spirit of transaction processing is the management of resources. There's something known as transaction isolation, I figure that in your app it is set to 'SERIALIZABLE' Whenever there's stress on the server(a lotta HTTP connections targeting dinamic pages), this kind of problem should arise... To avoid, try to keep your jsp code-free, that is, perform in EJB as many work as you can, defining very granular methods( I use Stateless Session Beans for this), then call these methods from jsp... Another workaround, at the cost of less data consistency, is to change the isolation level to 'COMMITED'. If you stress test your app further, you'll discover that orion starts to choke, eating up DB connections and not releasing them (I use CMP), refer to bug #161 in bugzilla for a complete description My 2c, JP -----Original Message----- From: Adam Cassar [mailto:[EMAIL PROTECTED]] Sent: Martes, 14 de Noviembre de 2000 8:55 To: Orion-Interest Subject: DeadlockException Does anyone know what the following error means? 11/14/00 10:51 PM Error in bean com.netregistry.aucom.accounting.BillingAccount: Error in ejbPassivate com.evermind.server.DeadlockException: Deadlock detected: thread 11 is waiting for resource entity 1003 held by thread 11 Any ideas on how to track it down?
Principles of Transaction Processing (Morgan Kaufman Series in Data Management Systems).url
