You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-user@db.apache.org by Rick Hillegas <Ri...@Sun.COM> on 2008/04/30 23:43:49 UTC

Re: org.apache.derby.client.am.SqlException: A lock

Hi Shaoyong,

For tips on how to avoid deadlocks, please see the "Deadlocks" section 
of the Derby Developer's Guide: 
http://db.apache.org/derby/docs/10.3/devguide/

Hope this helps,
-Rick

Shaoyong Wang wrote:
>
> We are using Derby 10.3.1.4. Occasionally, we saw the following error. 
> Can anybody tell me how to tune Derby to get around this? Thanks.
>
> Caused by: org.apache.derby.client.am.SqlException: A lock could not 
> be obtained due to a deadlock, cycle of locks and waiters is:
>
> …
>
> The selected victim is XID : 2057595.
>
> at org.apache.derby.client.am.Statement.completeExecute(Unknown Source)
>
> at 
> org.apache.derby.client.net.NetStatementReply.parseEXCSQLSTTreply(Unknown 
> Source)
>
> at org.apache.derby.client.net.NetStatementReply.readExecute(Unknown 
> Source)
>
> at org.apache.derby.client.net.StatementReply.readExecute(Unknown Source)
>
> at 
> org.apache.derby.client.net.NetPreparedStatement.readExecute_(Unknown 
> Source)
>
> at org.apache.derby.client.am.PreparedStatement.readExecute(Unknown 
> Source)
>
> at org.apache.derby.client.am.PreparedStatement.flowExecute(Unknown 
> Source)
>
> at org.apache.derby.client.am.PreparedStatement.executeUpdateX(Unknown 
> Source)
>
> ... 79 more
>


Re: org.apache.derby.client.am.SqlException: A lock

Posted by Francois Orsini <fr...@gmail.com>.
Hi Shaoyong,

You can also look at the link below to find out how to debug some locking
situations:
http://wiki.apache.org/db-derby/LockDebugging

Cheers,

--francois

On Wed, Apr 30, 2008 at 2:43 PM, Rick Hillegas <Ri...@sun.com>
wrote:

> Hi Shaoyong,
>
> For tips on how to avoid deadlocks, please see the "Deadlocks" section of
> the Derby Developer's Guide:
> http://db.apache.org/derby/docs/10.3/devguide/
>
> Hope this helps,
> -Rick
>
>
> Shaoyong Wang wrote:
>
> >
> > We are using Derby 10.3.1.4. Occasionally, we saw the following error.
> > Can anybody tell me how to tune Derby to get around this? Thanks.
> >
> > Caused by: org.apache.derby.client.am.SqlException: A lock could not be
> > obtained due to a deadlock, cycle of locks and waiters is:
> >
> > …
> >
> > The selected victim is XID : 2057595.
> >
> > at org.apache.derby.client.am.Statement.completeExecute(Unknown Source)
> >
> > at
> > org.apache.derby.client.net.NetStatementReply.parseEXCSQLSTTreply(Unknown
> > Source)
> >
> > at org.apache.derby.client.net.NetStatementReply.readExecute(Unknown
> > Source)
> >
> > at org.apache.derby.client.net.StatementReply.readExecute(Unknown
> > Source)
> >
> > at org.apache.derby.client.net.NetPreparedStatement.readExecute_(Unknown
> > Source)
> >
> > at org.apache.derby.client.am.PreparedStatement.readExecute(Unknown
> > Source)
> >
> > at org.apache.derby.client.am.PreparedStatement.flowExecute(Unknown
> > Source)
> >
> > at org.apache.derby.client.am.PreparedStatement.executeUpdateX(Unknown
> > Source)
> >
> > ... 79 more
> >
> >
>