Code refactoring for the JPA-store.