Never Use "eclipselink.allow-zero-id" - It is Deprecated and has Side Effects
(Doc ID 2034917.1)
Last updated on AUGUST 16, 2016
Applies to:Oracle TopLink - Version 188.8.131.52 and later
Information in this document applies to any platform.
Raise awareness that "eclipselink.allow-zero-id" must never be used.
The "eclipselink.allow-zero-id" is known to cause side effects with the primary key generation on other applications.
It has been seen that this can end up in getting
java.sql.SQLIntegrityConstraintViolationException: ORA-00001: unique constraint violated
errors when trying to INSERT a new JPA object in the database table, because the primary key generation has been skipped due to the global effect or having "eclipselink.allow-zero-id" set in a different application and thus accepting Java's default 0 as a valid primary key, which the application normally would not want. (Such problems are very hard to spot.)
To view full details, sign in with your My Oracle Support account.
Don't have a My Oracle Support account? Click to get started!
In this Document