Is it possible to get a DB deadlock exception with Spring + JPA Repositories + H2/PostgreSQL?
I've found several examples of how to simulate a deadlock with raw SQL (one, two, three, four), but my goal is to do the same in a more high-level environment.
I did some experiments with concurerent threads, CrudRepository.save(entity), and Thread.sleep() but to no avail (I guess it's not possible). What else can I try?