diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml index a70af312f7..982db2d4cc 100644 --- a/.github/release-drafter.yml +++ b/.github/release-drafter.yml @@ -1,24 +1,108 @@ name-template: $RESOLVED_VERSION tag-template: v$RESOLVED_VERSION +pull-request: + title-templates: + fix: '🐛 $TITLE (#$NUMBER)' + feat: '🚀 $TITLE (#$NUMBER)' + default: '$TITLE (#$NUMBER)' +autolabeler: + - label: 'bug' + branch: + - '/fix\/.+/' + title: + - '/fix/i' + - label: 'feature' + branch: + - '/feature\/.+/' + title: + - '/feat/i' + - label: 'documentation' + branch: + - '/docs\/.+/' + title: + - '/docs/i' + - label: 'maintenance' + branch: + - '/(chore|refactor|style|test|ci|perf|build)\/.+/' + title: + - '/(chore|refactor|style|test|ci|perf|build)/i' + - label: 'chore' + branch: + - '/chore\/.+/' + title: + - '/chore/i' + - label: 'refactor' + branch: + - '/refactor\/.+/' + title: + - '/refactor/i' + - label: 'style' + branch: + - '/style\/.+/' + title: + - '/style/i' + - label: 'test' + branch: + - '/test\/.+/' + title: + - '/test/i' + - label: 'ci' + branch: + - '/ci\/.+/' + title: + - '/ci/i' + - label: 'perf' + branch: + - '/perf\/.+/' + title: + - '/perf/i' + - label: 'build' + branch: + - '/build\/.+/' + title: + - '/build/i' + - label: 'deps' + branch: + - '/deps\/.+/' + title: + - '/deps/i' + - label: 'revert' + branch: + - '/revert\/.+/' + title: + - '/revert/i' categories: - - title: ✨ Features + - title: '🚀 Features' labels: + - 'feat' - "type: enhancement" - "type: new feature" - "type: major" - - title: 🐛 Bug Fixes/Improvements + - title: '🐛 Bug Fixes' labels: + - 'fix' + - 'bug' - "type: improvement" - "type: bug" - "type: minor" - - title: 🛠 Dependency upgrades + - title: '📚 Documentation' labels: - - "type: dependency upgrade" - - "dependencies" - - title: ⚙️ Build/CI + - 'docs' + - title: '🔧 Maintenance' labels: + - 'maintenance' + - 'chore' + - 'refactor' + - 'style' + - 'test' + - 'ci' + - 'perf' + - 'build' - "type: ci" - "type: build" + - title: '⏪ Reverts' + labels: + - 'revert' change-template: '- $TITLE @$AUTHOR (#$NUMBER)' version-resolver: major: @@ -31,8 +115,6 @@ version-resolver: labels: - 'type: patch' default: patch -commitsh: $BASE_REF_NAME -filter-by-commitsh: true template: | ## What's Changed diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index a3cf894ae2..ca0c3a1543 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -13,7 +13,7 @@ jobs: java: ['11'] env: GIT_USER_NAME: puneetbehl - GIT_USER_EMAIL: behlp@objectcomputing.com + GIT_USER_EMAIL: behlp@unityfoundation.io steps: - name: Checkout repository uses: actions/checkout@v4 @@ -21,13 +21,13 @@ jobs: token: ${{ secrets.GH_TOKEN }} ref: ${{github.event.inputs.ref}} - name: Set up JDK - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: 'adopt' java-version: ${{ matrix.java }} - name: Publish Documentation id: docs - uses: gradle/gradle-build-action@v2 + uses: gradle/gradle-build-action@v3 env: GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} @@ -53,6 +53,6 @@ jobs: FOLDER: docs/build/docs DOC_SUB_FOLDER: hibernate DOC_FOLDER: gh-pages - COMMIT_EMAIL: behlp@objectcomputing.com + COMMIT_EMAIL: behlp@unityfoundation.io COMMIT_NAME: Puneet Behl VERSION: ${{ steps.release_version.outputs.release_version }} \ No newline at end of file diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml index 24636d11ea..5f7cd7fd12 100644 --- a/.github/workflows/gradle.yml +++ b/.github/workflows/gradle.yml @@ -16,13 +16,13 @@ jobs: steps: - uses: actions/checkout@v4 - name: Set up JDK - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: 'adopt' java-version: '11' - name: Run Build id: build - uses: gradle/gradle-build-action@v2 + uses: gradle/gradle-build-action@v3 env: GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} @@ -36,12 +36,12 @@ jobs: steps: - uses: actions/checkout@v4 - name: Set up JDK - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: 'adopt' java-version: '11' - name: Publish Artifacts To Grails Artifactory (repo.grails.org) - uses: gradle/gradle-build-action@v2 + uses: gradle/gradle-build-action@v3 env: GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} @@ -52,7 +52,7 @@ jobs: arguments: -Dorg.gradle.internal.publish.checksums.insecure=true publish - name: Build Docs if: success() - uses: gradle/gradle-build-action@v2 + uses: gradle/gradle-build-action@v3 env: GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} @@ -78,5 +78,5 @@ jobs: FOLDER: docs/build/docs DOC_SUB_FOLDER: hibernate DOC_FOLDER: gh-pages - COMMIT_EMAIL: behlp@objectcomputing.com + COMMIT_EMAIL: behlp@unityfoundation.io COMMIT_NAME: Puneet Behl \ No newline at end of file diff --git a/.github/workflows/groovy-joint-workflow.yml b/.github/workflows/groovy-joint-workflow.yml new file mode 100644 index 0000000000..6ce23ee936 --- /dev/null +++ b/.github/workflows/groovy-joint-workflow.yml @@ -0,0 +1,152 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +name: "Grails Joint Validation Build" +# GROOVY_2_5_X == Grails 4.0.x +# GROOVY_3_0_X == grails master +# Groovy master branch does not map to any due to changed package names. +on: + push: + branches: + - '[8-9]+.[0-9]+.x' + pull_request: + branches: + - '[8-9]+.[0-9]+.x' + workflow_dispatch: +permissions: + contents: read +env: + CI_GROOVY_VERSION: +jobs: + build_groovy: + strategy: + fail-fast: true + runs-on: ubuntu-latest + outputs: + groovyVersion: ${{ steps.groovy-version.outputs.value }} + steps: + - name: Set up JDK + uses: actions/setup-java@v4 + with: + distribution: 'adopt' + java-version: '11.0.6' + - name: Cache local Maven repository & Groovy + uses: actions/cache@v4 + with: + path: | + ~/groovy + ~/.m2/repository + key: cache-local-groovy-maven-${{ github.sha }} + - name: Checkout Groovy 3_0_X (Grails 5 and later) + if: startsWith(github.ref, 'refs/heads/8.') || startsWith(github.base_ref, '8.') + run: cd .. && git clone --depth 1 https://github.com/apache/groovy.git -b GROOVY_3_0_X --single-branch + - name: Set CI_GROOVY_VERSION for Grails + id: groovy-version + run: | + cd ../groovy + echo "CI_GROOVY_VERSION=$(cat gradle.properties | grep groovyVersion | cut -d\= -f2 | tr -d '[:space:]')" >> $GITHUB_ENV + echo "value=$(cat gradle.properties | grep groovyVersion | cut -d\= -f2 | tr -d '[:space:]')" >> $GITHUB_OUTPUT + - name: Prepare GE Set-up Configuration + id: ge_conf + run: | + echo "VALUE<> $GITHUB_OUTPUT + echo "plugins { " >> $GITHUB_OUTPUT + echo " id 'com.gradle.enterprise' version '3.15.1'" >> $GITHUB_OUTPUT + echo " id 'com.gradle.common-custom-user-data-gradle-plugin' version '1.11.3'" >> $GITHUB_OUTPUT + echo "}" >> $GITHUB_OUTPUT + echo "" >> $GITHUB_OUTPUT + echo "gradleEnterprise {" >> $GITHUB_OUTPUT + echo " server = 'https://ge.grails.org'" >> $GITHUB_OUTPUT + echo " buildScan {" >> $GITHUB_OUTPUT + echo " publishAlways()" >> $GITHUB_OUTPUT + echo " publishIfAuthenticated()" >> $GITHUB_OUTPUT + echo " uploadInBackground = System.getenv('CI') == null" >> $GITHUB_OUTPUT + echo " capture {" >> $GITHUB_OUTPUT + echo " taskInputFiles = true" >> $GITHUB_OUTPUT + echo " }" >> $GITHUB_OUTPUT + echo " }" >> $GITHUB_OUTPUT + echo "}" >> $GITHUB_OUTPUT + echo "" >> $GITHUB_OUTPUT + echo "buildCache {" >> $GITHUB_OUTPUT + echo " local { enabled = System.getenv('CI') != 'true' }" >> $GITHUB_OUTPUT + echo " remote(HttpBuildCache) {" >> $GITHUB_OUTPUT + echo " push = System.getenv('CI') == 'true'" >> $GITHUB_OUTPUT + echo " enabled = true" >> $GITHUB_OUTPUT + echo " url = 'https://ge.grails.org/cache/'" >> $GITHUB_OUTPUT + echo " credentials {" >> $GITHUB_OUTPUT + echo " username = System.getenv('GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER')" >> $GITHUB_OUTPUT + echo " password = System.getenv('GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY')" >> $GITHUB_OUTPUT + echo " }" >> $GITHUB_OUTPUT + echo " }" >> $GITHUB_OUTPUT + echo "}" >> $GITHUB_OUTPUT + echo "" >> $GITHUB_OUTPUT + echo "EOF" >> $GITHUB_OUTPUT + - name: Gradle Enterprise Set-up + run: | + cd ../groovy + # Delete exiting plugins and build-scan from settings.gradle file + sed -i '21,31d' settings.gradle + # Add Gradle Enterprise set-up related configuration after line no 20 in settings.gradle + echo "${{ steps.ge_conf.outputs.value}}" | sed -i -e "20r /dev/stdin" settings.gradle + - name: Build and install groovy (no docs) + uses: gradle/gradle-build-action@v3 + env: + GRADLE_SCANS_ACCEPT: yes + GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} + GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} + GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY }} + with: + build-root-directory: ../groovy + arguments: | + install + -x groovydoc + -x javadoc + -x javadocAll + -x groovydocAll + -x asciidoc + -x docGDK + build_gorm_hibernate5: + needs: [build_groovy] + strategy: + fail-fast: true + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Set up JDK + uses: actions/setup-java@v4 + with: + distribution: 'adopt' + java-version: '11' + - name: Cache local Maven repository & Groovy + uses: actions/cache@v4 + with: + path: | + ~/groovy + ~/.m2/repository + key: cache-local-groovy-maven-${{ github.sha }} + - name: Set CI_GROOVY_VERSION for Grails + run: | + echo "CI_GROOVY_VERSION=${{needs.build_groovy.outputs.groovyVersion}}" >> $GITHUB_ENV + - name: Build GORM Hibernate5 + id: build_gorm_hibernate5 + uses: gradle/gradle-build-action@v3 + env: + GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} + GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} + GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY }} + with: + arguments: | + build + -x groovydoc diff --git a/.github/workflows/release-notes.yml b/.github/workflows/release-notes.yml index 0986194944..41a7037494 100644 --- a/.github/workflows/release-notes.yml +++ b/.github/workflows/release-notes.yml @@ -4,8 +4,11 @@ on: types: [closed,reopened] push: branches: - - master - '[7-9]+.[0-9]+.x' + pull_request: + types: [opened, reopened, synchronize] + pull_request_target: + types: [opened, reopened, synchronize] workflow_dispatch: jobs: release_notes: @@ -21,12 +24,10 @@ jobs: id: extract_branch run: echo "value=${GITHUB_REF:11}" >> $GITHUB_OUTPUT # If it has release drafter: - - uses: release-drafter/release-drafter@v5 + - uses: release-drafter/release-drafter@v6 if: steps.check_release_drafter.outputs.has_release_drafter == 'true' env: GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} - with: - commitish: ${{ steps.extract_branch.outputs.value }} # Otherwise: - name: Export Gradle Properties if: steps.check_release_drafter.outputs.has_release_drafter == 'false' @@ -45,4 +46,4 @@ jobs: name: ${{ env.title }} ${{ steps.release_notes.outputs.next_version }} tag: v${{ steps.release_notes.outputs.next_version }} bodyFile: CHANGELOG.md - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.GH_TOKEN }} \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 65aa94f3af..b78f29da89 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,15 +10,15 @@ jobs: java: ['11'] env: GIT_USER_NAME: puneetbehl - GIT_USER_EMAIL: behlp@objectcomputing.com + GIT_USER_EMAIL: behlp@unityfoundation.io steps: - name: Checkout repository uses: actions/checkout@v4 with: token: ${{ secrets.GH_TOKEN }} - - uses: gradle/wrapper-validation-action@v1 + - uses: gradle/wrapper-validation-action@v2 - name: Set up JDK - uses: actions/setup-java@v3 + uses: actions/setup-java@v4 with: distribution: 'adopt' java-version: ${{ matrix.java }} @@ -35,7 +35,7 @@ jobs: run: echo $SECRING_FILE | base64 -d > ${{ github.workspace }}/secring.gpg - name: Publish to Sonatype OSSRH id: publish - uses: gradle/gradle-build-action@v2 + uses: gradle/gradle-build-action@v3 env: SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} @@ -51,7 +51,7 @@ jobs: - name: Publish Documentation id: docs if: steps.publish.outcome == 'success' - uses: gradle/gradle-build-action@v2 + uses: gradle/gradle-build-action@v3 env: GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} @@ -79,7 +79,7 @@ jobs: FOLDER: docs/build/docs DOC_SUB_FOLDER: hibernate DOC_FOLDER: gh-pages - COMMIT_EMAIL: behlp@objectcomputing.com + COMMIT_EMAIL: behlp@unityfoundation.io COMMIT_NAME: Puneet Behl VERSION: ${{ steps.release_version.outputs.release_version }} - name: Run post-release diff --git a/README.md b/README.md index d233e640d0..8572b6441b 100644 --- a/README.md +++ b/README.md @@ -1,17 +1,14 @@ # GORM for Hibernate 5 +[![Maven Central](https://img.shields.io/maven-central/v/org.grails/grails-datastore-gorm-hibernate5.svg?label=Maven%20Central)](https://central.sonatype.com/artifact/org.grails/grails-datastore-gorm-hibernate5) [![Java CI](https://github.com/grails/gorm-hibernate5/workflows/Java%20CI/badge.svg?event=push)](https://github.com/grails/gorm-hibernate5/actions/workflows/gradle.yml) -This project implements [GORM](http://gorm.grails.org/latest/) for the Hibernate 5. +This project implements [GORM](https://gorm.grails.org) for the Hibernate 5. For more information see the following links: -* [Documentation](http://gorm.grails.org/latest/hibernate/manual) -* [API](http://gorm.grails.org/latest/hibernate/api) -* [Grails Plugin](https://plugins.grails.org/plugin/grails/hibernate5) -* ![Java CI](https://github.com/grails/gorm-hibernate5/workflows/Java%20CI/badge.svg) +* [Documentation](https://gorm.grails.org/latest/hibernate/manual) +* [API Reference](https://gorm.grails.org/latest/hibernate/api) For the current development version see the following links: -* [Beta Documentation](http://gorm.grails.org/snapshot/hibernate/manual) -* [Beta API](http://gorm.grails.org/snapshot/hibernate/api) - - +* [Development Snapshot Documentation](https://gorm.grails.org/snapshot/hibernate/manual) +* [Development Snapshot API Reference](https://gorm.grails.org/snapshot/hibernate/api) \ No newline at end of file diff --git a/build.gradle b/build.gradle index 49077afac2..8bf8d6d047 100644 --- a/build.gradle +++ b/build.gradle @@ -5,11 +5,11 @@ buildscript { } dependencies { classpath "org.codehaus.groovy.modules.http-builder:http-builder:0.7.2" - classpath "io.github.gradle-nexus:publish-plugin:1.3.0" + classpath "io.github.gradle-nexus:publish-plugin:2.0.0" classpath "io.github.groovylang.groovydoc:groovydoc-gradle-plugin:1.0.1" classpath "org.grails:grails-gradle-plugin:$grailsGradlePluginVersion" - classpath "org.grails.plugins:views-gradle:3.1.0" - classpath("org.asciidoctor:asciidoctor-gradle-jvm:4.0.0-alpha.1") + classpath "org.grails.plugins:views-gradle:3.2.3" + classpath("org.asciidoctor:asciidoctor-gradle-jvm:4.0.2") classpath "com.github.erdi:webdriver-binaries-gradle-plugin:3.2" } } @@ -54,6 +54,7 @@ if (isReleaseVersion) { subprojects { Project subproject -> repositories { + mavenLocal() maven { url "https://repo.grails.org/grails/core" } if(groovyVersion && groovyVersion.endsWith('-SNAPSHOT')) { maven { @@ -63,6 +64,10 @@ subprojects { Project subproject -> } } + ext { + groovyVersion = System.getenv('CI_GROOVY_VERSION') ?: project.groovyVersion + } + configurations.all { resolutionStrategy.dependencySubstitution { substitute module("org.codehaus.groovy:groovy-all") with module("org.codehaus.groovy:groovy:$groovyVersion") @@ -113,11 +118,11 @@ subprojects { Project subproject -> } dependencies { - testImplementation "io.projectreactor:reactor-test:3.5.11" + testImplementation "io.projectreactor:reactor-test:3.6.5" testImplementation "org.codehaus.groovy:groovy-test-junit5:$groovyVersion" testImplementation("org.spockframework:spock-core:$spockVersion") { transitive = false} testImplementation "org.junit.jupiter:junit-jupiter-api:$junitJupiterVersion" - testImplementation "org.junit.platform:junit-platform-runner:1.10.1" + testImplementation "org.junit.platform:junit-platform-runner:1.10.2" testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:$junitJupiterVersion" } @@ -221,7 +226,7 @@ subprojects { Project subproject -> testImplementation "org.codehaus.groovy:groovy-test-junit5:$groovyVersion" testImplementation("org.spockframework:spock-core:$spockVersion") { transitive = false} testImplementation "org.junit.jupiter:junit-jupiter-api:$junitJupiterVersion" - testImplementation "org.junit.platform:junit-platform-runner:1.10.1" + testImplementation "org.junit.platform:junit-platform-runner:1.10.2" testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:$junitJupiterVersion" } @@ -288,7 +293,7 @@ subprojects { Project subproject -> developer { id = 'puneetbehl' name = 'Puneet Behl' - email = 'behlp@objectcomputing.com' + email = 'behlp@unityfoundation.io' } } } diff --git a/gradle.properties b/gradle.properties index 1173ff6d96..e4e1e08772 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,36 +1,35 @@ assetPipelineVersion=3.3.4 gebVersion=2.3 -gormVersion=8.0.2 -grailsGradlePluginVersion=6.1.0 -groovyVersion=3.0.11 +gormVersion=8.1.2 +grailsGradlePluginVersion=6.2.0 +groovyVersion=3.0.21 h2Version=1.4.200 hibernate5Version=5.6.15.Final hibernateValidatorVersion=6.2.5.Final hibernateGroovyProxy=1.1 jansiVersion=2.4.1 -javaParserCoreVersion=3.25.5 -jaxbVersion=2.3.1 -junitJupiterVersion=5.10.1 +javaParserCoreVersion=3.25.10 +junitJupiterVersion=5.10.2 picocliVersion=4.7.5 -projectVersion=8.0.2-SNAPSHOT -pluginGrailsVersion=6.1.0 +projectVersion=8.1.1-SNAPSHOT +pluginGrailsVersion=6.2.0 seleniumSafariDriverVersion=3.14.0 seleniumVersion=3.14.0 servletApiVersion=4.0.1 slf4jVersion=1.7.36 snakeyamlVersion=2.2 spockVersion=2.1-groovy-3.0 -springBootVersion=2.7.16 -springVersion=5.3.30 +springBootVersion=2.7.18 +springVersion=5.3.33 tomcatLog4jVersion=8.5.2 -tomcatVersion=9.0.82 +tomcatVersion=9.0.87 # Following are used only for example projects fieldsVersion=3.0.0.RC1 -grailsVersion=6.1.0 +grailsVersion=6.2.0 micrometer.version=1.8.0 scaffoldingVersion=4.1.0 -testingSupportVersion=3.1.0 +testingSupportVersion=3.2.2 org.gradle.caching=true org.gradle.parallel=false org.gradle.daemon=true diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index b1624c473c..c7d437bbb4 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.3-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.4-bin.zip networkTimeout=10000 zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/grails-datastore-gorm-hibernate5/build.gradle b/grails-datastore-gorm-hibernate5/build.gradle index 4ae7c00872..b4fa650be4 100644 --- a/grails-datastore-gorm-hibernate5/build.gradle +++ b/grails-datastore-gorm-hibernate5/build.gradle @@ -20,8 +20,8 @@ dependencies { } api 'javax.validation:validation-api:2.0.1.Final' runtimeOnly('javax.el:javax.el-api:3.0.1-b06') - runtimeOnly "javax.xml.bind:jaxb-api:$jaxbVersion" - runtimeOnly "com.sun.xml.bind:jaxb-impl:$jaxbVersion" + runtimeOnly "javax.xml.bind:jaxb-api:2.3.1" + runtimeOnly "com.sun.xml.bind:jaxb-impl:4.0.5" compileOnly ("net.sf.ehcache:ehcache-core:2.6.11") { exclude group: 'commons-logging', module:'commons-logging' diff --git a/grails-datastore-gorm-hibernate5/src/main/groovy/org/grails/orm/hibernate/AbstractHibernateGormStaticApi.groovy b/grails-datastore-gorm-hibernate5/src/main/groovy/org/grails/orm/hibernate/AbstractHibernateGormStaticApi.groovy index 018d8f8b9f..d471936507 100644 --- a/grails-datastore-gorm-hibernate5/src/main/groovy/org/grails/orm/hibernate/AbstractHibernateGormStaticApi.groovy +++ b/grails-datastore-gorm-hibernate5/src/main/groovy/org/grails/orm/hibernate/AbstractHibernateGormStaticApi.groovy @@ -771,7 +771,7 @@ abstract class AbstractHibernateGormStaticApi extends GormStaticApi { protected List removeNullNames(Map query) { List nullNames = [] - Set allNames = new HashSet(query.keySet()) + Set allNames = new HashSet<>(query.keySet() as Set) for (String name in allNames) { if (query[name] == null) { query.remove name diff --git a/grails-datastore-gorm-hibernate5/src/main/groovy/org/grails/orm/hibernate/cfg/GrailsDomainBinder.java b/grails-datastore-gorm-hibernate5/src/main/groovy/org/grails/orm/hibernate/cfg/GrailsDomainBinder.java index 004a88bf96..3e1d914eb3 100644 --- a/grails-datastore-gorm-hibernate5/src/main/groovy/org/grails/orm/hibernate/cfg/GrailsDomainBinder.java +++ b/grails-datastore-gorm-hibernate5/src/main/groovy/org/grails/orm/hibernate/cfg/GrailsDomainBinder.java @@ -1615,6 +1615,7 @@ protected void bindJoinedSubClass(HibernatePersistentEntity sub, JoinedSubclass bindSimpleValue(identifier.getType().getName(), key, false, columnName, mappings); joinedSubclass.createPrimaryKey(); + joinedSubclass.createForeignKey(); // properties createClassProperties(sub, joinedSubclass, mappings, sessionFactoryBeanName); diff --git a/settings.gradle b/settings.gradle index 4d88995822..c190c2f342 100644 --- a/settings.gradle +++ b/settings.gradle @@ -1,6 +1,6 @@ plugins { - id "com.gradle.enterprise" version "3.15.1" - id 'com.gradle.common-custom-user-data-gradle-plugin' version '1.11.3' + id "com.gradle.enterprise" version "3.17.1" + id 'com.gradle.common-custom-user-data-gradle-plugin' version '2.0' } gradleEnterprise { @@ -13,19 +13,17 @@ gradleEnterprise { taskInputFiles = true } } + } buildCache { local { enabled = System.getenv('CI') != 'true' } - remote(HttpBuildCache) { - push = System.getenv('CI') == 'true' + remote(gradleEnterprise.buildCache) { + def isAuthenticated = System.getenv('GRADLE_ENTERPRISE_ACCESS_KEY') + push = System.getenv('CI') == 'true' && isAuthenticated enabled = true - url = 'https://ge.grails.org/cache/' - credentials { - username = System.getenv('GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER') - password = System.getenv('GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY') - } - }} + } +} // Core