Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge develop into main #225

Merged
merged 129 commits into from
Oct 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
129 commits
Select commit Hold shift + click to select a range
212f53e
Bump ubi8/ubi-minimal from 8.5 to 8.6 in /app/src/main/docker
dependabot[bot] May 12, 2022
a305e52
Bump quarkus.platform.version from 2.8.3.Final to 2.9.0.Final
dependabot[bot] May 11, 2022
dd6e3fb
Added CII Best Practices Badge
Flurb May 11, 2022
ca2ed33
Bump quarkus.platform.version from 2.9.0.Final to 2.9.1.Final
dependabot[bot] May 17, 2022
6d2b67b
Bump quarkus.platform.version from 2.9.1.Final to 2.9.2.Final
dependabot[bot] May 25, 2022
e867ba4
Bump surefire-plugin.version from 3.0.0-M6 to 3.0.0-M7
dependabot[bot] Jun 7, 2022
5684f34
Bump actions/setup-java from 3.3.0 to 3.4.0
dependabot[bot] Jun 21, 2022
a43c0bb
Bump powsybl-single-line-diagram-core from 2.10.0 to 2.11.0
dependabot[bot] Jun 14, 2022
1b4a31b
Fixed compile error.
Jun 22, 2022
e385595
Bump quarkus.platform.version from 2.9.2.Final to 2.10.0.Final
dependabot[bot] Jun 22, 2022
740f475
Bump compas.core.version from 0.9.0 to 0.9.1
dependabot[bot] Jun 27, 2022
ab18956
Bump jandex-maven-plugin from 1.2.2 to 1.2.3
dependabot[bot] Jun 29, 2022
2c66ae9
Bump quarkus.platform.version from 2.10.0.Final to 2.10.1.Final
dependabot[bot] Jun 29, 2022
b2bc527
Bump quarkus.platform.version from 2.10.1.Final to 2.10.2.Final
dependabot[bot] Jul 6, 2022
831d120
Bump actions/setup-java from 3.4.0 to 3.4.1
dependabot[bot] Jul 11, 2022
58760f8
Added Postman collections.
Jul 11, 2022
b0e6c69
Updated Postman collection.
Jul 11, 2022
ff160b1
Upgrade to JDK 17
Jul 13, 2022
d3128bb
Upgrade to JDK 17
Jul 13, 2022
4b6ca26
Upgrade to JDK 17
Jul 13, 2022
5099f2b
Updated README.
Jul 14, 2022
eca7b7e
Updated documentation for development.
Jul 19, 2022
97d2674
Changed auto alignment to group all components from a single bay.
Jul 21, 2022
684d225
Updated Test Data and first step to improved checks.
Jul 21, 2022
0a911af
Updated unittest to validate XY Coordinates.
Aug 1, 2022
751df8b
Processed Review comments.
Aug 1, 2022
eeaae6b
Bump quarkus.platform.version from 2.10.2.Final to 2.10.3.Final
dependabot[bot] Jul 19, 2022
a9ce907
Bump powsybl-single-line-diagram-core from 2.11.0 to 2.12.0
dependabot[bot] Jul 22, 2022
36ac7f4
Bump gson from 2.9.0 to 2.9.1
dependabot[bot] Aug 1, 2022
f38b453
Bump quarkus.platform.version from 2.10.3.Final to 2.11.1.Final
dependabot[bot] Aug 1, 2022
11616f2
Bump quarkus.platform.version from 2.11.1.Final to 2.11.2.Final
dependabot[bot] Aug 5, 2022
6ec4ca4
Fixed sonar code smells.
Aug 10, 2022
841adae
Bump maven-javadoc-plugin from 3.4.0 to 3.4.1
dependabot[bot] Aug 15, 2022
b69a4f3
Bump slf4j-simple from 1.7.36 to 2.0.0
dependabot[bot] Aug 22, 2022
152e450
Fixed GitHub Actions.
Aug 23, 2022
eb3def1
Bump quarkus.platform.version from 2.11.2.Final to 2.11.3.Final
dependabot[bot] Aug 24, 2022
688d6e0
Bump quarkus.platform.version from 2.11.3.Final to 2.12.0.Final
dependabot[bot] Aug 31, 2022
d4dfc2c
Bump quarkus.platform.version from 2.12.0.Final to 2.12.1.Final
dependabot[bot] Sep 7, 2022
df66167
Bump compas.core.version from 0.9.1 to 0.9.2
dependabot[bot] Sep 8, 2022
47995a5
Bump actions/setup-java from 3.4.1 to 3.5.0
dependabot[bot] Sep 8, 2022
f758aae
Bump quarkus.platform.version from 2.12.1.Final to 2.12.2.Final
dependabot[bot] Sep 13, 2022
35579dd
Bump slf4j-simple from 2.0.0 to 2.0.1
dependabot[bot] Sep 14, 2022
1785d21
Bump powsybl-single-line-diagram-core from 2.12.0 to 2.13.0
dependabot[bot] Sep 16, 2022
f53f7fb
Fixed needed changes after upgrade.
Sep 19, 2022
3059554
Added some test for the provider.
Sep 19, 2022
e9496a7
Bump maven-jar-plugin from 3.2.2 to 3.3.0
dependabot[bot] Sep 16, 2022
2cd6bb1
Bump compas.core.version from 0.9.2 to 0.9.3
dependabot[bot] Sep 15, 2022
b616887
Bump quarkus.platform.version from 2.12.2.Final to 2.12.3.Final
dependabot[bot] Sep 20, 2022
7799e29
Bump slf4j-simple from 2.0.1 to 2.0.2
dependabot[bot] Sep 21, 2022
95c4b56
Bump actions/setup-java from 3.5.0 to 3.5.1
dependabot[bot] Sep 27, 2022
5171c0c
Bump quarkus.platform.version from 2.12.3.Final to 2.13.0.Final
dependabot[bot] Sep 28, 2022
7c0ebcc
Bump quarkus.platform.version from 2.13.0.Final to 2.13.1.Final
dependabot[bot] Oct 6, 2022
f7861ee
Bump quarkus.platform.version from 2.13.1.Final to 2.13.2.Final
dependabot[bot] Oct 12, 2022
d4ff874
Bump whelk-io/maven-settings-xml-action from 20 to 21
dependabot[bot] Oct 17, 2022
9eb69bf
Bump powsybl-single-line-diagram-core from 2.13.0 to 2.13.1
dependabot[bot] Oct 18, 2022
237a583
Bump actions/setup-java from 3.5.1 to 3.6.0
dependabot[bot] Oct 18, 2022
cff0767
Bump quarkus.platform.version from 2.13.2.Final to 2.13.3.Final
dependabot[bot] Oct 19, 2022
d48dc6a
Bump alex-page/github-project-automation-plus from 0.8.1 to 0.8.2
dependabot[bot] Oct 19, 2022
0de4090
Bump gson from 2.9.1 to 2.10
dependabot[bot] Oct 25, 2022
db05b8b
Bump ubi8/ubi-minimal from 8.6 to 8.7 in /app/src/main/docker
dependabot[bot] Nov 8, 2022
a0120e7
Bump quarkus.platform.version from 2.13.3.Final to 2.13.4.Final
dependabot[bot] Nov 8, 2022
095ac80
Bump quarkus.platform.version from 2.13.4.Final to 2.14.0.Final
dependabot[bot] Nov 9, 2022
47aed2e
Bump quarkus.platform.version from 2.14.0.Final to 2.14.1.Final
dependabot[bot] Nov 16, 2022
18ac99c
Bump powsybl-single-line-diagram-core from 2.13.1 to 3.0.0
dependabot[bot] Nov 18, 2022
ce46f41
Bump slf4j-simple from 2.0.3 to 2.0.4
dependabot[bot] Nov 21, 2022
e2516f7
Replace SLF4J with Log4j2 to better fit Quarkus.
Nov 21, 2022
3b282f7
Use released version of CoMPAS Core
Nov 21, 2022
1c5523a
Added logging on endpoints.
Nov 22, 2022
3edb9c5
Bump microprofile-openapi-api from 3.0 to 3.1
dependabot[bot] Nov 22, 2022
6af6255
Bump ubi8/ubi-minimal from 8.7 to 8.7-923 in /app/src/main/docker
dependabot[bot] Nov 23, 2022
f2fb7ef
Bump quarkus.platform.version from 2.14.1.Final to 2.14.2.Final
dependabot[bot] Nov 25, 2022
ffdc950
Bump actions/setup-java from 3.6.0 to 3.8.0
dependabot[bot] Dec 6, 2022
af44099
Bump quarkus.platform.version from 2.14.2.Final to 2.14.3.Final
dependabot[bot] Dec 7, 2022
6040d3f
Bump actions/setup-java from 3.8.0 to 3.9.0
dependabot[bot] Dec 14, 2022
b4c0b74
Bump ubi8/ubi-minimal from 8.7-923 to 8.7-1031 in /app/src/main/docker
dependabot[bot] Dec 22, 2022
49468ce
Bump quarkus.platform.version from 2.14.3.Final to 2.15.1.Final
dependabot[bot] Dec 22, 2022
f9bbf9d
Bump gson from 2.10 to 2.10.1
dependabot[bot] Jan 6, 2023
e6e954a
Bump quarkus.platform.version from 2.15.1.Final to 2.15.2.Final
dependabot[bot] Jan 5, 2023
e66768f
Bump quarkus.platform.version from 2.15.2.Final to 2.16.0.Final
dependabot[bot] Jan 25, 2023
2006ce0
Bump surefire-plugin.version from 3.0.0-M7 to 3.0.0-M8
dependabot[bot] Jan 30, 2023
5f4e07a
Bump ubi8/ubi-minimal from 8.7-1031 to 8.7-1049 in /app/src/main/docker
dependabot[bot] Jan 30, 2023
80f11c5
Bump alex-page/github-project-automation-plus from 0.8.2 to 0.8.3
dependabot[bot] Jan 30, 2023
31c4e0a
Bump quarkus.platform.version from 2.16.0.Final to 2.16.1.Final
dependabot[bot] Feb 1, 2023
301691c
Bump powsybl-single-line-diagram-core from 3.0.0 to 3.1.0
dependabot[bot] Jan 31, 2023
a653c39
Bump actions/setup-java from 3.9.0 to 3.10.0
dependabot[bot] Feb 7, 2023
0349e6b
Bump quarkus.platform.version from 2.16.1.Final to 2.16.2.Final
dependabot[bot] Feb 9, 2023
2bbfa3c
Bump ubi8/ubi-minimal in /app/src/main/docker
dependabot[bot] Feb 10, 2023
955a369
Bump surefire-plugin.version from 3.0.0-M8 to 3.0.0-M9
dependabot[bot] Feb 15, 2023
eec0564
Bump maven-javadoc-plugin from 3.4.1 to 3.5.0
dependabot[bot] Feb 15, 2023
78002b9
Bump quarkus.platform.version from 2.16.2.Final to 2.16.3.Final
dependabot[bot] Feb 16, 2023
0cffbbb
Bump log4j2.version from 2.19.0 to 2.20.0
dependabot[bot] Feb 21, 2023
23c4133
Bump ubi8/ubi-minimal in /app/src/main/docker
dependabot[bot] Feb 21, 2023
eb3dea7
Bump quarkus.platform.version from 2.16.3.Final to 2.16.4.Final
dependabot[bot] Mar 3, 2023
22e825a
Bump maven-compiler-plugin from 3.10.1 to 3.11.0
dependabot[bot] Mar 9, 2023
ba62377
Bump surefire-plugin.version from 3.0.0-M9 to 3.0.0
dependabot[bot] Mar 14, 2023
c361c4e
Bump quarkus.platform.version from 2.16.4.Final to 2.16.5.Final
dependabot[bot] Mar 22, 2023
5c01268
Bump actions/setup-java from 3.10.0 to 3.11.0
dependabot[bot] Mar 27, 2023
da30a4f
Bump ubi8/ubi-minimal in /app/src/main/docker
dependabot[bot] Mar 28, 2023
b90b993
Bump jacoco-maven-plugin from 0.8.8 to 0.8.9
dependabot[bot] Apr 3, 2023
1b2a72f
Bump ubi8/ubi-minimal in /app/src/main/docker
dependabot[bot] Apr 4, 2023
ce055f9
Bump quarkus.platform.version from 2.16.5.Final to 2.16.6.Final
dependabot[bot] Apr 4, 2023
b5909c2
Bump powsybl-single-line-diagram-core from 3.1.0 to 3.2.0
dependabot[bot] Apr 24, 2023
dd9ab67
Fixed import
pascalwilbrink Apr 25, 2023
aabfc54
Bump jacoco-maven-plugin from 0.8.9 to 0.8.10
dependabot[bot] Apr 25, 2023
5caa558
Bump maven-source-plugin from 3.2.1 to 3.3.0 (#205)
dependabot[bot] May 23, 2023
f075b5b
Bump ubi8/ubi-minimal from 8.7-1107 to 8.8-860 in /app/src/main/docke…
dependabot[bot] May 23, 2023
c0192e6
Upgrading to Quarkus 3.0
apupier May 26, 2023
958084e
refactor: split SC worflow into build & analysis
juancho0202 Jun 7, 2023
3dd59b0
fix: restoring actions/setup-java version
juancho0202 Jun 7, 2023
86d3f75
build(deps): Bump microprofile-openapi-api from 3.1 to 3.1.1
dependabot[bot] Jul 5, 2023
3cab33c
build(deps): Bump fsfe/reuse-action from 1 to 2
dependabot[bot] Jul 20, 2023
82e0474
Update reuse.yml
pascalwilbrink Sep 11, 2023
0a47fa4
build(deps): Bump docker/setup-buildx-action from 2 to 3
dependabot[bot] Sep 21, 2023
e2a6d9d
build(deps): Bump ubi8/ubi-minimal in /app/src/main/docker
dependabot[bot] Sep 21, 2023
a8f3dff
Bump surefire-plugin.version from 3.0.0 to 3.1.2
dependabot[bot] Jun 7, 2023
96a2cab
build(deps): Bump actions/checkout from 3 to 4
dependabot[bot] Sep 21, 2023
8375a69
build(deps): Bump docker/login-action from 2 to 3
dependabot[bot] Sep 21, 2023
48f6540
build(deps): Bump org.apache.maven.plugins:maven-javadoc-plugin (#224)
dependabot[bot] Sep 27, 2023
71ac4c3
chore: update compas-core version to 0.16.0
juancho0202 Oct 4, 2023
ef422a3
build(deps): Bump fsfe/reuse-action from 1 to 2
dependabot[bot] Jul 20, 2023
4314c3e
Update reuse.yml
pascalwilbrink Sep 11, 2023
f4035c6
Revert "Fixed import"
pascalwilbrink Oct 5, 2023
f3957a2
Updated imports
pascalwilbrink Oct 5, 2023
dff9f0d
Fixed needed changes after upgrade.
Sep 19, 2022
762d69d
build(deps): Bump fsfe/reuse-action from 1 to 2
dependabot[bot] Jul 20, 2023
8b11298
Update reuse.yml
pascalwilbrink Sep 11, 2023
e440cd6
Fixed merge conflicts
pascalwilbrink Oct 5, 2023
cc73938
Merge pull request #234 from com-pas/fix_merge_conflicts
juancho0202 Oct 5, 2023
982eea9
Merge branch 'main' into develop
pascalwilbrink Oct 5, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/build-project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Cache Docker Register
uses: actions/cache@v3
Expand All @@ -37,7 +37,7 @@ jobs:

- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
- name: Set up JDK 17
uses: actions/[email protected]
with:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/release-project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Cache Docker Register
uses: actions/cache@v3
Expand All @@ -42,9 +42,9 @@ jobs:
java-version: '17'
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_TOKEN }}
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/reuse.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: REUSE Compliance Check
uses: fsfe/reuse-action@v1
uses: fsfe/reuse-action@v2

