Hi, Can you post a thread dump from the deadlock?
My guess would be that we're using the second connection to fetch an ID value from a sequence table. Otherwise, we should not be obtaining multiple. -Patrick On 8/23/07, Christian Defoy <[EMAIL PROTECTED]> wrote: > Hello, > > Quick question about connection usage: > > I was performing some tests and I noticed that my connection pool was > configured for 10 connections but theoretically, I should need only > one so I set the connection pool size to 1. Now, my application > deadlocks because it appears that getEntityManager() requests a > connection and query.getResultList() requests one too. > > When I read section 4.8 "Configuring the Use of JDBC Connections", I > thought that setting openjpa.ConnectionRetainMode to "always" would > have the entity manager retain its connection (that part works fine) > but that it would have the entity manager share that connection with > queries... > > Is there a way to make that happen? My server is kind of counting on > the fact that a single connection is used to process a single > request... > > Christian > -- Patrick Linskey 202 669 5907