Skip to content

Commit

Permalink
YAS-0001 maven version management
Browse files Browse the repository at this point in the history
  • Loading branch information
zuize47 committed Apr 8, 2024
1 parent f033506 commit c57e628
Show file tree
Hide file tree
Showing 5 changed files with 123 additions and 95 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/cart-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
- name: Run Maven Build Command
run: mvn clean install -DskipTests
- name: Run Maven Test
run: mvn test -f cart
run: mvn test -pl cart -am
- name: Unit Test Results
uses: dorny/test-reporter@v1
if: success() || failure()
Expand All @@ -39,7 +39,7 @@ jobs:
if: ${{ github.event.pull_request.head.repo.full_name == github.repository || github.ref == 'refs/heads/main' }}
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: mvn org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -f cart
run: mvn org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -pl cart -am
- name: Log in to the Container registry
if: ${{ github.ref == 'refs/heads/main' }}
uses: docker/login-action@v2
Expand Down
23 changes: 6 additions & 17 deletions backoffice-bff/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,17 @@
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>3.2.0</version>
<relativePath/> <!-- lookup parent from repository -->
<groupId>com.yas</groupId>
<artifactId>yas</artifactId>
<version>${revision}</version>
<relativePath>../pom.xml</relativePath>
</parent>
<groupId>com.yas</groupId>
<artifactId>backoffice-bff</artifactId>
<version>0.0.1-SNAPSHOT</version>
<version>1.0-SNAPSHOT</version>
<name>backoffice-bff</name>
<description>Backend for backoffice</description>
<properties>
<java.version>21</java.version>
<spring-cloud.version>2023.0.0</spring-cloud.version>
<sonar.organization>nashtech-garage</sonar.organization>
<sonar.host.url>https://sonarcloud.io</sonar.host.url>

<sonar.projectKey>nashtech-garage_yas-backoffice-bff</sonar.projectKey>
<logstash-logback-encoder.version>7.4</logstash-logback-encoder.version>
<opentelemetry-logback.vesion>1.30.0-alpha</opentelemetry-logback.vesion>
Expand Down Expand Up @@ -74,13 +70,6 @@
</dependencies>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-dependencies</artifactId>
<version>${spring-cloud.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>net.logstash.logback</groupId>
<artifactId>logstash-logback-encoder</artifactId>
Expand Down
32 changes: 5 additions & 27 deletions cart/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,17 @@
<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>3.2.0</version>
<relativePath /> <!-- lookup parent from repository -->
<groupId>com.yas</groupId>
<artifactId>yas</artifactId>
<version>1.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<groupId>com.yas</groupId>
<artifactId>cart</artifactId>
<version>0.0.1-SNAPSHOT</version>
<version>1.0-SNAPSHOT</version>
<name>cart</name>
<description>YAS Cart service</description>

<properties>
<java.version>21</java.version>
<springdoc-openapi-starter-webmvc-ui.version>2.0.2</springdoc-openapi-starter-webmvc-ui.version>
<org.lombok.version>1.18.30</org.lombok.version>
<org.mapstruct.version>1.4.1.Final</org.mapstruct.version>
<spring-cloud.version>2022.0.3</spring-cloud.version>
Expand Down Expand Up @@ -155,25 +152,6 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<annotationProcessorPaths>
<path>
<groupId>org.mapstruct</groupId>
<artifactId>mapstruct-processor</artifactId>
<version>${org.mapstruct.version}</version>
</path>
<path>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>${lombok.version}</version>
</path>
<path>
<groupId>org.projectlombok</groupId>
<artifactId>lombok-mapstruct-binding</artifactId>
<version>0.2.0</version>
</path>
</annotationProcessorPaths>
</configuration>
</plugin>
</plugins>
</build>
Expand Down
128 changes: 103 additions & 25 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,28 +1,106 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.yas</groupId>
<artifactId>yas</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>pom</packaging>
<name>yas</name>
<modules>
<module>backoffice-bff</module>
<module>cart</module>
<module>customer</module>
<module>inventory</module>
<module>location</module>
<module>media</module>
<module>order</module>
<module>payment</module>
<module>payment-paypal</module>
<module>product</module>
<module>promotion</module>
<module>rating</module>
<module>search</module>
<module>storefront-bff</module>
<module>tax</module>
<module>saga</module>
</modules>
<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>3.2.4</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<groupId>com.yas</groupId>
<artifactId>yas</artifactId>
<version>${revision}</version>
<packaging>pom</packaging>
<name>yas</name>

<modules>
<module>backoffice-bff</module>
<module>cart</module>
<module>customer</module>
<module>inventory</module>
<module>location</module>
<module>media</module>
<module>order</module>
<module>payment</module>
<module>payment-paypal</module>
<module>product</module>
<module>promotion</module>
<module>rating</module>
<module>search</module>
<module>storefront-bff</module>
<module>tax</module>
<module>saga</module>
</modules>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<java.version>21</java.version>
<maven.compiler.source>21</maven.compiler.source>
<maven.compiler.target>21</maven.compiler.target>
<yas.version>1.0-SNAPSHOT</yas.version>
<revision>1.0-SNAPSHOT</revision>

<sonar.organization>nashtech-garage</sonar.organization>
<sonar.host.url>https://sonarcloud.io</sonar.host.url>

<springdoc-openapi-starter-webmvc-ui.version>2.0.2</springdoc-openapi-starter-webmvc-ui.version>
<org.mapstruct.version>1.4.1.Final</org.mapstruct.version>
<spring-cloud.version>2023.0.0</spring-cloud.version>

<eventuate-platform.version>2023.0.RELEASE</eventuate-platform.version>

</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-dependencies</artifactId>
<version>${spring-cloud.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>io.eventuate.platform</groupId>
<artifactId>eventuate-platform-dependencies</artifactId>
<version>${eventuate-platform.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<annotationProcessorPaths>
<path>
<groupId>org.mapstruct</groupId>
<artifactId>mapstruct-processor</artifactId>
<version>${org.mapstruct.version}</version>
</path>
<path>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>${lombok.version}</version>
</path>
<path>
<groupId>org.projectlombok</groupId>
<artifactId>lombok-mapstruct-binding</artifactId>
<version>0.2.0</version>
</path>
</annotationProcessorPaths>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

</project>
31 changes: 7 additions & 24 deletions saga/pom.xml
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>
<groupId>com.yas</groupId>
<parent>
<groupId>com.yas</groupId>
<artifactId>yas</artifactId>
<version>${revision}</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>saga</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>saga</name>
<description>Saga model common yas project</description>
<properties>
<java.version>21</java.version>
<maven.compiler.source>21</maven.compiler.source>
<maven.compiler.target>21</maven.compiler.target>
<org.lombok.version>1.18.30</org.lombok.version>
<org.mapstruct.version>1.4.1.Final</org.mapstruct.version>
<eventuate-platform.version>2023.0.RELEASE</eventuate-platform.version>
Expand Down Expand Up @@ -55,26 +58,6 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.11.0</version>
<configuration>
<annotationProcessorPaths>
<path>
<groupId>org.mapstruct</groupId>
<artifactId>mapstruct-processor</artifactId>
<version>${org.mapstruct.version}</version>
</path>
<path>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>${org.lombok.version}</version>
</path>
<path>
<groupId>org.projectlombok</groupId>
<artifactId>lombok-mapstruct-binding</artifactId>
<version>0.2.0</version>
</path>
</annotationProcessorPaths>
</configuration>
</plugin>
</plugins>
</build>
Expand Down

0 comments on commit c57e628

Please sign in to comment.