// The JPA spec doesn't actually say what to do with a newly persistent object
// We simply flush it (which goes against "unflushed changes made to the entity will not be synced")
// but then what are we supposed to do with a newly persistent ? does it make it into the DB after?
om.flushInternal(true);
}
om.detachObject(entity, new DetachState(om.getApiAdapter()));
}
catch (NucleusException ne)
{
throwException(NucleusJPAHelper.getJPAExceptionForNucleusException(ne));
}