Commit Graph

11458 Commits

Author SHA1 Message Date
Gavin King 3b9014cdbf HHH-17755 add test for issue 2024-02-20 16:56:28 +01:00
Gavin King e51d03c0ba HHH-17755 fix inferral of @IdClass column mapping from @MapsId 2024-02-20 16:56:28 +01:00
Gavin King 22b1d606c5 fix spelling of method name 2024-02-20 16:56:28 +01:00
Gavin King d1db92c220 very minor code changes to ForeignGenerator 2024-02-20 16:56:28 +01:00
Gavin King 78cd0175cc HHH-17755 make @MapsId work correctly with @IdClass
the @Id property was not getting populated
2024-02-20 16:56:28 +01:00
Marco Belladelli d29cb697f9
HHH-17730 Account for immutable embedded ids during merge 2024-02-20 14:11:25 +01:00
Marco Belladelli 76027709b1
HHH-17730 Add test for issue 2024-02-20 14:11:25 +01:00
Ken Schosinsky fff89542a6 HHH-17742 Fix race condition in ConcreteSqmSelectQueryPlan 2024-02-19 14:16:59 +01:00
Ken Schosinsky 9fc1ba259f HHH-17742 Test for race condition in ConcreteSqmSelectQueryPlan
Race condition occurs when two or more concurrent reach the synchronized
block in ConcreteSqmSelectQueryPlan#withCacheableSqmInterpretation. The
latter ones will see the cacheableSqmInterpretation by the first one,
but don't check whether it is compatible
(jdbcSelect.dependsOnParameterBindings(), jdbcSelect.isCompatibleWith).

