MySQL Forums
Forum List  »  InnoDB

Deadlock found when trying to get lock
Posted by: Rafal Kedziorski
Date: March 31, 2005 12:32AM

Hi,


I'm working with JBoss and MySQL 4.0.22 (and 4.0.18 on Testsystem). But under the load, I get sometimes Exceptions like this:


java.sql.SQLException: Deadlock found when trying to get lock; Try restarting transaction message from server: "Lock wait timeout exceeded; Try restarting transaction"


It looks like InnoDB problem. Is there a way to find out why this happens?


This is my mysql-ds.xml:


<?xml version="1.0" encoding="UTF-8"?>
<datasources>
<local-tx-datasource>
<jndi-name>OmaDS</jndi-name>
<connection-url>jdbc:mysql://localhost/ofa</connection-url>
<driver-class>com.mysql.jdbc.Driver</driver-class>
<user-name>user</user-name>
<password>xxx</password>
<connection-property name="autoReconnect">true</connection-property>


<!-- <transaction-isolation>TRANSACTION_READ_COMMITTED</transaction-isolation> -->


<!--pooling parameters-->
<min-pool-size>25</min-pool-size>
<max-pool-size>100</max-pool-size>
<blocking-timeout-millis>5000</blocking-timeout-millis>
<idle-timeout-minutes>15</idle-timeout-minutes>


<prepared-statement-cache-size>1000</prepared-statement-cache-size>
</local-tx-datasource>
</datasources>


Our beans are configured to make SELECT ... FOR UPDATE calls.



Best Regards,
Rafal

Options: ReplyQuote


Subject
Views
Written By
Posted
Deadlock found when trying to get lock
5601
March 31, 2005 12:32AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.