Skip to content

Commit 971c9f8

Browse files
authored
Revert "Add java matrix to GHA (#725)" (#727)
This reverts commit 16672a9.
1 parent 16672a9 commit 971c9f8

File tree

11 files changed

+30
-88
lines changed

11 files changed

+30
-88
lines changed

.github/dependabot.yml

Lines changed: 0 additions & 18 deletions
This file was deleted.

.github/workflows/ci.yml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,12 @@ on:
1111
jobs:
1212
build:
1313
runs-on: ubuntu-latest
14-
strategy:
15-
matrix:
16-
java: [21, 23]
1714
steps:
18-
- uses: actions/checkout@v5
19-
- uses: actions/setup-java@v5
15+
- uses: actions/checkout@v4
16+
- uses: actions/setup-java@v4
2017
with:
2118
distribution: 'temurin' # See 'Supported distributions' for available options
22-
java-version: ${{ matrix.java }}
19+
java-version: '17'
2320
cache: 'gradle'
2421
- name: Build
25-
run: ./gradlew check -PjavaVersion=${{ matrix.java }}
22+
run: ./gradlew check

.github/workflows/codeql.yml

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -12,41 +12,39 @@
1212
name: "CodeQL"
1313

1414
on:
15+
push:
16+
branches: [ "master" ]
1517
pull_request:
16-
branches:
17-
- master
18-
- main
19-
18+
# The branches below must be a subset of the branches above
19+
branches: [ "master" ]
2020
schedule:
2121
- cron: '36 5 * * 4'
22+
2223
jobs:
2324
analyze:
24-
name: Analyze (Java ${{ matrix.java }})
25+
name: Analyze
2526
runs-on: ubuntu-latest
2627
permissions:
2728
actions: read
2829
contents: read
2930
security-events: write
30-
env:
31-
ORG_GRADLE_PROJECT_javaVersion: ${{ matrix.java }}
3231

3332
strategy:
3433
fail-fast: false
3534
matrix:
3635
language: [ 'java' ]
37-
java: [21, 23]
3836
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
3937
# Use only 'java' to analyze code written in Java, Kotlin or both
4038
# Use only 'javascript' to analyze code written in JavaScript, TypeScript or both
4139
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
4240

4341
steps:
4442
- name: Checkout repository
45-
uses: actions/checkout@v5
43+
uses: actions/checkout@v4
4644

4745
# Initializes the CodeQL tools for scanning.
4846
- name: Initialize CodeQL
49-
uses: github/codeql-action/init@v4
47+
uses: github/codeql-action/init@v3
5048
with:
5149
languages: ${{ matrix.language }}
5250
# If you wish to specify custom queries, you can do so here or in a config file.
@@ -56,16 +54,16 @@ jobs:
5654
# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
5755
# queries: security-extended,security-and-quality
5856

59-
- uses: actions/setup-java@v5
57+
- uses: actions/setup-java@v4
6058
with:
6159
distribution: 'temurin' # See 'Supported distributions' for available options
62-
java-version: ${{ matrix.java }}
60+
java-version: '17'
6361

6462

6563
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, or Java).
6664
# If this step fails, then you should remove it and run the build manually (see below)
6765
- name: Autobuild
68-
uses: github/codeql-action/autobuild@v4
66+
uses: github/codeql-action/autobuild@v3
6967

7068
# ℹ️ Command-line programs to run using the OS shell.
7169
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
@@ -78,6 +76,6 @@ jobs:
7876
# ./location_of_script_within_repo/buildscript.sh
7977

8078
- name: Perform CodeQL Analysis
81-
uses: github/codeql-action/analyze@v4
79+
uses: github/codeql-action/analyze@v3
8280
with:
8381
category: "/language:${{matrix.language}}"

.github/workflows/publish-openapi.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@ name: Publish OpenAPI specs
22
on:
33
push:
44
branches:
5-
- master
6-
- main
5+
- "master"
76

