I am facing PessimisticLockException while writing into MySQL. I have used @Transactional in the Java method also there is only one row of data in the table.
The method does a checks the table and performs ither validation and if valid inserts the values in the table while insertion I am facing a Lock.