From 869e137e0535af099d789224b11d1548c2322666 Mon Sep 17 00:00:00 2001 From: SristiSingh-eu Date: Thu, 9 Nov 2023 10:58:38 +0100 Subject: [PATCH 1/8] EA-3623 add github action on push --- .github/workflows/build_test_analyse.yml | 35 ++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .github/workflows/build_test_analyse.yml diff --git a/.github/workflows/build_test_analyse.yml b/.github/workflows/build_test_analyse.yml new file mode 100644 index 0000000..4605a24 --- /dev/null +++ b/.github/workflows/build_test_analyse.yml @@ -0,0 +1,35 @@ +name: Build, Run Tests and Sonar Analysis +on: push + +jobs: + build: + name: Build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + with: + # Shallow clones should be disabled for a better relevancy of analysis + fetch-depth: 0 + - name: Set up JDK 11 + uses: actions/setup-java@v1 + with: + java-version: 11 + - name: Cache Maven packages + uses: actions/cache@v1 + with: + path: ~/.m2 + key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} + restore-keys: ${{ runner.os }}-m2 + - name: Cache SonarCloud packages + uses: actions/cache@v1 + with: + path: ~/.sonar/cache + key: ${{ runner.os }}-sonar + restore-keys: ${{ runner.os }}-sonar + - name: Build, run tests and analyse + run: mvn -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Pcoverage -Dsonar.projectKey=europeana_thumbnail-api + env: + # Needed to get some information about the pull request, if any + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + # SonarCloud access token should be generated from https://sonarcloud.io/account/security/ + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} \ No newline at end of file From 19955c4f88f94d49c4436f69a7f672ee72ee3441 Mon Sep 17 00:00:00 2001 From: SristiSingh-eu Date: Thu, 9 Nov 2023 11:01:11 +0100 Subject: [PATCH 2/8] EA-3623 add repositories in pom --- pom.xml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/pom.xml b/pom.xml index 231e18d..d9e328d 100644 --- a/pom.xml +++ b/pom.xml @@ -12,6 +12,26 @@ 0.7.2-SNAPSHOT war + + + libs-release-local + europeana-releases + https://artifactory.eanadev.org/artifactory/libs-release + + + libs-snapshots-local + europeana-snapshots + https://artifactory.eanadev.org/artifactory/libs-snapshot + + + + plugins-release + artifactory plugins-release + https://artifactory.eanadev.org/artifactory/plugins-release + + + + Thumbnail API Spring-Boot2 application for providing CHO thumbnail images From ec222b7f14a1052c167fd3f8d53da37439ac7285 Mon Sep 17 00:00:00 2001 From: SristiSingh-eu Date: Thu, 9 Nov 2023 13:00:14 +0100 Subject: [PATCH 3/8] EA-3623 add sonar host url --- pom.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/pom.xml b/pom.xml index d9e328d..85083ea 100644 --- a/pom.xml +++ b/pom.xml @@ -42,6 +42,7 @@ UTF-8 UTF-8 europeana + https://sonarcloud.io 1.10 0.3.9 From c5bda8585bdd760701751e7117d244bf1c7cdd57 Mon Sep 17 00:00:00 2001 From: srishti Date: Thu, 23 Nov 2023 16:55:29 +0100 Subject: [PATCH 4/8] EA-3623 update the project key --- .github/workflows/build_test_analyse.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_test_analyse.yml b/.github/workflows/build_test_analyse.yml index 4605a24..217aa7e 100644 --- a/.github/workflows/build_test_analyse.yml +++ b/.github/workflows/build_test_analyse.yml @@ -27,7 +27,7 @@ jobs: key: ${{ runner.os }}-sonar restore-keys: ${{ runner.os }}-sonar - name: Build, run tests and analyse - run: mvn -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Pcoverage -Dsonar.projectKey=europeana_thumbnail-api + run: mvn -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Pcoverage -Dsonar.projectKey=eu.europeana:thumbnail-api env: # Needed to get some information about the pull request, if any GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 041375789d21c058592c8db1a9c150611720bd5e Mon Sep 17 00:00:00 2001 From: srishti Date: Mon, 4 Dec 2023 16:10:52 +0100 Subject: [PATCH 5/8] EA-3623 testing --- src/main/java/eu/europeana/thumbnail/ThumbnailApplication.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/eu/europeana/thumbnail/ThumbnailApplication.java b/src/main/java/eu/europeana/thumbnail/ThumbnailApplication.java index 977d0d6..59b7fec 100644 --- a/src/main/java/eu/europeana/thumbnail/ThumbnailApplication.java +++ b/src/main/java/eu/europeana/thumbnail/ThumbnailApplication.java @@ -29,6 +29,7 @@ public static void main(String[] args) { System.getenv("CF_INSTANCE_IP")); SpringApplication.run(ThumbnailApplication.class, args); + System.out.println("testing"); } @Override From 0c5f3f33e042616618edaada3bf823417630bb7e Mon Sep 17 00:00:00 2001 From: srishti Date: Mon, 4 Dec 2023 16:19:13 +0100 Subject: [PATCH 6/8] EA-3623 remove syys out --- src/main/java/eu/europeana/thumbnail/ThumbnailApplication.java | 1 - 1 file changed, 1 deletion(-) diff --git a/src/main/java/eu/europeana/thumbnail/ThumbnailApplication.java b/src/main/java/eu/europeana/thumbnail/ThumbnailApplication.java index 59b7fec..977d0d6 100644 --- a/src/main/java/eu/europeana/thumbnail/ThumbnailApplication.java +++ b/src/main/java/eu/europeana/thumbnail/ThumbnailApplication.java @@ -29,7 +29,6 @@ public static void main(String[] args) { System.getenv("CF_INSTANCE_IP")); SpringApplication.run(ThumbnailApplication.class, args); - System.out.println("testing"); } @Override From 6932c4ddc7d7f923cdd5dbd6d6d9607d6bb20e87 Mon Sep 17 00:00:00 2001 From: Luthien-in-edhil Date: Tue, 9 Jan 2024 10:51:53 +0100 Subject: [PATCH 7/8] test for review --- .../java/eu/europeana/thumbnail/service/StoragesService.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/java/eu/europeana/thumbnail/service/StoragesService.java b/src/main/java/eu/europeana/thumbnail/service/StoragesService.java index 0231676..ec20d89 100644 --- a/src/main/java/eu/europeana/thumbnail/service/StoragesService.java +++ b/src/main/java/eu/europeana/thumbnail/service/StoragesService.java @@ -58,6 +58,7 @@ public List getStorages(String route) { private String getTopLevelName(String route) { int i = route.indexOf('.'); + System.out.println(i); if (i >= 0) { return route.substring(0, i); } From 7e5e2a5f6a3456b35ea874b3f065d12e70d2ed0d Mon Sep 17 00:00:00 2001 From: Luthien-in-edhil Date: Tue, 9 Jan 2024 11:32:32 +0100 Subject: [PATCH 8/8] removed test for review --- .../java/eu/europeana/thumbnail/service/StoragesService.java | 1 - 1 file changed, 1 deletion(-) diff --git a/src/main/java/eu/europeana/thumbnail/service/StoragesService.java b/src/main/java/eu/europeana/thumbnail/service/StoragesService.java index ec20d89..0231676 100644 --- a/src/main/java/eu/europeana/thumbnail/service/StoragesService.java +++ b/src/main/java/eu/europeana/thumbnail/service/StoragesService.java @@ -58,7 +58,6 @@ public List getStorages(String route) { private String getTopLevelName(String route) { int i = route.indexOf('.'); - System.out.println(i); if (i >= 0) { return route.substring(0, i); }