87
jobs:
98
publish-openapi:
@@ -12,4 +11,4 @@ jobs:
1211
SWAGGER_PUBLISHER_API_TOKEN: ${{ secrets.SWAGGER_PUBLISHER_API_TOKEN }}
1312
with:
1413
test_to_run: 'uk.gov.hmcts.reform.demo.openapi.OpenAPIPublisherTest'
15-
java_version: 21
14+
java_version: 17

.github/workflows/secrets-scanner.yml

Lines changed: 0 additions & 23 deletions
This file was deleted.

README.md

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -89,16 +89,6 @@ The template contains the following plugins:
8989
9090
Located in `./bin/init.sh`. Simply run and follow the explanation how to execute it.
9191
92-
## Java version
93-
94-
The HMCTS Java plugin configures the Gradle toolchain using the `javaVersion` project property.
95-
This template defaults to Java 21, so no extra flag is needed for local development. When you want
96-
to be explicit (for example in CI), pass the property on the command line, e.g.
97-
98-
```bash
99-
./gradlew check -PjavaVersion=21
100-
```
101-
10292
## Building and deploying the application
10393
10494
### Building the application
@@ -184,3 +174,4 @@ There is no need to remove postgres and java or similar core images.
184174
## License
185175

186176
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details
177+

build.gradle

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ plugins {
33
id 'jacoco'
44
id 'io.spring.dependency-management' version '1.1.7'
55
id 'org.springframework.boot' version '3.5.5'
6-
id 'com.github.ben-manes.versions' version '0.53.0'
6+
id 'com.github.ben-manes.versions' version '0.52.0'
77
id 'org.sonarqube' version '6.3.1.5724'
88
/*
99
Applies analysis tools including checkstyle and OWASP Dependency checker.
@@ -20,9 +20,7 @@ application {
2020

2121
java {
2222
toolchain {
23-
languageVersion = JavaLanguageVersion.of(
24-
findProperty("javaVersion")?.toInteger() ?: 21
25-
)
23+
languageVersion = JavaLanguageVersion.of(21)
2624
}
2725
}
2826

@@ -42,15 +40,12 @@ def configureSourceSet(String name) {
4240
configurations {
4341
functionalTestImplementation.extendsFrom testImplementation
4442
functionalTestRuntimeOnly.extendsFrom runtimeOnly
45-
functionalTestRuntimeOnly.extendsFrom testRuntimeOnly
4643

4744
integrationTestImplementation.extendsFrom testImplementation
4845
integrationTestRuntimeOnly.extendsFrom runtimeOnly
49-
integrationTestRuntimeOnly.extendsFrom testRuntimeOnly
5046

5147
smokeTestImplementation.extendsFrom testImplementation
5248
smokeTestRuntimeOnly.extendsFrom runtimeOnly
53-
smokeTestRuntimeOnly.extendsFrom testRuntimeOnly
5449
}
5550

5651
tasks.withType(JavaCompile).configureEach {
@@ -138,8 +133,8 @@ repositories {
138133
}
139134

140135
ext {
141-
log4JVersion = "2.25.2"
142-
logbackVersion = "1.5.19"
136+
log4JVersion = "2.25.1"
137+
logbackVersion = "1.5.18"
143138
}
144139

145140
ext['snakeyaml.version'] = '2.0'
@@ -160,7 +155,6 @@ dependencies {
160155

161156
testImplementation group: 'org.springframework.boot', name: 'spring-boot-starter-test'
162157
testImplementation group: 'io.rest-assured', name: 'rest-assured', version: '5.5.6'
163-
testRuntimeOnly group: 'org.junit.platform', name: 'junit-platform-launcher'
164158
}
165159

166160
bootJar {

gradle/wrapper/gradle-wrapper.jar

-1.65 KB
Binary file not shown.

gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-9.1.0-all.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-all.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

gradlew

Lines changed: 4 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)