Skip to content

Commit

Permalink
Merge branch 'release/v10'
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Apr 14, 2023
2 parents c1227e7 + 90ee6f8 commit 773fae4
Show file tree
Hide file tree
Showing 176 changed files with 24,088 additions and 3,352 deletions.
119 changes: 54 additions & 65 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,70 +3,59 @@ name: CI
on: push

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
cache: maven
- name: Cache SonarCloud packages
uses: actions/cache@v3
with:
path: ~/.sonar/cache
key: ${{ runner.os }}-sonar
restore-keys: ${{ runner.os }}-sonar
- name: Build - Clean Jacoco Verify
run: >
mvn --batch-mode --update-snapshots
clean
org.jacoco:jacoco-maven-plugin:prepare-agent
verify
org.jacoco:jacoco-maven-plugin:report
- name: Sonar Analyze
run: >
mvn --batch-mode
-Dsonar.host.url=https://sonarcloud.io
-Dsonar.organization=europeana
-Dsonar.projectKey=europeana_metis-framework
sonar:sonar
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

deploy_libraries:
needs: build
if: ${{ github.ref == 'refs/heads/develop' }}
runs-on: ubuntu-latest
ci:
uses: europeana/metis-actions/.github/workflows/ci.yml@main
with:
sonar_organization: europeana
sonar_project_key: europeana_metis-framework
secrets:
SONAR_TOKEN: ${{ secrets.METIS_SONAR_TOKEN }}

steps:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
cache: maven
- name: Prepare Settings Deploy
run: >
mkdir -p ~/.m2 &&
echo "<settings><servers><server><id>${REPOSITORY_ID}</id><username>${REPOSITORY_USERNAME}</username><password>${REPOSITORY_PASSWORD}</password></server></servers></settings>" > ~/.m2/settings.xml
env:
REPOSITORY_ID: artifactory.eanadev.org
REPOSITORY_USERNAME: ${{ secrets.REPOSITORY_USERNAME }}
REPOSITORY_PASSWORD: ${{ secrets.REPOSITORY_PASSWORD }}
- name: Deploy
run: >
mvn --batch-mode
-Dmaven.test.skip=true
-Dmaven.install.skip=true
deploy
deploy-artifacts:
needs: ci
uses: europeana/metis-actions/.github/workflows/deploy-artifacts.yml@main
secrets:
ARTIFACTORY_USERNAME: ${{ secrets.ARTIFACTORY_USERNAME }}
ARTIFACTORY_PASSWORD: ${{ secrets.ARTIFACTORY_PASSWORD }}

docker-build_metis-authentication:
needs: ci
uses: europeana/metis-actions/.github/workflows/docker-build-push.yml@main
with:
docker-organization: europeana
docker-image-name: metis-authentication
project-path: metis-authentication/metis-authentication-rest/
secrets:
DOCKER_HUB_USERNAME: ${{ secrets.DOCKER_HUB_USERNAME }}
DOCKER_HUB_PASSWORD: ${{ secrets.DOCKER_HUB_PASSWORD }}
docker-build_metis-core:
needs: ci
uses: europeana/metis-actions/.github/workflows/docker-build-push.yml@main
with:
docker-organization: europeana
docker-image-name: metis-core
project-path: metis-core/metis-core-rest/
secrets:
DOCKER_HUB_USERNAME: ${{ secrets.DOCKER_HUB_USERNAME }}
DOCKER_HUB_PASSWORD: ${{ secrets.DOCKER_HUB_PASSWORD }}
docker-build_metis-dereference:
needs: ci
uses: europeana/metis-actions/.github/workflows/docker-build-push.yml@main
with:
docker-organization: europeana
docker-image-name: metis-dereference
project-path: metis-dereference/metis-dereference-rest/
secrets:
DOCKER_HUB_USERNAME: ${{ secrets.DOCKER_HUB_USERNAME }}
DOCKER_HUB_PASSWORD: ${{ secrets.DOCKER_HUB_PASSWORD }}
docker-build_metis-repository:
needs: ci
uses: europeana/metis-actions/.github/workflows/docker-build-push.yml@main
with:
docker-organization: europeana
docker-image-name: metis-repository
project-path: metis-repository/metis-repository-rest/
secrets:
DOCKER_HUB_USERNAME: ${{ secrets.DOCKER_HUB_USERNAME }}
DOCKER_HUB_PASSWORD: ${{ secrets.DOCKER_HUB_PASSWORD }}
26 changes: 26 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: RELEASE

