Deadlock when creating job instances
问题 I have multiple threads that start jobs using a synchronous job launcher. I get the following exception when job instances are created concurrently: Exception in thread "pool-1-thread-1" org.springframework.dao.DataAccessResourceFailureException: Could not obtain last_insert_id(); nested exception is com.mysql.jdbc.exceptions.jdbc4.MySQLTransactionRollbackException: Deadlock found when trying to get lock; try restarting transaction at org.springframework.jdbc.support.incrementer