Skip to content

Commit

Permalink
Feature / Gradle update (8.12) (#488)
Browse files Browse the repository at this point in the history
* Update to latest Gradle (8.12)

* Add Gradle properties to improve build times

* Fix deprecation warnings

* Do not set parallel build globally (to many complications)

* Use parallel builds in CI

* Do not use config on demand (feature is still incubating)
  • Loading branch information
martin-traverse authored Jan 6, 2025
1 parent ac37c75 commit 4d703ce
Show file tree
Hide file tree
Showing 10 changed files with 24 additions and 23 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
cache: gradle

- name: Build
run: ./gradlew classes testClasses
run: ./gradlew classes testClasses --parallel

- name: Unit tests
run: ./gradlew test
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/integration-cloud.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ jobs:
java-version: ${{ env.JAVA_VERSION }}

- name: Build Java
run: ./gradlew testClasses
run: ./gradlew testClasses --parallel

# Auth tool will also create the secrets file if it doesn't exist
- name: Prepare secrets
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/integration-sql.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ jobs:
java-version: ${{ env.JAVA_VERSION }}

- name: Build
run: ./gradlew trac-svc-meta:testClasses
run: ./gradlew trac-svc-meta:testClasses --parallel

# Auth tool will also create the secrets file if it doesn't exist
- name: Prepare secrets
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
node-version: ${{ env.NODE_VERSION }}

- name: Platform - Build distribution files
run: ./gradlew installDist
run: ./gradlew installDist --parallel

- name: Platform - Install the sandbox
run: |
Expand Down Expand Up @@ -147,7 +147,7 @@ jobs:
cache: gradle

- name: Build
run: ./gradlew testClasses
run: ./gradlew testClasses --parallel

- name: Slow tests
run: ./gradlew integration -DintegrationTags="slow"
Expand Down Expand Up @@ -185,7 +185,7 @@ jobs:
cache: gradle

- name: Java - Build platform
run: ./gradlew testClasses
run: ./gradlew testClasses --parallel

- name: Python - setup
uses: actions/setup-python@v5
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/packaging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ jobs:
cache: gradle

- name: Build JARs
run: ./gradlew jar javadocJar sourcesJar -PincludeJavadoc=true -PincludeSources=true
run: ./gradlew jar javadocJar sourcesJar -PincludeJavadoc=true -PincludeSources=true --parallel

- name: Build packages for distribution
run: ./gradlew installDist
Expand Down
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ def versionNumber = ext.getVersionFromGit()

allprojects {

group 'org.finos.tracdap'
version versionNumber
group = 'org.finos.tracdap'
version = versionNumber
}

subprojects {
Expand Down
7 changes: 4 additions & 3 deletions gradle/publish.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,12 @@ def publishModule(Project project) {

"$project.name" (MavenPublication) {

groupId project.group
artifactId project.name
version project.version
from project.components.java

groupId = project.group
artifactId = project.name
version = project.version

pom {

name = project.name
Expand Down
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.12-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
20 changes: 10 additions & 10 deletions gradlew.bat
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@ set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if %ERRORLEVEL% equ 0 goto execute

echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
echo. 1>&2
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2
echo. 1>&2
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
echo location of your Java installation. 1>&2

goto fail

Expand All @@ -57,11 +57,11 @@ set JAVA_EXE=%JAVA_HOME%/bin/java.exe

if exist "%JAVA_EXE%" goto execute

echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
echo. 1>&2
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2
echo. 1>&2
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
echo location of your Java installation. 1>&2

goto fail

Expand Down

0 comments on commit 4d703ce

Please sign in to comment.