I am getting MySQL lock wait timeout on the insert which very unusual. Usually, we are supposed to get this issue during an update.
Insert statement that we are using very simple one INSERT INTO Document ('title', 'page_number') VALUES('some name here','12');
We are not locking any table during this period,
- what is the possible cause for this behavior?
- How to debug this condition to figure out what is holding the lock?
We are using AWS Mysql aurora. Please let us know if we need any other information
Update
I tried to get the table lock details by using SHOW INNODB STATUS
but it did not help me much since this issue occurs only on production randomly and we are not able to reproduce it.