168 changes: 96 additions & 72 deletions .github/workflows/sonarcloud-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,82 +4,106 @@

name: SonarCloud Analysis

on:
push:
branches:
- '**'
pull_request:
branches:
- 'main'
- 'develop'
pull_request_target:
branches:
- 'main'
- 'develop'
on:
workflow_run:
workflows: [SonarCloud Build]
types: [completed]

jobs:
build:
name: SonarCloud
sonar-check:
runs-on: ubuntu-latest
if: github.event.workflow_run.conclusion == 'success'
timeout-minutes: 15

if: ${{ (github.event_name != 'pull_request_target' && github.actor != 'dependabot[bot]') || (github.actor == 'dependabot[bot]' && github.event_name == 'pull_request_target') }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Cache SonarCloud packages
uses: actions/cache@v3
with:
path: ~/.sonar/cache
key: ${{ runner.os }}-sonar
restore-keys: ${{ runner.os }}-sonar
- name: Cache Maven packages
uses: actions/cache@v3
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
- name: echo event
run: cat $GITHUB_EVENT_PATH
- name: Download PR number artifact
if: github.event.workflow_run.event == 'pull_request'
uses: dawidd6/action-download-artifact@v2
with:
workflow: SonarCloud Build
run_id: ${{ github.event.workflow_run.id }}
name: PR_NUMBER
- name: Read PR_NUMBER.txt
if: github.event.workflow_run.event == 'pull_request'
id: pr_number
uses: juliangruber/read-file-action@v1
with:
path: ./PR_NUMBER.txt
- name: Request GitHub API for PR data
if: github.event.workflow_run.event == 'pull_request'
uses: octokit/[email protected]
id: get_pr_data
with:
route: GET /repos/{full_name}/pulls/{number}
number: ${{ steps.pr_number.outputs.content }}
full_name: ${{ github.event.repository.full_name }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/checkout@v4
with:
repository: ${{ github.event.workflow_run.head_repository.full_name }}
ref: ${{ github.event.workflow_run.head_branch }}
fetch-depth: 0
- name: Checkout base branch
if: github.event.workflow_run.event == 'pull_request'
run: |
git remote add upstream ${{ github.event.repository.clone_url }}
git fetch upstream
git checkout -B ${{ fromJson(steps.get_pr_data.outputs.data).base.ref }} upstream/${{ fromJson(steps.get_pr_data.outputs.data).base.ref }}
git checkout ${{ github.event.workflow_run.head_branch }}
git clean -ffdx && git reset --hard HEAD
- name: Cache SonarCloud packages
uses: actions/cache@v3
with:
path: ~/.sonar/cache
key: ${{ runner.os }}-sonar
restore-keys: ${{ runner.os }}-sonar
- name: Cache Maven packages
uses: actions/cache@v3
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2

- name: Set up JDK 17
uses: actions/[email protected]
with:
distribution: 'zulu'
java-version: '17'
- name: Set up JDK 17
uses: actions/[email protected]
with:
distribution: 'zulu'
java-version: '17'

- name: Set Common Sonar Variables
id: sonar_env
run: |
echo "##[set-output name=sonar_opts;]$(echo -Dsonar.host.url=https://sonarcloud.io \
-Dsonar.projectKey=com-pas_compas-scl-auto-alignment \
-Dsonar.organization=com-pas )"
- name: Create custom Maven Settings.xml
uses: whelk-io/maven-settings-xml-action@v21
with:
output_file: custom_maven_settings.xml
servers: '[{ "id": "github-packages-compas", "username": "OWNER", "password": "${{ secrets.GITHUB_TOKEN }}" }]'
- name: Build and analyze (Pull Request)
if: ${{ github.event_name == 'pull_request' || (github.actor == 'dependabot[bot]' && github.event_name == 'pull_request_target') }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: |
./mvnw -B -s custom_maven_settings.xml -Psonar \
${{ steps.sonar_env.outputs.sonar_opts }} \
-Dsonar.pullrequest.branch=${{ github.ref_name }} \
-Dsonar.pullrequest.key=${{ github.event.pull_request.number }} \
-Dsonar.pullrequest.base=${{ github.base_ref }} \
-Dsonar.scm.revision=${{ github.event.pull_request.head.sha }} \
clean verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
- name: Build and analyze (Push)
if: ${{ github.event_name == 'push' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: |
./mvnw -B -s custom_maven_settings.xml -Psonar \
${{ steps.sonar_env.outputs.sonar_opts }} \
-Dsonar.branch.name=${{ github.ref_name }} \
clean verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
- name: Set Common Sonar Variables
id: sonar_env
run: |
echo "##[set-output name=sonar_opts;]$(echo -Dsonar.host.url=https://sonarcloud.io \
-Dsonar.projectKey=com-pas_compas-scl-auto-alignment \
-Dsonar.organization=com-pas )"
- name: Create custom Maven Settings.xml
uses: whelk-io/maven-settings-xml-action@v21
with:
output_file: custom_maven_settings.xml
servers: '[{ "id": "github-packages-compas", "username": "OWNER", "password": "${{ secrets.GITHUB_TOKEN }}" }]'
- name: Build and analyze (Pull Request)
if: ${{ github.event.workflow_run.event == 'pull_request' || (github.event.workflow_run.actor == 'dependabot[bot]' && github.event.workflow_run.event == 'pull_request_target') }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: |
./mvnw -B -s custom_maven_settings.xml -Psonar \
${{ steps.sonar_env.outputs.sonar_opts }} \
-Dsonar.pullrequest.branch=${{ fromJson(steps.get_pr_data.outputs.data).head.ref }} \
-Dsonar.pullrequest.key=${{ fromJson(steps.get_pr_data.outputs.data).number }} \
-Dsonar.pullrequest.base=${{ fromJson(steps.get_pr_data.outputs.data).base.ref }} \
-Dsonar.scm.revision=${{ github.event.workflow_run.head_sha }} \
clean verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
- name: Build and analyze (Push)
if: ${{ github.event.workflow_run.event == 'push' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: |
./mvnw -B -s custom_maven_settings.xml -Psonar \
${{ steps.sonar_env.outputs.sonar_opts }} \
-Dsonar.scm.revision=${{ github.event.workflow_run.head_sha }} \
-Dsonar.branch.name=${{ github.event.workflow_run.head_branch }} \
clean verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
77 changes: 77 additions & 0 deletions .github/workflows/sonarcloud-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
# SPDX-FileCopyrightText: 2022 Alliander N.V.
#
# SPDX-License-Identifier: Apache-2.0

name: SonarCloud Build

on:
push:
branches:
- '**'
pull_request:
branches:
- 'main'
- 'develop'
pull_request_target:
branches:
- 'main'
- 'develop'

jobs:
precheck-build:
name: Pre Check Build
runs-on: ubuntu-latest
timeout-minutes: 30

if: ${{ (github.event_name != 'pull_request_target' && github.actor != 'dependabot[bot]') || (github.actor == 'dependabot[bot]' && github.event_name == 'pull_request_target') }}
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Cache SonarCloud packages
uses: actions/cache@v3
with:
path: ~/.sonar/cache
key: ${{ runner.os }}-sonar
restore-keys: ${{ runner.os }}-sonar
- name: Cache Maven packages
uses: actions/cache@v3
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '17'

- name: Create custom Maven Settings.xml
uses: whelk-io/maven-settings-xml-action@v21
with:
output_file: custom_maven_settings.xml
servers: '[{ "id": "github-packages-compas", "username": "OWNER", "password": "${{ secrets.GITHUB_TOKEN }}" }]'
- name: Build and analyze (Pull Request)
if: ${{ github.event_name == 'pull_request' || (github.actor == 'dependabot[bot]' && github.event_name == 'pull_request_target') }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
./mvnw -B -s custom_maven_settings.xml clean verify
- name: Build and analyze (Push)
if: ${{ github.event_name == 'push' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
./mvnw -B -s custom_maven_settings.xml clean verify
- name: Save PR number to file
if: github.event_name == 'pull_request'
run: echo ${{ github.event.number }} > PR_NUMBER.txt
- name: Archive PR number
if: github.event_name == 'pull_request'
uses: actions/upload-artifact@v3
with:
name: PR_NUMBER
path: PR_NUMBER.txt
2 changes: 1 addition & 1 deletion app/src/main/docker/Dockerfile.jvm
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
# docker run -i --rm -p 8080:8080 -p 5005:5005 -e JAVA_ENABLE_DEBUG="true" quarkus/app-jvm
#
###
FROM registry.access.redhat.com/ubi8/ubi-minimal:8.7-1107
FROM registry.access.redhat.com/ubi8/ubi-minimal:8.7-1107

ARG JAVA_PACKAGE=java-17-openjdk-headless
ARG RUN_JAVA_VERSION=1.3.8
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
import io.quarkus.runtime.annotations.RegisterForReflection;
import org.lfenergy.compas.core.commons.ElementConverter;

import javax.enterprise.context.ApplicationScoped;
import javax.enterprise.inject.Produces;
import jakarta.enterprise.context.ApplicationScoped;
import jakarta.enterprise.inject.Produces;

/**
* Create Beans from other dependencies that are used in the application.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import org.eclipse.microprofile.health.HealthCheckResponse;
import org.eclipse.microprofile.health.Liveness;

import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;

@Liveness
@ApplicationScoped
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import org.eclipse.microprofile.health.HealthCheckResponse;
import org.eclipse.microprofile.health.Readiness;

import javax.enterprise.context.ApplicationScoped;
import jakarta.enterprise.context.ApplicationScoped;

@Readiness
@ApplicationScoped
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@
import org.lfenergy.compas.scl.auto.alignment.rest.v1.model.SclAutoAlignSVGRequest;
import org.lfenergy.compas.scl.auto.alignment.service.SclAutoAlignmentService;

import javax.enterprise.context.RequestScoped;
import javax.inject.Inject;
import javax.validation.Valid;
import javax.ws.rs.Consumes;
import javax.ws.rs.POST;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.core.MediaType;
import jakarta.enterprise.context.RequestScoped;
import jakarta.inject.Inject;
import jakarta.validation.Valid;
import jakarta.ws.rs.Consumes;
import jakarta.ws.rs.POST;
import jakarta.ws.rs.Path;
import jakarta.ws.rs.Produces;
import jakarta.ws.rs.core.MediaType;

@Authenticated
@RequestScoped
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@

import org.eclipse.microprofile.openapi.annotations.media.Schema;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotEmpty;
import jakarta.xml.bind.annotation.XmlAccessType;
import jakarta.xml.bind.annotation.XmlAccessorType;
import jakarta.xml.bind.annotation.XmlElement;
import jakarta.xml.bind.annotation.XmlRootElement;
import java.util.ArrayList;
import java.util.List;

Expand Down
Loading
Loading