Correct Use of flush() in JPA