Skip to content

Commit 513fd1c

Browse files
authored
Merge branch 'main' into main-perf
2 parents 6204335 + a415555 commit 513fd1c

File tree

947 files changed

+45349
-9910
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

947 files changed

+45349
-9910
lines changed

Jenkinsfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ stage('Build') {
181181
state[buildEnv.tag]['containerName'] = "postgres"
182182
break;
183183
case "edb":
184-
docker.image('quay.io/enterprisedb/edb-postgres-advanced:14.5-3.2-postgis').pull()
184+
docker.image('quay.io/enterprisedb/edb-postgres-advanced:15.2-3.3-postgis').pull()
185185
sh "./docker_db.sh edb"
186186
state[buildEnv.tag]['containerName'] = "edb"
187187
break;

README.adoc

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
1-
Hibernate ORM is a library providing Object/Relational Mapping (ORM) support
2-
to applications, libraries, and frameworks.
1+
Hibernate ORM is a powerful object/relational mapping solution for Java, and makes it easy to develop persistence logic for applications, libraries, and frameworks.
32

4-
It also provides an implementation of the JPA specification, which is the standard Java specification for ORM.
3+
Hibernate implements JPA, the standard API for object/relational persistence in Java, but also offers an extensive set of features and APIs which go beyond the specification.
54

6-
This is the repository of its source code; see https://hibernate.org/orm/[Hibernate.org] for additional information.
5+
See https://hibernate.org/orm/[Hibernate.org] for more information.
76

87
image:https://ci.hibernate.org/job/hibernate-orm-pipeline/job/main/badge/icon[Build Status,link=https://ci.hibernate.org/job/hibernate-orm-pipeline/job/main/]
98
image:https://img.shields.io/badge/Revved%20up%20by-Gradle%20Enterprise-06A0CE?logo=Gradle&labelColor=02303A[link=https://ge.hibernate.org/scans]
@@ -18,7 +17,7 @@ for its CI needs. See
1817

1918
== Building from sources
2019

21-
The build requires at least Java 11 JDK.
20+
The build requires at least Java 11 and at most Java 17.
2221

2322
Hibernate uses https://gradle.org[Gradle] as its build tool. See the _Gradle Primer_ section below if you are new to
2423
Gradle.

checkerstubs/jboss.logging.astub

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
// Checkerframework stubs for the jboss.logging module
2+
3+
package org.jboss.logging;
4+
5+
import org.checkerframework.checker.nullness.qual.Nullable;
6+
7+
public interface BasicLogger {
8+
void tracef(String format, @Nullable Object param1, @Nullable Object param2);
9+
}

databases/cockroachdb/matrix.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,4 @@
1111
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
1212
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
1313
*/
14-
jdbcDependency 'org.postgresql:postgresql:42.2.8'
14+
jdbcDependency 'org.postgresql:postgresql:42.6.0'

databases/db2/matrix.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
66
*/
77

8-
jdbcDependency 'com.ibm.db2:jcc:11.5.7.0'
8+
jdbcDependency 'com.ibm.db2:jcc:11.5.8.0'

databases/derby/matrix.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
66
*/
77
//databaseProfile {
8-
jdbcDependency 'org.apache.derby:derby:10.14.2.0'
8+
jdbcDependency 'org.apache.derby:derby:10.15.2.0'
99

1010
// testing {
1111
// beforeSuite {

databases/hana/matrix.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
66
*/
77

8-
jdbcDependency 'com.sap.cloud.db.jdbc:ngdbc:2.4.59'
8+
jdbcDependency 'com.sap.cloud.db.jdbc:ngdbc:2.16.14'

databases/mariadb/matrix.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
55
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
66
*/
7-
jdbcDependency 'org.mariadb.jdbc:mariadb-java-client:2.7.7'
7+
jdbcDependency 'org.mariadb.jdbc:mariadb-java-client:2.7.9'

databases/mssqlserver/matrix.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
66
*/
77

8-
jdbcDependency 'com.microsoft.sqlserver:mssql-jdbc:6.4.0.jre8'
8+
jdbcDependency 'com.microsoft.sqlserver:mssql-jdbc:12.2.0.jre11'

databases/mysql/matrix.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
55
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
66
*/
7-
jdbcDependency 'mysql:mysql-connector-java:8.0.27'
7+
jdbcDependency 'com.mysql:mysql-connector-j:8.0.33'

databases/oracle/matrix.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
55
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
66
*/
7-
jdbcDependency 'com.oracle.database.jdbc:ojdbc8:21.8.0.0'
7+
jdbcDependency 'com.oracle.database.jdbc:ojdbc11:23.2.0.0'

databases/pgsql/matrix.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
55
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
66
*/
7-
jdbcDependency 'org.postgresql:postgresql:42.2.19'
7+
jdbcDependency 'org.postgresql:postgresql:42.6.0'

docker_db.sh

Lines changed: 49 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ postgresql_15() {
147147
}
148148

149149
edb() {
150-
edb_14
150+
edb_15
151151
}
152152

153153
edb_10() {
@@ -164,6 +164,13 @@ edb_14() {
164164
$CONTAINER_CLI run --name edb -e POSTGRES_USER=hibernate_orm_test -e POSTGRES_PASSWORD=hibernate_orm_test -e POSTGRES_DB=hibernate_orm_test -p 5444:5444 -d edb-test:14
165165
}
166166

167+
edb_15() {
168+
$CONTAINER_CLI rm -f edb || true
169+
# We need to build a derived image because the existing image is mainly made for use by a kubernetes operator
170+
(cd edb; $CONTAINER_CLI build -t edb-test:15 -f edb15.Dockerfile .)
171+
$CONTAINER_CLI run --name edb -e POSTGRES_USER=hibernate_orm_test -e POSTGRES_PASSWORD=hibernate_orm_test -e POSTGRES_DB=hibernate_orm_test -p 5444:5444 -d edb-test:15
172+
}
173+
167174
db2() {
168175
db2_11_5
169176
}
@@ -645,6 +652,46 @@ cockroachdb() {
645652
cockroachdb_22_2
646653
}
647654

655+
cockroachdb_23_1() {
656+
$CONTAINER_CLI rm -f cockroach || true
657+
LOG_CONFIG="
658+
sinks:
659+
stderr:
660+
channels: all
661+
filter: ERROR
662+
redact: false
663+
exit-on-error: true
664+
"
665+
$CONTAINER_CLI run -d --name=cockroach -m 6g -p 26257:26257 -p 8080:8080 cockroachdb/cockroach-unstable:v23.1.0-rc.1 start-single-node \
666+
--insecure --store=type=mem,size=0.25 --advertise-addr=localhost --log="$LOG_CONFIG"
667+
OUTPUT=
668+
while [[ $OUTPUT != *"CockroachDB node starting"* ]]; do
669+
echo "Waiting for CockroachDB to start..."
670+
sleep 10
671+
# Note we need to redirect stderr to stdout to capture the logs
672+
OUTPUT=$($CONTAINER_CLI logs cockroach 2>&1)
673+
done
674+
echo "Enabling experimental box2d operators and some optimized settings for running the tests"
675+
#settings documented in https://www.cockroachlabs.com/docs/v22.1/local-testing.html#use-a-local-single-node-cluster-with-in-memory-storage
676+
$CONTAINER_CLI exec cockroach bash -c "cat <<EOF | ./cockroach sql --insecure
677+
SET CLUSTER SETTING sql.spatial.experimental_box2d_comparison_operators.enabled = on;
678+
SET CLUSTER SETTING kv.raft_log.disable_synchronization_unsafe = true;
679+
SET CLUSTER SETTING kv.range_merge.queue_interval = '50ms';
680+
SET CLUSTER SETTING jobs.registry.interval.gc = '30s';
681+
SET CLUSTER SETTING jobs.registry.interval.cancel = '180s';
682+
SET CLUSTER SETTING jobs.retention_time = '15s';
683+
SET CLUSTER SETTING sql.stats.automatic_collection.enabled = false;
684+
SET CLUSTER SETTING kv.range_split.by_load_merge_delay = '5s';
685+
ALTER RANGE default CONFIGURE ZONE USING "gc.ttlseconds" = 600;
686+
ALTER DATABASE system CONFIGURE ZONE USING "gc.ttlseconds" = 600;
687+
688+
quit
689+
EOF
690+
"
691+
echo "Cockroachdb successfully started"
692+
693+
}
694+
648695
cockroachdb_22_2() {
649696
$CONTAINER_CLI rm -f cockroach || true
650697
LOG_CONFIG="
@@ -800,6 +847,7 @@ if [ -z ${1} ]; then
800847
echo "No db name provided"
801848
echo "Provide one of:"
802849
echo -e "\tcockroachdb"
850+
echo -e "\tcockroachdb_23_1"
803851
echo -e "\tcockroachdb_22_2"
804852
echo -e "\tcockroachdb_22_1"
805853
echo -e "\tcockroachdb_21_1"

documentation/documentation.gradle

Lines changed: 153 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,15 @@
11
import org.asciidoctor.gradle.jvm.AsciidoctorTask
2+
import org.asciidoctor.gradle.jvm.pdf.AsciidoctorPdfTask
23

34
plugins {
45
id 'org.asciidoctor.jvm.convert' version '3.3.2'
6+
id 'org.asciidoctor.jvm.pdf' version '3.3.2'
7+
id "org.asciidoctor.jvm.gems" version "3.3.2"
8+
}
9+
10+
repositories {
11+
mavenCentral()
12+
ruby.gems()
513
}
614

715
/*
@@ -37,6 +45,8 @@ dependencies {
3745
reportAggregation project(':hibernate-ant')
3846
reportAggregation project(':hibernate-enhance-maven-plugin')
3947
reportAggregation project(':hibernate-jpamodelgen')
48+
49+
asciidoctorGems 'rubygems:rouge:4.1.1'
4050
}
4151

4252

@@ -65,9 +75,15 @@ tasks.register('buildDocsForPublishing') {
6575

6676

6777
asciidoctorj {
78+
requires 'rouge'
79+
modules {
80+
pdf {
81+
version '2.3.7'
82+
}
83+
}
6884
attributes icons: 'font',
6985
experimental: true,
70-
'source-highlighter': 'prettify',
86+
'source-highlighter': 'rouge',
7187
majorMinorVersion: rootProject.ormVersion.family,
7288
fullVersion: rootProject.ormVersion.fullName
7389

@@ -77,6 +93,7 @@ asciidoctorj {
7793
// Topical Guides ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
7894

7995
tasks.register('renderTopicalGuides', AsciidoctorTask) { task ->
96+
group = "Documentation"
8097
description = 'Renders the Topical Guides in HTML format using Asciidoctor.'
8198
tasks.buildDocs.dependsOn task
8299
tasks.buildDocsForPublishing.dependsOn task
@@ -96,6 +113,7 @@ tasks.register('renderTopicalGuides', AsciidoctorTask) { task ->
96113
// Getting Started Guides (quick starts) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
97114

98115
tasks.register('renderGettingStartedGuides', AsciidoctorTask) { task ->
116+
group = "Documentation"
99117
description = 'Renders the Getting Started Guides (quick starts) in HTML format using Asciidoctor.'
100118
tasks.buildDocs.dependsOn task
101119
tasks.buildDocsForPublishing.dependsOn task
@@ -123,9 +141,116 @@ tasks.register('buildTutorialZip', Zip) { task ->
123141
}
124142

125143

144+
// Introduction ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
145+
146+
tasks.register('renderIntroductionPdf', AsciidoctorPdfTask) {task->
147+
group = "Documentation"
148+
description = 'Renders the Introduction in PDF format using Asciidoctor.'
149+
tasks.buildDocs.dependsOn task
150+
tasks.buildDocsForPublishing.dependsOn task
151+
inputs.property "hibernate-version", project.ormVersion
152+
153+
sourceDir = file( 'src/main/asciidoc/introduction' )
154+
baseDir = file( 'src/main/asciidoc/introduction' )
155+
sources {
156+
include 'Hibernate_Introduction.adoc'
157+
}
158+
outputDir = "$buildDir/asciidoc/introduction/pdf"
159+
160+
attributes jpaJavadocUrlPrefix: "https://javaee.github.io/javaee-spec/javadocs/javax/persistence/"
161+
}
162+
163+
tasks.register('renderIntroduction', AsciidoctorTask) {task->
164+
group = "Documentation"
165+
description = 'Renders the Introduction in HTML format using Asciidoctor.'
166+
tasks.buildDocs.dependsOn task
167+
tasks.buildDocsForPublishing.dependsOn task
168+
inputs.property "hibernate-version", project.ormVersion
169+
170+
sourceDir = file( 'src/main/asciidoc/introduction' )
171+
sources {
172+
include 'Hibernate_Introduction.adoc'
173+
}
174+
outputDir = "$buildDir/asciidoc/introduction/html_single"
175+
176+
attributes linkcss: true,
177+
stylesheet: "css/hibernate.css",
178+
docinfo: 'private',
179+
jpaJavadocUrlPrefix: "https://javaee.github.io/javaee-spec/javadocs/javax/persistence/"
180+
181+
resources {
182+
from('src/main/asciidoc/introduction/') {
183+
include 'images/**'
184+
}
185+
from('src/main/style/asciidoctor') {
186+
include 'images/**'
187+
}
188+
from('src/main/style/asciidoctor') {
189+
include 'css/**'
190+
}
191+
from('src/main/style/asciidoctor') {
192+
include 'js/**'
193+
}
194+
}
195+
}
196+
197+
// HQL Guide ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
198+
199+
tasks.register('renderQLPdf', AsciidoctorPdfTask) {task->
200+
group = "Documentation"
201+
description = 'Renders the Query Language document in PDF format using Asciidoctor.'
202+
tasks.buildDocs.dependsOn task
203+
tasks.buildDocsForPublishing.dependsOn task
204+
inputs.property "hibernate-version", project.ormVersion
205+
206+
sourceDir = file( 'src/main/asciidoc/querylanguage' )
207+
baseDir = file( 'src/main/asciidoc/querylanguage' )
208+
sources {
209+
include 'Hibernate_Query_Language.adoc'
210+
}
211+
outputDir = "$buildDir/asciidoc/querylanguage/pdf"
212+
213+
attributes jpaJavadocUrlPrefix: "https://javaee.github.io/javaee-spec/javadocs/javax/persistence/"
214+
}
215+
216+
tasks.register('renderQL', AsciidoctorTask) {task->
217+
group = "Documentation"
218+
description = 'Renders the Query Language document in HTML format using Asciidoctor.'
219+
tasks.buildDocs.dependsOn task
220+
tasks.buildDocsForPublishing.dependsOn task
221+
inputs.property "hibernate-version", project.ormVersion
222+
223+
sourceDir = file( 'src/main/asciidoc/querylanguage' )
224+
sources {
225+
include 'Hibernate_Query_Language.adoc'
226+
}
227+
outputDir = "$buildDir/asciidoc/querylanguage/html_single"
228+
229+
attributes linkcss: true,
230+
stylesheet: "css/hibernate.css",
231+
docinfo: 'private',
232+
jpaJavadocUrlPrefix: "https://javaee.github.io/javaee-spec/javadocs/javax/persistence/"
233+
234+
resources {
235+
from('src/main/asciidoc/querylanguage/') {
236+
include 'images/**'
237+
}
238+
from('src/main/style/asciidoctor') {
239+
include 'images/**'
240+
}
241+
from('src/main/style/asciidoctor') {
242+
include 'css/**'
243+
}
244+
from('src/main/style/asciidoctor') {
245+
include 'js/**'
246+
}
247+
}
248+
}
249+
126250
// User Guide ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
127251

128252
tasks.register('renderUserGuide', AsciidoctorTask) { task ->
253+
group = "Documentation"
129254
description = 'Renders the User Guides in HTML format using Asciidoctor.'
130255
tasks.buildDocs.dependsOn task
131256
tasks.buildDocsForPublishing.dependsOn task
@@ -267,6 +392,33 @@ tasks.register('renderLoggingReport', AsciidoctorTask) { task ->
267392
}
268393
}
269394

395+
tasks.register('renderDialectReport', AsciidoctorTask) { task ->
396+
group 'Documentation'
397+
description = 'Renders the ORM Dialect report in HTML format using Asciidoctor.'
398+
dependsOn tasks.generateDialectReport
399+
tasks.renderOrmReports.dependsOn task
400+
inputs.property "version", project.ormVersion
401+
402+
sourceDir = layout.buildDirectory.dir('orm/reports')
403+
sources {
404+
include 'dialect.adoc'
405+
}
406+
407+
outputDir = project.layout.buildDirectory.dir('asciidoc/dialect')
408+
409+
attributes linkcss: true,
410+
stylesheet: "css/hibernate.css"
411+
412+
resources {
413+
from('src/main/style/asciidoctor') {
414+
include 'images/**'
415+
}
416+
from('src/main/style/asciidoctor') {
417+
include 'css/**'
418+
}
419+
}
420+
}
421+
270422

271423
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
272424

0 commit comments

Comments
 (0)