That depends on what you mean by ahead of time. On the call to
EntityManager.persist() the sequence value will be assigned to the ID of
the persisted object. This is before any changes are flushed to the
Thanks, nothing specific.
I'm assuming that persist() does a lot of pre-commit activities such as
registered object comparison to find out what fields needs to be updated
etc. From what I senses that is not the case?