on:
workflow_dispatch:
inputs:
release-version:
description: 'The version of the intended release, should be just a number'
required: true
new-snapshot-version:
description: 'The version of the intended new snapshot'
required: true
commit-hash-branch:
description: 'The commit hash or branch to use as a base for the merge and release(default: develop)'
required: false
default: develop

jobs:
ci-release:
uses: europeana/metis-actions/.github/workflows/release.yml@main
with:
release-version: ${{ github.event.inputs.release-version }}
commit-hash-branch: ${{ github.event.inputs.commit-hash-branch }}
new-snapshot-version: ${{ github.event.inputs.new-snapshot-version }}
target-merge-branch: master
secrets:
METIS_PERSONAL_ACCESS_TOKEN: ${{ secrets.METIS_PERSONAL_ACCESS_TOKEN }}
1 change: 1 addition & 0 deletions .run/metis-authentication(.properties).run.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
<env name="server.servlet.context-path" value="/metis-authentication"/>
<env name="spring.config.location"
value="file:///data/metis-configuration/metis-framework/metis-authentication/metis-authentication-rest/k8s/overlays/local/components/properties/application.properties"/>
<env name="logging.config" value="file:///data/metis-configuration/k8s/common-components/log4j2-xml/log4j2.xml"/>
</envs>
<module name="metis-authentication-rest"/>
<option name="SPRING_BOOT_MAIN_CLASS" value="eu.europeana.metis.authentication.rest.Application"/>
Expand Down
1 change: 1 addition & 0 deletions .run/metis-core (.properties).run.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<env name="server.servlet.context-path" value="/metis-core"/>
<env name="spring.config.location"
value="file:///data/metis-configuration/metis-framework/metis-core/metis-core-rest/k8s/overlays/local/components/properties/application.properties"/>
<env name="logging.config" value="file:///data/metis-configuration/k8s/common-components/log4j2-xml/log4j2.xml"/>
</envs>
<module name="metis-core-rest"/>
<option name="SPRING_BOOT_MAIN_CLASS" value="eu.europeana.metis.core.rest.Application"/>
Expand Down
1 change: 1 addition & 0 deletions .run/metis-dereference(.properties).run.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
<env name="server.servlet.context-path" value="/metis-dereference"/>
<env name="spring.config.location"
value="file:///data/metis-configuration/metis-framework/metis-dereference/metis-dereference-rest/k8s/overlays/local/components/properties/application.properties"/>
<env name="logging.config" value="file:///data/metis-configuration/k8s/common-components/log4j2-xml/log4j2.xml"/>
</envs>
<module name="metis-dereference-rest"/>
<option name="SPRING_BOOT_MAIN_CLASS" value="eu.europeana.metis.dereference.rest.Application"/>
Expand Down
31 changes: 31 additions & 0 deletions .run/metis-repository (.properties).run.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="metis-repository (.properties)" type="SpringBootApplicationConfigurationType"
factoryName="Spring Boot">
<envs>
<env name="logging.config" value="file:///data/metis-configuration/k8s/common-components/log4j2-xml/log4j2.xml"/>
<env name="server.servlet.context-path" value="/metis-repository"/>
<env name="spring.config.location"
value="file:///data/metis-configuration/metis-framework/metis-repository/metis-repository-rest/k8s/overlays/local/components/properties/application.properties"/>
</envs>
<module name="metis-repository-rest"/>
<option name="SPRING_BOOT_MAIN_CLASS" value="eu.europeana.metis.repository.rest.Application"/>
<extension name="net.ashald.envfile">
<option name="IS_ENABLED" value="false"/>
<option name="IS_SUBST" value="false"/>
<option name="IS_PATH_MACRO_SUPPORTED" value="false"/>
<option name="IS_IGNORE_MISSING_FILES" value="false"/>
<option name="IS_ENABLE_EXPERIMENTAL_INTEGRATIONS" value="false"/>
<ENTRIES>
<ENTRY IS_ENABLED="true" PARSER="runconfig" IS_EXECUTABLE="false"/>
</ENTRIES>
</extension>
<extension name="software.aws.toolkits.jetbrains.core.execution.JavaAwsConnectionExtension">
<option name="credential"/>
<option name="region"/>
<option name="useCurrentConnection" value="false"/>
</extension>
<method v="2">
<option name="Make" enabled="true"/>
</method>
</configuration>
</component>
2 changes: 1 addition & 1 deletion metis-authentication/metis-authentication-common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<artifactId>metis-authentication</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-authentication-common</artifactId>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<artifactId>metis-authentication</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-authentication-rest-client</artifactId>

