Commit Graph

11746 Commits

Author SHA1 Message Date
Andrea Boriero 83f723e8c2 HHH-17943 - Add test for issue 2024-05-22 17:54:09 +02:00
Jan Schatteman ab7f95abd7 HHH-17943 - Fix for issue
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2024-05-22 17:54:09 +02:00
Jan Schatteman a3387a2d85 HHH-17943 - Add test for issue
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2024-05-22 17:54:09 +02:00
Yanming Zhou 1433423c1b HHH-18073 `BasicCollectionJavaType::wrap` should retain order of `Set` to keep consistent with `deepCopy` 2024-05-21 18:24:46 +02:00
Marco Belladelli 19c42b3942 HHH-18026 Fix SQL Exception for dialects not supporting arbitrary keys 2024-05-20 08:46:36 +02:00
Marco Belladelli c23d75cd76 HHH-18026 Add test for issue 2024-05-20 08:46:36 +02:00
Yoann Rodière dfbb72abe6 HHH-18112 Fix and test default version handling for non-Oracle dialects 2024-05-15 11:54:35 +02:00
Yoann Rodière 32d4f1596e HHH-18080 Fix default version handling in dialects when not using JDBC metadata
* Use the minimum supported version instead of '0.0.0'
* Don't warn about version '0.0.0'
2024-05-10 10:48:40 -05:00
Yoann Rodière 73edbac469 HHH-18079 Default to minimum supported DB version in more cases
In particular when using hibernate.boot.allow_jdbc_metadata_access=false with jakarta.persistence.database-product-name
2024-05-10 10:48:40 -05:00
Sanne Grinovero b98ee83b8d HHH-18094 Bytebuddy enhancer: make better use of constants and memory 2024-05-10 10:01:12 +01:00
Marco Belladelli e7d32c0365
Fix Oracle test missing order by expression in select distinct 2024-05-07 11:11:43 +02:00
Christian Beikov 23fecb110d HHH-17421 Ensure that no follow-on locking happens on SQL Server and Sybase ASE 2024-05-07 08:17:29 +02:00
Simon StJohn-Green 604c896529 HHH-17421 Test that no follow-on locking happens on SQL Server and Sybase ASE 2024-05-07 08:17:28 +02:00
Christian Thiel 5698af3917 HHH-17305 Test and fix for keeping order of tables in polymorphic queries 2024-05-06 17:49:36 +02:00
Christian Beikov 459c6f427a HHH-17385 Missing table for superclass when joining subclass association 2024-05-06 16:23:10 +02:00
Andrea Boriero 92aef4a1ae HHH-18032 CompositeId, when the id assigned by PrePersist method an HibernateException: identifier of an instance of _ was altered is thrown 2024-05-06 14:52:04 +02:00
Andrea Boriero 098fdbd374 HHH-18032 Add test for issue 2024-05-06 14:52:04 +02:00
Marco Belladelli e8252cb4a8 HHH-17827 Fix check for Map dynamic entity classes 2024-05-06 14:29:14 +02:00
Marco Belladelli bb88d3244b HHH-17827 Add test for issue 2024-05-06 14:29:14 +02:00
Marco Belladelli 08c2a5479d HHH-17834 Force version increment for the correct inheritance table 2024-05-06 14:27:13 +02:00
Marco Belladelli d977b40598 HHH-17834 Add test for issue 2024-05-06 14:27:13 +02:00
Christian Beikov 19c2c40f82 HHH-18046 Fix Hana issue with binary arithmetic parameter operand and skip test for cockroach 2024-05-06 12:15:00 +02:00
Marco Belladelli 9ba0dd7af0 HHH-17837 Render target-side key for explicit plural joins when needed
Also, change how we determine whether we need to use the target-side to only the strictly needed cases (non-optimizable joins, `group by` or `order by` clauses)
2024-05-03 08:48:24 +02:00
Marco Belladelli b2f1725520 HHH-17837 Add test for issue 2024-05-03 08:48:24 +02:00
Christian Beikov 0b1ad4e410 HHH-18046 Cast parameters used as arithmetic operands on DB2 2024-05-02 18:19:16 +02:00
Christian Beikov d5da60da1c HHH-18018 Use NO_PLAIN_PARAMETER for Derby functions that use the length function 2024-05-02 10:28:13 +02:00
Sanne Grinovero f379ae0652 HHH-18011 Extract reusable constants from EnhancerImpl 2024-05-01 12:00:04 +01:00
Sanne Grinovero aff789cd90 HHH-18011 Extract DefaultEnhancerClassFileLocator and allow using a different implementation 2024-05-01 12:00:04 +01:00
Christian Beikov 4b172ed843 HHH-18036 Truncate time-related milliseconds when creating a java.sql.Date 2024-05-01 00:09:03 +02:00
Andrea Boriero b5b40f272a HHH-17964 Hibernate using wrong column order for ElementCollection query when composite ID is present 2024-04-25 09:59:17 +02:00
Andrea Boriero 96793faa47 HHH-17964 Add test for issue 2024-04-25 09:59:17 +02:00
Gavin King 84cdd7c93f slightly improve format of error message
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-24 23:28:54 +02:00
Marco Belladelli 9346c28c8e HHH-17983 Remove entity keys from batch queue before loading 2024-04-24 11:37:57 +02:00
Marco Belladelli c846bc3ec2 HHH-17983 Add test for issue 2024-04-24 11:37:57 +02:00
Marco Belladelli 205197bdf4 HHH-17883 Correct original column order for primary keys 2024-04-24 11:36:50 +02:00
Marco Belladelli 00d5f2f9e6 HHH-17883 Add test for issue 2024-04-24 11:36:50 +02:00
Sanne Grinovero a76a314586 HHH-17993 Metamodel processing on bootstrap: avoid retrying same metamodel class name multiple times 2024-04-23 17:35:04 +01:00
Sanne Grinovero c1dca9879f HHH-17991 Reduce overhead from @DialectOverride discovery 2024-04-23 17:35:04 +01:00
Sanne Grinovero bfd0a29e95 HHH-17988 MetadataContext should consistently use ClassLoaderService 2024-04-23 17:35:04 +01:00
Sanne Grinovero 6f8545f1a5 HHH-17987 Improve allocation rate of ReflectHelper#setterMethodOrNull 2024-04-23 17:35:04 +01:00
Sanne Grinovero cf5d09cc76 HHH-17980 Excessive contention during getter identification in the ByteBuddy enhancer 2024-04-23 17:35:04 +01:00
Christian Beikov 63551906d8 Fix HANA dialect doesRoundTemporalOnOverflow 2024-04-23 18:00:01 +02:00
Christian Beikov 94bade568a Fix SybaseASEDialect column length resolution 2024-04-23 17:07:59 +02:00
Gavin King 06139cf5da HHH-17999 use Supplier instead of Constructor
this is quite a lot cleaner

Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-23 16:23:01 +02:00
Gavin King abbfa5333e HHH-17999 use Constructor<Expectation> instead of Class<Expectation>
for Quarkus

Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-23 16:23:01 +02:00
Andrea Boriero 97a15ae194 HHH-17965 @ElementCollection with @CollectionTable throws o.h.MappingException Foreign key must have same number of columns as the referenced primary key 2024-04-23 13:51:13 +02:00
Andrea Boriero 4eb542872a HHH-17965 Add test for issue 2024-04-23 13:51:13 +02:00
Gavin King 122a659776 add an example to jdoc of SS.fetch()
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-19 21:43:26 +02:00
Gavin King daa99ab11b HHH-17955 Javadoc improvements in StatelessSession
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-19 21:43:26 +02:00
Gavin King e0e603a072 talk about lock() and refresh() in javadoc preamble for Session
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-19 21:43:26 +02:00
Gavin King 5948ad1245 two minor improvements to javadoc
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-19 21:43:26 +02:00
Gavin King a5b8a39d54 make javadoc consistent
yes, these methods actually do still accept detached objects
as of today, but that's already deprecated and we're going to
turn it off in the future

Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-19 21:43:26 +02:00
Gavin King 082e47efb7 HHH-17953 fix StatelessSession.fetch() for empty collection
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-19 21:43:26 +02:00
Gavin King 18c0fd7a78 fix an NPE that occurred if a QL 'delete' statement had no predicate (#8190)
(bug exposed by Jakarta Data TCK)

Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-19 21:43:26 +02:00
Christian Beikov 1166e64fe0 HHH-17884 Introduce special SqlTypes constants for ordinal based enums 2024-04-19 13:03:56 +02:00
Marco Belladelli d8e0ecfbf8 HHH-17916 Check type is resolved before building generic property 2024-04-19 12:40:45 +02:00
Marco Belladelli f220abd1ca HHH-17916 Add test for issue 2024-04-19 12:40:45 +02:00
Yanming Zhou cb8a1c464d HHH-17951 Deprecate unused Size.LobMultiplier 2024-04-17 18:36:49 +02:00
Steve Ebersole c90abde507 HHH-17559 - Prefer Java Time handling for all temporal values
(cherry picked from commit a996b6514e)
2024-04-12 13:13:36 -05:00
Andrea Boriero af6c8eefea Fix SybaseASEDialect column lenght resolution 2024-04-12 19:27:52 +02:00
Andrea Boriero dbaccbe6e0 Fix sybase LobSchemaUpdateTest failure 2024-04-12 19:09:54 +02:00
Andrea Boriero 1dc67a323f HHH-17761 Merging a bytecode enhanced entity with all properties set to null does not apply the update 2024-04-12 11:52:01 -05:00
Andrea Boriero 78d4cce17e HHH-17761 Add test for issue 2024-04-12 11:52:01 -05:00
marko-bekhta 2d00d4f7fa HHH-17761 Add a reproducer 2024-04-12 11:52:01 -05:00
Steve Ebersole 11d468eeb7 HHH-17946 - Avoid creating ProxyFactory if possible
(cherry picked from commit f68f6aae50)
2024-04-12 11:23:45 -05:00
Marco Belladelli 7b96a0ade2 HHH-17783 Allow early initialization of entity instance by non-owning initializer 2024-04-12 11:14:59 -05:00
gtoison b545d095ec HHH-17918 test reproducing the issue 2024-04-12 11:14:59 -05:00
Marco Belladelli 10f7f132e5 HHH-17783 Add test for issue 2024-04-12 11:14:59 -05:00
Yanming Zhou 8efcccda8d HHH-17912 Disallow multiple valued binding for BasicCollectionType
(cherry picked from commit 71234d90ae)
2024-04-12 11:02:59 -05:00
Christian Beikov 7a4e0c21f4 HHH-17932 Get rid of unnecessary synchronization 2024-04-12 14:01:59 +02:00
Gavin King e9b0656f94 add missing @since annotations
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-12 13:34:32 +02:00
Gavin King 40f1f616cb add a missing @since annotation
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-12 13:34:28 +02:00
Andrea Boriero 90e80efa48 Fix mssql LobSchemaUpdateTest failure 2024-04-12 13:34:09 +02:00
Gavin King cf184bef64 HHH-17934 limit test to databases with proper MERGE support for now
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-12 13:33:50 +02:00
Gavin King a9f1681bfc HHH-17934 sort out version handling in upsert()
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-12 13:33:45 +02:00
Gavin King da8a56b9c5 HHH-17934 generate a correct SQL merge statement
(adds the version check if necessary)

Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-12 13:33:41 +02:00
Gavin King b780e6ee77 HHH-17934 test demonstrating bug
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-12 13:33:35 +02:00
Yanming Zhou e9a7a57d13 Fix SqlTypes::isStringType 2024-04-12 13:33:14 +02:00
Yanming Zhou 4ca8377500 Add more type name alias mappings
1. MySQL returns `int` even `integer` is specified
2. H2 returns `character large object` and `binary large object` even `clob` and `blob` is specified
2024-04-12 13:33:10 +02:00
Mohammad Yasin Sadeghi 030bc54eea correct a typo 2024-04-12 13:32:50 +02:00
Gavin King 2e4ef2e252 get rid of raw types and extract methods
eliminates compiler warnings

Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-12 13:32:38 +02:00
Gavin King 85e764ee3b improve error message, as suggested by Yoann
Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-12 13:32:32 +02:00
Christian Beikov 4b863b180e HHH-17947 Bidirectional association management shouldn't ignore maintaining inverse lazy objects 2024-04-12 13:29:19 +02:00
Christian Beikov 6112a1809e HHH-17947 Add additional test for unique key loading 2024-04-12 13:29:19 +02:00
Jan Schatteman fd9a5b9861 HHH-17947 - Add test for issue
Signed-off-by: Jan Schatteman <jschatte@redhat.com>
2024-04-12 13:29:19 +02:00
Marco Belladelli 75de08372e HHH-17832 Register projection usage for circular bidirectional fetch 2024-04-11 16:33:17 +02:00
Marco Belladelli a502842b5c HHH-17832 Add test for issue 2024-04-11 16:33:17 +02:00
Yoann Rodière 0e0437715b HHH-17935 Do not use the "auto-enable" feature for the tenant ID filter
This filter already gets enabled automatically where relevant, and
critically it's not relevant when using a "root" tenant identifier.
2024-04-10 14:43:59 +02:00
Christian Beikov 94f17a92e0 HHH-17904 Introduce config property to enable native enum type 2024-04-10 14:11:44 +02:00
Christian Beikov 5d16b90826 HHH-17906 Use insert target paths for type inference of SqmValues 2024-04-10 14:11:40 +02:00
Christian Beikov 73038b47ab HHH-17884 Respect ordering guarantee of ORDINAL/STRING when using native enums 2024-04-10 14:11:36 +02:00
Marco Belladelli 661fe9ede0 HHH-10921 Add test for issue 2024-04-09 19:17:00 +02:00
Gavin King cd06e56ab2 fix previous-page navigation with KeyedResultList
It was returning the results in reverse order.
This caused a failure in the Data TCK.

Signed-off-by: Gavin King <gavin@hibernate.org>
2024-04-09 10:05:53 +02:00
Andrea Boriero a4f64540e7 HHH-17887 Release mode After Statment with deferred result set access does not work 2024-04-09 07:47:06 +02:00
Andrea Boriero 486d45bd13 HHH-17887 Add test for issue 2024-04-09 07:47:06 +02:00
Andrea Boriero d7d2294bd9 HHH-17826 ResultSet closed while scrolling results 2024-04-08 16:27:08 +02:00
Andrea Boriero 1b5419b6af HHH-17826 Add test for issue 2024-04-08 16:27:08 +02:00
Marco Belladelli 36fd9d5e18 HHH-17857 Use `fromNameExact` when determining actual table group 2024-04-08 16:17:22 +02:00
Marco Belladelli c68924d5c8 HHH-17857 Add test for issue 2024-04-08 16:17:22 +02:00
Christian Beikov 4f92a5b379 HHH-17885 Fix for same named attribute of different Embedded uses same selection expression 2024-04-04 09:24:43 +02:00