When writing Java code relying on Spring and JPA, you may eventually come to the need of some scheduling; since Quartz is by far the reference in this field, you think you will solve all of your problems by reading the appropriate page on Spring docs. Wrong, at least if you need some Spring goodies like @Autowired and @Transactional.
I've recently come up to a very wicked problem in Syncope, and a saving blog post pointed me in the right direction: Getting your persistence access right when working with background jobs in Spring can be tricky.