Incorrect Schema update (invalidschema for sequence) when override RevisionEntity with generated id with sequence
Description
Attachments
- 28 Jul 2012, 10:53 AM
Activity
Chris Cranford August 5, 2016 at 4:55 AM
Verified this is not an issue with 5.0, 5.1, nor 5.2.
Steve Ebersole October 28, 2015 at 3:25 AM
As part of verifying that this issue affects 5.0, please just set the "Affects version". Leave the "verify-affects-5.0" label and leave the issue in "Awaiting Response" status; these are critical for us to be able to track these verifications and triage them. Thanks.
Steve Ebersole October 27, 2015 at 7:16 PM
This bug report does not indicate that the reported issue affects version 5.x. Versions prior to 5.x are no longer maintained. It would be a great help to the Hibernate team and community for someone to verify that the reported issue still affects version 5.x. If so, please add the 5.x version that you verified with to the list of affected-versions and attach the (preferably SSCCE) test case you used to do the verification to the report; from there the issues will be looked at during our triage meetings.
For details, see http://in.relation.to/2015/10/27/great-jira-cleanup-2015/
Lukasz Antoniak July 28, 2012 at 10:53 AM
Just to clarify, Hibernate does not expose — hibermate.generateDdl parameter. I assume that you mentioned the attribute of Spring's org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter
which in the end sets — hibernate.hbm2ddl.auto to — update. Which database are you using? Attached simple application works fine on Oracle and I can see REVINFO_SEQUENCE
in ENVERS_AUDIT
schema.
Cyril MOREAU July 23, 2012 at 9:10 AM
ok it's good (with hibernate.hbm2ddl.auto=create, but not with hibernate.generateDdl=true)
I have created an abstract RevisionEntity with @GeneratedValue depends on sequence
@MappedSuperclass
public class MyDefaultRevisionEntity implements Serializable {
private static final long serialVersionUID = -8404582037485802857L;
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "idgen")
@RevisionNumber
private int id;
I want created specif subclass how determinate the sequencegenerator (in specific schema)
@Entity
@RevisionEntity
@Table(name = "revinfo", schema = "revision")
@SequenceGenerator(name = "idgen", sequenceName = "revinfo_sequence", schema = "revision")
public class SampleRevisionEntity extends MyDefaultRevisionEntity {
But the hibernate schema update create the sequence into "public" schema but not into "revision" schema.