Expand Down
2 changes: 1 addition & 1 deletion metis-authentication/metis-authentication-rest/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<artifactId>metis-authentication</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-authentication-rest</artifactId>

Expand Down
2 changes: 1 addition & 1 deletion metis-authentication/metis-authentication-service/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<artifactId>metis-authentication</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-authentication-service</artifactId>

Expand Down
2 changes: 1 addition & 1 deletion metis-authentication/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<artifactId>metis-framework</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-authentication</artifactId>
<packaging>pom</packaging>
Expand Down
12 changes: 12 additions & 0 deletions metis-common/metis-common-base/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>eu.europeana.metis</groupId>
<artifactId>metis-common</artifactId>
<version>10</version>
</parent>
<artifactId>metis-common-base</artifactId>

<name>metis-common-base</name>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package eu.europeana.metis.common;

public interface DatabaseProperties {

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package eu.europeana.metis.common;

public interface SettingsHolder {
DatabaseProperties getDatabaseProperties();
}
7 changes: 6 additions & 1 deletion metis-common/metis-common-mongo/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,16 @@
<parent>
<artifactId>metis-common</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-common-mongo</artifactId>

<dependencies>
<dependency>
<groupId>eu.europeana.metis</groupId>
<artifactId>metis-common-base</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>eu.europeana.metis</groupId>
<artifactId>metis-common-utils</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import com.mongodb.MongoCredential;
import com.mongodb.ReadPreference;
import com.mongodb.ServerAddress;
import eu.europeana.metis.common.DatabaseProperties;
import eu.europeana.metis.network.InetAddressUtil;
import java.net.InetSocketAddress;
import java.util.ArrayList;
Expand All @@ -18,7 +19,7 @@
*
* @param <E> The type of exception thrown when the properties are not valid.
*/
public class MongoProperties<E extends Exception> {
public class MongoProperties<E extends Exception> implements DatabaseProperties {

// Exception creator
private final Function<String, E> exceptionCreator;
Expand Down
2 changes: 1 addition & 1 deletion metis-common/metis-common-network/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<artifactId>metis-common</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-common-network</artifactId>

Expand Down
7 changes: 6 additions & 1 deletion metis-common/metis-common-solr/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,16 @@
<parent>
<artifactId>metis-common</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-common-solr</artifactId>

<dependencies>
<dependency>
<groupId>eu.europeana.metis</groupId>
<artifactId>metis-common-base</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>eu.europeana.metis</groupId>
<artifactId>metis-common-network</artifactId>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package eu.europeana.metis.solr.connection;

import eu.europeana.metis.common.DatabaseProperties;
import eu.europeana.metis.network.InetAddressUtil;
import java.net.InetSocketAddress;
import java.net.URI;
Expand All @@ -14,7 +15,7 @@
*
* @param <E> The type of exception thrown when the properties are not valid.
*/
public class SolrProperties<E extends Exception> {
public class SolrProperties<E extends Exception> implements DatabaseProperties {

// Default settings
private static final int DEFAULT_ZOOKEEPER_TIMEOUT_IN_SECONDS = 30;
Expand Down
2 changes: 1 addition & 1 deletion metis-common/metis-common-utils/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<artifactId>metis-common</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-common-utils</artifactId>

Expand Down
2 changes: 1 addition & 1 deletion metis-common/metis-common-zoho/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<artifactId>metis-common</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>

<artifactId>metis-common-zoho</artifactId>
Expand Down
3 changes: 2 additions & 1 deletion metis-common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,13 @@
<parent>
<artifactId>metis-framework</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-common</artifactId>
<packaging>pom</packaging>

<modules>
<module>metis-common-base</module>
<module>metis-common-utils</module>
<module>metis-common-mongo</module>
<module>metis-common-solr</module>
Expand Down
2 changes: 1 addition & 1 deletion metis-core/metis-core-common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<artifactId>metis-core</artifactId>
<groupId>eu.europeana.metis</groupId>
<version>9</version>
<version>10</version>
</parent>
<artifactId>metis-core-common</artifactId>
<dependencies>
Expand Down
Loading

0 comments on commit 773fae4

Please sign in to comment.