Try context.clear()
EntityManager.clear: clear the persistence context, as a result of which all managed objects will be disconnected. Changes made to objects that have not been flushed to the database will not be saved.
Session.clear: Completely clear the session.
, , / , , , . SQL script . PersistenceHelper .