On MySQL this can cause "limit null,1" to be rendered if the first query
has both offset and limit, the latter ones only a limit.
2024-02-19 14:16:59 +01:00
Marco Belladelli a4cbe2f95a
HHH-17096 Always initialize table group for subtype treated joins 2024-02-16 16:30:21 +01:00
Marco Belladelli c6c9671385
HHH-17096 Add test for issue 2024-02-16 16:30:17 +01:00
Marco Belladelli 2e9e472bd7
HHH-17508 Fix using union queries as CTE in criteria 2024-02-16 11:58:14 +01:00
Marco Belladelli 584518d609
HHH-17508 Add test for issue 2024-02-16 11:58:14 +01:00
Marco Belladelli 08db8487b0
HHH-17701 Use relational java type when resolving mapping expressibles 2024-02-16 11:55:21 +01:00
Marco Belladelli 6b56b7e737
HHH-17701 Add test for issue 2024-02-16 11:55:21 +01:00
Marco Belladelli 46dffe3336
HHH-17695 Skip rendering null nested JSON aggregate embeddables 2024-02-16 10:47:01 +01:00
Marco Belladelli d865ec9e36
HHH-17695 Add test for issue 2024-02-16 10:47:00 +01:00
Gavin King d234b4eea9 HHH-14821 consistent use of exception types
(and exception message formats)
2024-02-09 13:56:19 +01:00
Yanming Zhou d6390ce79f HHH-17719 Supports boolean as return type of mutation query method 2024-02-09 13:56:19 +01:00
Gavin King 8346b7132d more blurb about finder/query methods 2024-02-09 13:56:19 +01:00
Gavin King 594fd2f4aa add missing package-info 2024-02-09 13:56:19 +01:00
Gavin King ee33347786 HHH-17716 implement JtaTransactionAdapterTransactionManagerImpl.setTimeOut() 2024-02-09 13:56:19 +01:00
Gavin King d36131eff5 big code example in package doc for org.hibernate.annotations.processing 2024-02-09 13:56:19 +01:00
Gavin King da04eb7736 improve format of error messages relating to getters/setters 2024-02-09 13:56:19 +01:00
Gavin King dfdf49dfa6 further improvements to jdoc of @Find and @HQL 2024-02-09 13:56:19 +01:00
Gavin King 5c0486f840 clarify use of Order and Page with @Find
[It's allowed!]
2024-02-09 13:56:19 +01:00
Gavin King 9a8f02bd21 add some missing info to javadoc for @Find, @HQL, @SQL 2024-02-09 13:56:19 +01:00
Gavin King 2edd192b8d improve reporting of connection errors 2024-02-09 13:56:19 +01:00
Gavin King 7463ce89e3 HHH-17637 improve an error message 2024-02-09 13:56:19 +01:00
Andrea Boriero e98503a807
HHH-17704 Query using detached Proxy as parameter fails with LazyInitializationException 2024-02-08 12:06:51 +01:00
Andrea Boriero d35cd46995
HHH-17704 Add test for issue 2024-02-08 12:06:47 +01:00
Andrea Boriero 6057d99b79
HHH-16454 PostgreSQL ILIKE Keyword is considered a column name when deducing alias injection points 2024-02-08 12:05:42 +01:00
Andrea Boriero a2d3315067
HHH-16454 Add test for issue 2024-02-08 12:03:02 +01:00
Marco Belladelli 6138c76c72
HHH-17693 Fix typecheck assertions for converted properties
Also introduce a custom `DurationJdbcType`, mainly for validation purposes.
2024-02-08 09:40:47 +01:00
Marco Belladelli 658e9bc215
HHH-17693 Add test for issue 2024-02-08 09:39:08 +01:00
Andrea Boriero e9946dbb1c HHH-16974 IllegalStateException Unsupported tuple comparison combination 2024-02-07 11:18:14 +01:00
Andrea Boriero e7f9875dbe HHH-16974 Add test for issue 2024-02-07 11:18:14 +01:00
Yoann Rodière 0403d12ea9 Move setting of net.bytebuddy.experimental to the Jenkinsfile
The hope is that whenever we add a new JDK version to test,
we'll notice this setting, will try to remove it and upgrade bytebuddy
if necessary. This would avoid mess-ups like the one that caused
https://github.com/hibernate/hibernate-orm/pull/7790
2024-02-07 11:12:11 +01:00
Marco Belladelli 9f3676d690 HHH-17688 Make statement release more consistent in mutation delegates 2024-02-07 10:16:02 +01:00
Marco Belladelli 02fa42d90c HHH-17688 Add test for issue 2024-02-07 10:16:02 +01:00
Marco Belladelli 0a41fa41f5
HHH-17705 Load default bytecode provider using the correct ClassLoader 2024-02-05 17:18:04 +01:00
Christian Beikov 2661e5cd18 HHH-17662 Replace JdbcTypeConstructor uses for arrays with uniform resolve method 2024-02-05 14:34:02 +01:00
Stephanie Miller 5d348fc723 HHH-17662 Equals for ArrayJdbcType
JdbcTypes are put into a map and deduplicated there. Without an equals the ArrayJdbcType leaks because each resolution is created new.
2024-02-05 14:34:02 +01:00
Marco Belladelli 439fac712b Fix ORA-21700 in SetAsBasicTest 2024-02-02 12:19:42 +01:00
Andrea Boriero 5ae21a10de HHH-17320 A basic attribute of type TreeMap causes a JdbcTypeRecommendationException 2024-02-01 17:56:34 +01:00
Andrea Boriero 7be2362f29 HHH-17320 Add test for issue 2024-02-01 17:56:34 +01:00
Andrea Boriero b78159499e HHH-17687 AttributeConverter, query does not use converter to convert 'null' fields 2024-02-01 17:54:18 +01:00
Andrea Boriero e4f5926bce HHH-17687 Add test for issue 2024-02-01 17:54:18 +01:00
Marco Belladelli 24d25cedf8 HHH-17686 Avoid internal use of pruned expression for named references 2024-01-31 19:26:17 +01:00
Marco Belladelli 702caf471c HHH-17686 Add test for issue 2024-01-31 19:26:17 +01:00
Christian Beikov da21ca2e80 HHH-17689 Cache SQL statement for unique key lookup 2024-01-31 16:27:19 +01:00
Marco Belladelli ff0b535435 HHH-17594 HHH-17665 Fix proxy narrowing for delayed subtype entities 2024-01-30 19:02:05 +01:00
Marco Belladelli 652da4205f HHH-17594 HHH-17665 Add test for issue 2024-01-30 19:02:05 +01:00
Andrea Boriero 3844a34760 HHH-17587 Setting to null a property from a @SecondaryTable and @DynamicUpdate deletes the whole entry from database 2024-01-30 19:01:25 +01:00
Andrea Boriero 74f018182e HHH-17587 Add test for issue 2024-01-30 19:01:25 +01:00
Marco Belladelli 18b1cea796 HHH-17666 Fix trunc function argument type resolver 2024-01-30 10:38:12 +01:00
Marco Belladelli 7a227d702d HHH-17679 Fix unnecessary table reference resolution for treat 2024-01-26 17:24:34 +01:00
Marco Belladelli 28d8ec578f HHH-17679 Add test for issue 2024-01-26 17:24:34 +01:00
Christian Beikov 122598dcc2 HHH-17681 Restore AbstractSqmSelfRenderingFunctionDescriptor backwards compatibility 2024-01-26 17:09:52 +01:00
Gavin King 8a39ea95c1 HHH-17677 handle literal null arguments more elegantly in StandardFunctionReturnTypeResolvers
resolves a very confusing error message
2024-01-25 18:29:42 +01:00
Andrea Boriero 56deb7d89c HHH-17668 NullPointerException when refreshing bytecode-enhanced entity from second-level cache 2024-01-25 18:24:27 +01:00
Andrea Boriero 653110939e HHH-17668 Add test for issue 2024-01-25 18:24:27 +01:00
Marco Belladelli bfa1a86fea HHH-17113 Fix joined inheritance and force discriminator pruning 2024-01-25 18:23:24 +01:00
Marco Belladelli b97cb3719d HHH-17113 Add test for issue 2024-01-25 18:23:24 +01:00
Marco Belladelli e8b5a23dd2 HHH-17629 Reuse compatible joins for entity graphs and fetch profiles 2024-01-24 18:33:14 +01:00
Marco Belladelli 3b0ec32162 HHH-17629 Add test for issue 2024-01-24 18:33:14 +01:00
Andrea Boriero f2a699bafa HHH-17674 NullPointerException thrown when loading entity previously evicted and proxied 2024-01-24 18:30:15 +01:00
Andrea Boriero e0ea066d3f HHH-17674 Add test for issue 2024-01-24 18:30:15 +01:00
Andrea Boriero 6c690f561c HHH-16960 OneToOne lazy loading fails when fetch graph is involved 2024-01-24 11:05:00 +01:00
Andrea Boriero a73bc08c78 HHH-16960 Add test for issue 2024-01-24 11:05:00 +01:00
Christian Beikov f79673d274 HHH-17670 Test and fix for NPE in FromClause#findTableGroup 2024-01-24 11:05:00 +01:00
Marco Belladelli 236e3e2228 HHH-17667 Fix pruning of root table with discriminator predicate 2024-01-23 17:49:45 +01:00
Marco Belladelli ce0217df46 HHH-17667 Add test for issue 2024-01-23 17:49:45 +01:00
Andrea Boriero 316c7af186 HHH-17420 JoinColumn throws an AnnotationException 2024-01-23 15:30:24 +01:00
Andrea Boriero aef88b134d HHH-17420 Add test for issue 2024-01-23 15:30:24 +01:00
Andrea Boriero 9201ee7109 HHH-17644 Mapping of generic types in single table inheritance depends on lexicographical order of parent and child classnames 2024-01-23 15:29:41 +01:00
Andrea Boriero f33afc66bf HHH-17644 Add test for issue 2024-01-23 15:29:41 +01:00
Marco Belladelli bdb2906a94 HHH-17550 Respect default no-constraint setting 2024-01-22 18:38:48 +01:00
Marco Belladelli 641afbcf84 HHH-17550 Add test for issue 2024-01-22 18:38:48 +01:00
Marco Belladelli a060a3b9c0 HHH-17598 Allow array typed queries without result wrapping 2024-01-22 18:33:57 +01:00
Andrea Boriero 529d4915ba HHH-17634 Merging a new entity having a @GeneratedValue id should not set the generated id of the original entity 2024-01-22 18:28:39 +01:00
Andrea Boriero db47b51a30 HHH-17634 Add test for issue 2024-01-22 18:28:39 +01:00
Marco Belladelli ba5101d40b HHH-17526 Throw correct exception when reading list results 2024-01-22 15:27:53 +01:00
Marco Belladelli bb047c4fad HHH-17526 Add test for issue 2024-01-22 15:27:53 +01:00
Marco Belladelli d25b5532a9 HHH-17605 Fix native query selecting multiple of the same entity result 2024-01-22 15:27:53 +01:00
Marco Belladelli 70c8ea03bb HHH-17461 Include soft-delete column in duplication check 2024-01-22 15:27:53 +01:00
Andrea Boriero 673f03304f HHH-17653 - Error in generating schema when @Generator annotation is applied to a non id embeddable property 2024-01-22 13:03:25 +01:00
Andrea Boriero 4ba772b72d HHH-17653 Add test for issue 2024-01-22 13:03:25 +01:00
Marco Belladelli 240514986d
HHH-17643 Remove unused internal BytecodeProviderInitiator method 2024-01-22 08:51:05 +01:00
Marco Belladelli 8062350cc0
HHH-17643 Load `BytecodeProvider` as a java service
Also allow `SerializableProxy` deserialization even when no session factory is available.
2024-01-22 08:51:01 +01:00
Jan Schatteman 29346e6f19 HHH-17635 - Add test for issue
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2024-01-18 10:41:41 +01:00
Jan Schatteman d6f09d6e9d HHH-17635 - register custom user types when contributed through a service provider
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2024-01-18 10:41:41 +01:00
marko-bekhta 733b555e86 HHH-17619 Add the multitenancy filter in a stateless session 2024-01-15 12:30:30 +01:00
Marco Belladelli f5800a0388 HHH-17435 Small fixes to trim() function 2024-01-15 12:02:54 +01:00
Christian Beikov 8250f13d77 HHH-17639 Make recursive CTE cycle detection emulation independent of collation 2024-01-15 06:38:38 +01:00
Andrea Boriero 899bf7b4fb HHH-17632 AssertionError when updating entity with lazy loading property and bytecode enhancement 2024-01-12 17:01:56 +01:00
Andrea Boriero 8f3cc245ce HHH-17632 Add test for issue 2024-01-12 17:01:56 +01:00
Marco Belladelli b8d9552803 HHH-17492 Allow parameter inferred mapping for same java types 2024-01-12 17:01:12 +01:00
Marco Belladelli dc2c2823ed HHH-17492 Add test for issue 2024-01-12 17:01:12 +01:00
Marco Belladelli 8daa7ced49 HHH-17435 Allow input param as trim character and fix single quote 2024-01-12 12:53:20 +01:00
Marco Belladelli bc1210e641 HHH-17435 Add test for issue 2024-01-12 12:53:19 +01:00
Marco Belladelli c7658e1cab HHH-17615 Small fix to entity joins with soft-delete and inheritance 2024-01-11 19:35:12 +01:00
Marco Belladelli b99b6e4146 HHH-17615 Fix pruning of soft delete table for joined inheritance 2024-01-11 19:35:12 +01:00
Christian Beikov 6827581a38 HHH-17106 Fix ClassCastException when using length 1 named enum mapping 2024-01-10 12:47:23 +01:00
Andrea Boriero 19081ba565 HHH-17621 UnsupportedOperationException when merging an entity with a @Any mapping 2024-01-10 12:16:55 +01:00
Andrea Boriero 2ec2cf2343 HHH-17621 Add test for issue 2024-01-10 12:16:55 +01:00
Jan Schatteman 872d9ef1f7 HHH-17616 - More work related to moving resources
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2024-01-10 12:13:06 +01:00
Andrea Boriero 2555a05cb6 HHH-1645 HHH-17395 Refresh with LockMode on an unitialized proxy does not work 2024-01-09 12:13:57 +01:00
Andrea Boriero 49190fda66 HHH-1645 enabled test for issue 2024-01-09 12:13:57 +01:00
Daniel Mensinger e32d11ef6b HHH-17395 test case 2024-01-09 12:13:57 +01:00
Andrea Boriero 24b516253a HHH-17307 Hibernate 6 ListResultsConsumer.Results#addUnique really slow for ElementCollections 2024-01-08 18:52:29 +01:00
Christian Beikov 6e79643a55 HHH-17623 Test and fix use of association in @OrderBy 2024-01-08 18:52:29 +01:00
Marco Belladelli 5a27b2a4da HHH-17483 Fix applyDiscriminator treat for nested inheritance subtypes
Also small fix to joined-inheritance pruning.
2024-01-08 16:12:34 +01:00
Marco Belladelli 98ba4fca29 HHH-17483 Add test for issue 2024-01-08 16:12:34 +01:00
Jan Schatteman c9f79733bc HHH-17616 - Move resources that were still in src/java to src/resources (hibernate-core)
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2024-01-08 10:05:35 +01:00
Marco Belladelli 8e5f847201 HHH-17490 Fix not in and empty list parameter predicate 2024-01-05 18:46:24 +01:00
Marco Belladelli cfe41ed8bb HHH-17606 Fix nested generic join path resolution 2024-01-04 18:21:46 +01:00
Marco Belladelli fa0f5d414b HHH-17606 Add test for issue 2024-01-04 18:21:46 +01:00
Marco Belladelli 8692e3d4bc HHH-17530 Handle nested dynamic instantiations when tracking selections 2024-01-04 18:20:09 +01:00
Marco Belladelli f0b2eb9d1c HHH-17530 Add test for issue 2024-01-04 18:20:08 +01:00
Jan Schatteman f72bea49cb HHH-14821 - Test and fix for issue
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2024-01-04 16:52:54 +01:00
Jan Schatteman 718f26022e HHH-17511 - Fix for missing condition in join with a @SoftDelete marked Entity
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2024-01-04 16:44:20 +01:00
Jan Schatteman 7955b1b52e HHH-17511 - Add test for issue
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2024-01-04 16:44:20 +01:00
H.Lo 6768e14f8c HHH-17507 HHH-17574 Fixed wrap() & unwrap() & updated unit tests 2024-01-04 16:39:58 +01:00
Jan Schatteman 2521e72d37 HHH-14358 - Added test and fix to support null binding for PostgreSQL
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2023-12-22 20:26:09 +01:00
Christian Beikov 168a5dc469 Fix test on CockroachDB by not using identity generator 2023-12-22 10:23:25 +01:00
Jan Schatteman 67f1a809b2 HHH-17578 - Fix the intermittent ClassCastException that occurs when trying to call a method on a HibernateProxy where the parameter type is defined by generics/class hierarchy.
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2023-12-20 21:31:23 +01:00
Marco Belladelli e8d436ffb2 HHH-17467 Handle proxies when checking entity type instance 2023-12-20 18:06:00 +01:00
Marco Belladelli 74066a7afe HHH-17467 Add test for issue 2023-12-20 18:06:00 +01:00
Christian Beikov ad283cdc4c HHH-17303 Fix test on PostgreSQL 2023-12-20 16:29:32 +01:00
Christian Beikov 3c3aead17b HHH-17303 Fix test on PostgreSQL 2023-12-20 14:41:51 +01:00
Christian Beikov 5f26464c3e HHH-17303 Fix test on Derby 2023-12-20 13:31:25 +01:00
HARPER Jon 090253260b HHH-17303 Improve testJoinedInheritanceNativeQuery to operate on an entity with actual inheritance 2023-12-19 20:35:34 +01:00
ankiaga c4251325ce HHH-17327 Adding support for Union All in IncrementGenerator
https://hibernate.atlassian.net/browse/HHH-17327
2023-12-19 20:30:41 +01:00
Bastien JANSEN 93468249ad HHH-16526 - Add missing first argument in toHqlString() 2023-12-19 20:28:36 +01:00
zinzoddari 10f490c44b HHH-17396 fix typos in javadoc 2023-12-19 20:27:34 +01:00
Andrea Boriero a9e9985df0 HHH-17560 ArrayIndexOutOfBoundsException in DirtyHelper.isModified() 2023-12-19 20:20:36 +01:00
Andrea Boriero 074dd60c4a HHH-17560 Add test for issue 2023-12-19 20:20:36 +01:00
cmuchinsky 04ecdc6add [HHH-17496] Use Enum#name() for DB value 2023-12-19 19:08:03 +01:00
Andrea Boriero d90d6e63f0 HHH-17463 UnsupportedOperationException when using JAKARTA_JDBC_URL 2023-12-19 17:32:24 +01:00
Andrea Boriero d5bde15aaa HHH-17463 Add test for issue 2023-12-19 17:32:24 +01:00
Marco Belladelli b9e230e456 HHH-17572 Move embedded collections selection check to query validation 2023-12-18 18:23:39 +01:00
Marco Belladelli f88ef3e7c2 HHH-17572 Add test for issue 2023-12-18 18:23:39 +01:00
Marco Belladelli b44ff032c3 HHH-17528 Throw error for embedded result with collections 2023-12-15 19:46:33 +01:00
Benjamin Hartmann a59119ee42 HHH-17528 Add test for issue 2023-12-15 19:46:33 +01:00
Marco Belladelli 081b5977af HHH-17515 Fix constructor selection for integral types 2023-12-15 19:33:56 +01:00
Marco Belladelli b8255af29b HHH-17515 Add test for issue 2023-12-15 19:33:56 +01:00
Marco Belladelli 0970550c63 HHH-17566 Fix named native query registration with entity result type 2023-12-15 19:29:03 +01:00
Yoann Rodière 772af0de24 HHH-17566 Test addNamedQuery for native queries targeting entities 2023-12-15 19:29:03 +01:00
Yanming Zhou 53a29554c0 HHH-17570 Fix wrong name when checking Oracle autonomous JSON database
According to https://docs.oracle.com/en/database/oracle/oracle-database/23/sqlrf/SYS_CONTEXT.html#GUID-B9934A5D-D97B-4E51-B01B-80C76A5BD086

>> Returns DWCS on autonomous database management systems (ADW), OLTP on autonomous transaction processing systems (ATP), and JDCS on autonomous JSON database systems.
2023-12-15 14:14:54 +01:00