LPS-41415 Force flush

Operations are not necessarily sent immediately to the database, but cached into the hibernate session. That's why we need to force the flush of the session in order to avoid reorganizations and prevent duplications in the database.