[hibernate-issues] [Hibernate-JIRA] Created: (HHH-6615) int type in Revision number

Adriano Saturno Muniz (JIRA) noreply at atlassian.com
Mon Aug 29 11:44:02 EDT 2011


int type in Revision number
---------------------------

                 Key: HHH-6615
                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-6615
             Project: Hibernate Core
          Issue Type: Bug
          Components: envers
    Affects Versions: 3.6.6
         Environment: Hibernata 3.6.6, Oracle
            Reporter: Adriano Saturno Muniz


At class DefaultRevisionEntity we have:
 
    @RevisionNumber
    private int id;
 
I made a test setting the HIBERNATE_SEQUENCE to 2,147,483,647. After that, I made an audited update.
 
The REV column of REVINFO table become negative (int type overflow)

The revision number should be long, at least.
 
No warnings / exceptions at all could be dangerous. In a overflow all the audit will stop working (envers based the version recoverry in an always increasing REV value, right?). In a very worst scenario, after a long time loosing audit, a primary key violation will happen.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list