Remove unnecessary ids from Java entities.