Methods which use the derive query functionality now can be annotated with `@Lock` to used a given `LockMode`. Right now there are two different modes `PESSIMISTIC_READ` and `PESSIMISTIC_WRITE`. Based on the dialect the right select is generated. For example for H2 `Select ... FOR UPDATE`. Closes spring-projects/spring-data-jdbc#1041 See #643, Original pull request spring-projects/spring-data-jdbc/pull/1158