在一次生产上线时,程序出现了大量的DeadlockLoserDataAccessException
看mysql死锁日志
LATEST DETECTED DEADLOCK
------------------------
2017-02-09 22:34:00 7f3d560f8700
*** (1) TRANSACTION:
TRANSACTION 978548494, ACTIVE 0 sec fetching rows
mysql tables in use 3, locked 3
LOCK WAIT 12 lock struct(s), heap size 2936, 3 row lock(s)
MySQL thread id 23742818, OS thread handle 0x7f3d54ca8700, query id 3320349347 10.0.12.151 fin_titan_dal Searching rows for update
/* E:rid=********************^^-6771925919016422700|1486650840013&rpcid=1.1&appid=********************:E */ update tbl_sync_eos_order
SET
status = '2',
retry_count = 0
where partner_id = 501001
and busi_order_no = '1201482707713012965'
and status = '1'
and trans_type = 20
*** (1) WAITING FOR THIS LOCK TO BE GRANTED:
RECORD LOCKS space id 460504 page no 923 n bits 1064 index `ix_status` of table `titan_home`.`tbl_sync_eos_order` trx id 978548494 lock_mode X locks rec but not gap waiting
Record lock, heap no 553 PHYSICAL RECORD: n_fields 2; compact format; info bits 0
0: len 1; hex 31; asc 1;;
1: len 8; hex 80000000033fbdac; asc ? ;;
*** (2) TRANSACTION:
TRANSACTION 978548493, ACTIVE 0 sec fetching rows, thread declared inside InnoDB 5000
my