[hibernate/hibernate-orm] c9caf2: HHH-15770 javadoc and cleanup for @OnDelete, OnDel...
by Gavin King
Branch: refs/heads/main
Home: https://github.com/hibernate/hibernate-orm
Commit: c9caf292e693478f40d34e8c05eafacdadf9466f
https://github.com/hibernate/hibernate-orm/commit/c9caf292e693478f40d34e8...
Author: Gavin <gavin(a)hibernate.org>
Date: 2022-11-27 (Sun, 27 Nov 2022)
Changed paths:
M documentation/src/test/java/org/hibernate/userguide/pc/CascadeOnDeleteTest.java
M hibernate-core/src/main/java/org/hibernate/annotations/ColumnDefault.java
M hibernate-core/src/main/java/org/hibernate/annotations/OnDelete.java
M hibernate-core/src/main/java/org/hibernate/annotations/OnDeleteAction.java
M hibernate-core/src/main/java/org/hibernate/mapping/ManyToOne.java
Log Message:
-----------
HHH-15770 javadoc and cleanup for @OnDelete, OnDeleteAction
Commit: 76f92bd901e1c8846854821aa2ed3b5083a70503
https://github.com/hibernate/hibernate-orm/commit/76f92bd901e1c8846854821...
Author: Gavin <gavin(a)hibernate.org>
Date: 2022-11-27 (Sun, 27 Nov 2022)
Changed paths:
M hibernate-core/src/main/java/org/hibernate/annotations/OnDeleteAction.java
M hibernate-core/src/main/java/org/hibernate/cfg/AnnotationBinder.java
M hibernate-core/src/main/java/org/hibernate/cfg/BinderHelper.java
M hibernate-core/src/main/java/org/hibernate/cfg/OneToOneSecondPass.java
M hibernate-core/src/main/java/org/hibernate/cfg/ToOneBinder.java
M hibernate-core/src/main/java/org/hibernate/cfg/annotations/CollectionBinder.java
M hibernate-core/src/main/java/org/hibernate/cfg/annotations/EntityBinder.java
M hibernate-core/src/main/java/org/hibernate/dialect/Dialect.java
M hibernate-core/src/main/java/org/hibernate/event/internal/DefaultDeleteEventListener.java
M hibernate-core/src/main/java/org/hibernate/mapping/ForeignKey.java
M hibernate-core/src/main/java/org/hibernate/mapping/ManyToOne.java
M hibernate-core/src/main/java/org/hibernate/mapping/SimpleValue.java
M hibernate-core/src/main/java/org/hibernate/tool/schema/internal/StandardForeignKeyExporter.java
Log Message:
-----------
HHH-15770 add in all the commonly-supported OnDeleteActions
Commit: 759b68b0229a31dfb8b1ea2f45cbdb77dab6239f
https://github.com/hibernate/hibernate-orm/commit/759b68b0229a31dfb8b1ea2...
Author: Gavin <gavin(a)hibernate.org>
Date: 2022-11-27 (Sun, 27 Nov 2022)
Changed paths:
M hibernate-core/src/main/java/org/hibernate/cfg/AnnotatedColumn.java
M hibernate-core/src/main/java/org/hibernate/cfg/AnnotatedJoinColumn.java
M hibernate-core/src/main/java/org/hibernate/cfg/AnnotatedJoinColumns.java
M hibernate-core/src/main/java/org/hibernate/cfg/ColumnsBuilder.java
M hibernate-core/src/main/java/org/hibernate/cfg/ToOneFkSecondPass.java
M hibernate-core/src/main/java/org/hibernate/cfg/annotations/CollectionBinder.java
A hibernate-core/src/test/java/org/hibernate/orm/test/ondelete/toone/ToOneOnDeleteSetNullTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/ondelete/toone/ToOneOnDeleteTest.java
Log Message:
-----------
HHH-15770 let you use @ColumnDefault on associations
this is very useful in combination with @OnDelete(action=SET_NULL)
Commit: f2c81b0eaf3a39e74c527c20c77704beadb1d26d
https://github.com/hibernate/hibernate-orm/commit/f2c81b0eaf3a39e74c527c2...
Author: Gavin <gavin(a)hibernate.org>
Date: 2022-11-27 (Sun, 27 Nov 2022)
Changed paths:
M hibernate-core/src/main/java/org/hibernate/cfg/AnnotatedJoinColumn.java
M hibernate-core/src/main/java/org/hibernate/cfg/AnnotatedJoinColumns.java
M hibernate-core/src/main/java/org/hibernate/cfg/annotations/EntityBinder.java
Log Message:
-----------
rename some methods to reduce confusion
Compare: https://github.com/hibernate/hibernate-orm/compare/12aa8bd431b4...f2c81b0...
2 years, 1 month
[hibernate/hibernate-orm] 12aa8b: add some comments for the next poor soul who wrest...
by Gavin King
Branch: refs/heads/main
Home: https://github.com/hibernate/hibernate-orm
Commit: 12aa8bd431b4c94e96b8ce133257ad8dca6dcbee
https://github.com/hibernate/hibernate-orm/commit/12aa8bd431b4c94e96b8ce1...
Author: Gavin <gavin(a)hibernate.org>
Date: 2022-11-27 (Sun, 27 Nov 2022)
Changed paths:
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/DB2LegacyDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/DB2iLegacyDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/DB2zLegacyDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/SQLServerLegacyDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/unique/AlterTableUniqueDelegate.java
M hibernate-core/src/main/java/org/hibernate/dialect/unique/AlterTableUniqueIndexDelegate.java
M hibernate-core/src/main/java/org/hibernate/dialect/unique/CreateTableUniqueDelegate.java
M hibernate-core/src/main/java/org/hibernate/dialect/unique/SkipNullableUniqueDelegate.java
M hibernate-core/src/main/java/org/hibernate/dialect/unique/UniqueDelegate.java
Log Message:
-----------
add some comments for the next poor soul who wrestles with unique constraints
2 years, 1 month
[hibernate/hibernate-orm] 0253e1: HHH-15767 put unique constraints where they belong...
by Gavin King
Branch: refs/heads/main
Home: https://github.com/hibernate/hibernate-orm
Commit: 0253e1fe7a7cc4eb64fcc48f07630dee8d4fc20a
https://github.com/hibernate/hibernate-orm/commit/0253e1fe7a7cc4eb64fcc48...
Author: Gavin <gavin(a)hibernate.org>
Date: 2022-11-27 (Sun, 27 Nov 2022)
Changed paths:
M hibernate-core/src/main/java/org/hibernate/cfg/OneToOneSecondPass.java
M hibernate-core/src/main/java/org/hibernate/cfg/ToOneBinder.java
M hibernate-core/src/test/java/org/hibernate/orm/test/embeddable/MappedByEmbeddableTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/inheritance/discriminator/SingleTableInheritancePersistTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/inheritance/discriminator/TablePerClassInheritancePersistTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/inheritance/discriminator/TablePerClassInheritanceTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/insertordering/InsertOrderingSelfReferenceSingleTableInheritance.java
M hibernate-core/src/test/java/org/hibernate/orm/test/mapping/onetoone/primarykey/NullablePrimaryKeyTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/ondelete/toone/ToOneOnDeleteTest.java
M hibernate-envers/src/test/java/org/hibernate/envers/test/integration/query/InheritanceAssociationToOneInnerJoinTest.java
M hibernate-envers/src/test/java/org/hibernate/orm/test/envers/integration/onetoone/bidirectional/BiRefIngEntity.java
M hibernate-envers/src/test/java/org/hibernate/orm/test/envers/integration/onetoone/unidirectional/UniRefIngEntity.java
Log Message:
-----------
HHH-15767 put unique constraints where they belong on optional @OneToOne associations
this was a bug that allowed people to use @OneToOne as a regular @ManyToOne
and ... people did ... as evidenced by all these bogus tests I just fixed
this is in principle a breaking change because it breaks code that was broken
Commit: 5172d8798faff97c6f536f06dda89bdc3de33e56
https://github.com/hibernate/hibernate-orm/commit/5172d8798faff97c6f536f0...
Author: Gavin <gavin(a)hibernate.org>
Date: 2022-11-27 (Sun, 27 Nov 2022)
Changed paths:
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/DB2LegacyDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/DB2iLegacyDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/DB2zLegacyDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/SQLServerLegacyDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/SybaseLegacyDialect.java
M hibernate-core/src/main/java/org/hibernate/boot/internal/InFlightMetadataCollectorImpl.java
M hibernate-core/src/main/java/org/hibernate/cfg/IndexOrUniqueKeySecondPass.java
M hibernate-core/src/main/java/org/hibernate/dialect/AbstractTransactSQLDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/DB2Dialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/DB2iDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/DB2zDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/Dialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/SQLServerDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/SybaseDialect.java
A hibernate-core/src/main/java/org/hibernate/dialect/unique/AlterTableUniqueIndexDelegate.java
M hibernate-core/src/main/java/org/hibernate/dialect/unique/CreateTableUniqueDelegate.java
R hibernate-core/src/main/java/org/hibernate/dialect/unique/DB2UniqueDelegate.java
A hibernate-core/src/main/java/org/hibernate/dialect/unique/SkipNullableUniqueDelegate.java
M hibernate-core/src/main/java/org/hibernate/engine/jdbc/internal/DDLFormatterImpl.java
M hibernate-core/src/main/java/org/hibernate/mapping/Index.java
M hibernate-core/src/main/java/org/hibernate/mapping/Table.java
M hibernate-core/src/main/java/org/hibernate/mapping/UniqueKey.java
M hibernate-core/src/test/java/org/hibernate/orm/test/annotations/uniqueconstraint/UniqueConstraintTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/annotations/uniqueconstraint/UniqueConstraintThrowsConstraintViolationExceptionTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/jpa/mapping/UnidirectionalOneToManyUniqueConstraintOrderColumnTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/mapping/onetoone/primarykey/NullablePrimaryKeyTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/schemaupdate/inheritance/tableperclass/Element.java
M hibernate-core/src/test/java/org/hibernate/orm/test/schemaupdate/inheritance/tableperclass/SchemaCreationTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/schemaupdate/uniqueconstraint/UniqueConstraintDropTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/schemaupdate/uniqueconstraint/UniqueConstraintGenerationTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/tm/JtaBeforeCompletionFailureTest.java
Log Message:
-----------
HHH-15762 work around weird semantics of null in unique index on DB2/T-SQL
Compare: https://github.com/hibernate/hibernate-orm/compare/82e42ef94629...5172d87...
2 years, 1 month
[hibernate/hibernate-orm] 3ba90c: HHH-15762 nicer DDL for unique constraints
by Gavin King
Branch: refs/heads/main
Home: https://github.com/hibernate/hibernate-orm
Commit: 3ba90c004cd00fc584e7b6a6bb554783ddddc761
https://github.com/hibernate/hibernate-orm/commit/3ba90c004cd00fc584e7b6a...
Author: Gavin <gavin(a)hibernate.org>
Date: 2022-11-26 (Sat, 26 Nov 2022)
Changed paths:
M documentation/src/test/java/org/hibernate/userguide/schema/UniqueConstraintTest.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/CUBRIDDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/DB2iLegacyDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/MySQLLegacyDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/SQLiteDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/TeradataDialect.java
M hibernate-community-dialects/src/main/java/org/hibernate/community/dialect/unique/InformixUniqueDelegate.java
M hibernate-core/src/main/java/org/hibernate/boot/internal/InFlightMetadataCollectorImpl.java
M hibernate-core/src/main/java/org/hibernate/boot/model/relational/SqlStringGenerationContext.java
M hibernate-core/src/main/java/org/hibernate/boot/model/relational/internal/SqlStringGenerationContextImpl.java
M hibernate-core/src/main/java/org/hibernate/cfg/UniqueConstraintHolder.java
M hibernate-core/src/main/java/org/hibernate/cfg/annotations/TableBinder.java
M hibernate-core/src/main/java/org/hibernate/dialect/AbstractTransactSQLDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/DB2400V7R3Dialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/DB2iDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/DerbyDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/Dialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/H2Dialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/HSQLDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/MySQLDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/OracleDialect.java
M hibernate-core/src/main/java/org/hibernate/dialect/PostgreSQLDialect.java
A hibernate-core/src/main/java/org/hibernate/dialect/unique/AlterTableUniqueDelegate.java
A hibernate-core/src/main/java/org/hibernate/dialect/unique/CreateTableUniqueDelegate.java
M hibernate-core/src/main/java/org/hibernate/dialect/unique/DB2UniqueDelegate.java
M hibernate-core/src/main/java/org/hibernate/dialect/unique/DefaultUniqueDelegate.java
R hibernate-core/src/main/java/org/hibernate/dialect/unique/MySQLUniqueDelegate.java
M hibernate-core/src/main/java/org/hibernate/dialect/unique/UniqueDelegate.java
M hibernate-core/src/main/java/org/hibernate/mapping/Constraint.java
M hibernate-core/src/main/java/org/hibernate/mapping/Table.java
M hibernate-core/src/main/java/org/hibernate/mapping/UniqueKey.java
M hibernate-core/src/main/java/org/hibernate/mapping/Value.java
M hibernate-core/src/main/java/org/hibernate/tool/schema/internal/AbstractSchemaMigrator.java
M hibernate-core/src/main/java/org/hibernate/tool/schema/internal/StandardForeignKeyExporter.java
M hibernate-core/src/main/java/org/hibernate/tool/schema/internal/StandardIndexExporter.java
M hibernate-core/src/main/java/org/hibernate/tool/schema/internal/StandardSequenceExporter.java
M hibernate-core/src/main/java/org/hibernate/tool/schema/internal/StandardTableCleaner.java
M hibernate-core/src/main/java/org/hibernate/tool/schema/internal/StandardTableExporter.java
M hibernate-core/src/main/java/org/hibernate/tool/schema/internal/StandardUniqueKeyExporter.java
M hibernate-core/src/test/java/org/hibernate/orm/test/annotations/onetomany/Trainer.java
R hibernate-core/src/test/java/org/hibernate/orm/test/annotations/uniqueconstraint/MySQLDropConstraintThrowsExceptionTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/hbm/uk/UniqueDelegateTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/schemaupdate/inheritance/tableperclass/SchemaCreationTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/schemaupdate/uniqueconstraint/UniqueConstraintDropTest.java
M hibernate-core/src/test/java/org/hibernate/orm/test/schemaupdate/uniqueconstraint/UniqueConstraintGenerationTest.java
Log Message:
-----------
HHH-15762 nicer DDL for unique constraints
- prefer 'unique' in 'create table' except in migrations
- also ignore unique=true for PK column
- introduce AlterTableUniqueDelegate and CreateTableUniqueDelegate
- fix the tests / delete test that makes no sense now
- improve javadoc of UniqueDelegate
Commit: 13f4c8c2853af13c1dfb96ec157295c4f96a3d6e
https://github.com/hibernate/hibernate-orm/commit/13f4c8c2853af13c1dfb96e...
Author: Gavin <gavin(a)hibernate.org>
Date: 2022-11-26 (Sat, 26 Nov 2022)
Changed paths:
M hibernate-core/src/main/java/org/hibernate/boot/internal/InFlightMetadataCollectorImpl.java
M hibernate-core/src/main/java/org/hibernate/cfg/annotations/CollectionBinder.java
M hibernate-core/src/main/java/org/hibernate/mapping/UniqueKey.java
Log Message:
-----------
light refactoring
Commit: dd50e1e28ef9b56992b394e53eb570308d5ea06a
https://github.com/hibernate/hibernate-orm/commit/dd50e1e28ef9b56992b394e...
Author: Gavin <gavin(a)hibernate.org>
Date: 2022-11-26 (Sat, 26 Nov 2022)
Changed paths:
M hibernate-core/src/main/java/org/hibernate/annotations/ForeignKey.java
Log Message:
-----------
add message/@deprecated a member that Hibernate ignores
Compare: https://github.com/hibernate/hibernate-orm/compare/41fb50f18ec2...dd50e1e...
2 years, 1 month