I'm trying to delete an entity but the delete query is not generated and there's no error shown in the console :
@Override
@Transactional
public void removeClassObject(MyClassObject classObject) {
MyClassObject ip = entityManager.find(MyClassObject.class, classObject.getId());
entityManager.remove(ip);
}
Take notice : @Transactional is from springFramework package
EDIT :
All my configuration are ok, because I already have the merge and persist functions doing there job without any problem it's just the remove method which doesn't generate any sql query and does not remove the given entity.
EDIT 2 :
This is how I obtain my entityManager :
@PersistenceContext(type = PersistenceContextType.TRANSACTION)
protected EntityManager entityManager;