<?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>io.fusion.air</groupId> <artifactId>ms-cache-service</artifactId> <version>0.6.1</version> <packaging>jar</packaging> <name>msCacheService</name> <description>Microservice Cache Kafka Template</description>
<parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>3.1.0</version> </parent> <!– =================================================================== –> <!– Properties / Versions –> <!– =================================================================== –> <properties> <!– Java Version ================================================== –> <java.version>17</java.version>
<!– Maven ========================================================= –> <maven.compiler.target>${java.version}</maven.compiler.target> <maven.compiler.source>${java.version}</maven.compiler.source>
<maven-compiler-plugin>3.8.1</maven-compiler-plugin> <maven-dependency-plugin>3.3.0</maven-dependency-plugin> <maven-jar-plugin>3.2.2</maven-jar-plugin> <maven-surefire-plugin.version>3.0.0-M7</maven-surefire-plugin.version>
<!– Encoding ====================================================== –> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<!– Utilities ===================================================== –> <slf4j.version>2.0.7</slf4j.version> <logback.version>1.4.7</logback.version> <google.guava.version>31.1-jre</google.guava.version> <apache.httpcore>4.5.13</apache.httpcore> <apache.httpclient>5.2.1</apache.httpclient> <apache.commons.version>3.12.0</apache.commons.version> <fasterxml.version>2.15.1</fasterxml.version> <jwt.api.version>0.11.5</jwt.api.version> <google.gson.version>2.9.0</google.gson.version> <bouncycastle.version>1.46</bouncycastle.version>
<!– Java EE / Jakarta EE ========================================== –> <javax.bean.validation.version>2.0.1.Final</javax.bean.validation.version> <jakarta.bean.validation.version>3.0.0</jakarta.bean.validation.version> <jakarta.ee.version>10.0.0</jakarta.ee.version> <jakarta.servlet.version>6.0.0</jakarta.servlet.version> <jakarta.persistence.version>3.1.0</jakarta.persistence.version>
<!– Spring Libraries ============================================== –> <spring.boot.version>3.1.0</spring.boot.version> <spring.cloud.version>2022.0.2</spring.cloud.version> <spring.cloud.sleuth.version>3.1.8</spring.cloud.sleuth.version> <spring.security.version>6.1.0</spring.security.version>
<!– Spring Kafka ================================================= –> <spring.kafka.version>3.0.7</spring.kafka.version>
<!– Open API v3 - Swagger UI ===================================== –> <openapi.version>1.7.0</openapi.version>
</properties>
<!– ================================================================= –> <!– Repositories –> <!– ================================================================= –> <repositories> <repository> <id>spring-snapshots</id> <name>Spring Snapshots</name> <url>https://repo.spring.io/snapshot</url> <snapshots> <enabled>true</enabled> </snapshots> </repository> <repository> <id>spring-milestones</id> <name>Spring Milestones</name> <url>https://repo.spring.io/milestone</url>
</repository> <repository> <id>public</id> <url>http://maven.nuxeo.org/nexus/content/repositories/public/</url> </repository>
</repositories>
<dependencies>
<!– ================================================================= –> <!– Jakarta EE Frameworks (Required from Java 17 onwards) –> <!– ================================================================= –> <!– https://mvnrepository.com/artifact/jakarta.platform/jakarta.jakartaee-api –> <dependency> <groupId>jakarta.platform</groupId> <artifactId>jakarta.jakartaee-api</artifactId> <version>${jakarta.ee.version}</version> <scope>provided</scope> </dependency>
<dependency> <groupId>jakarta.servlet</groupId> <artifactId>jakarta.servlet-api</artifactId> <version>${jakarta.servlet.version}</version> </dependency>
<dependency> <groupId>jakarta.persistence</groupId> <artifactId>jakarta.persistence-api</artifactId> <version>${jakarta.persistence.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.hibernate.validator/hibernate-validator –> <dependency> <groupId>org.hibernate.validator</groupId> <artifactId>hibernate-validator</artifactId> <version>8.0.0.Final</version> </dependency>
<dependency> <groupId>javax.xml.bind</groupId> <artifactId>jaxb-api</artifactId> <version>2.3.1</version> </dependency>
<!– ================================================================= –> <!– Log Framework –> <!– ================================================================= –> <dependency> <groupId>org.slf4j</groupId> <artifactId>slf4j-api</artifactId> <version>${slf4j.version}</version> </dependency> <dependency> <groupId>ch.qos.logback</groupId> <artifactId>logback-classic</artifactId> <version>${logback.version}</version> </dependency>
<!– ================================================================= –> <!– Utility Libraries –> <!– ================================================================= –> <!– https://mvnrepository.com/artifact/com.google.guava/guava –> <dependency> <groupId>com.google.guava</groupId> <artifactId>guava</artifactId> <version>${google.guava.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.apache.httpcomponents.client5/httpclient5 –> <dependency> <groupId>org.apache.httpcomponents.client5</groupId> <artifactId>httpclient5</artifactId> <version>${apache.httpclient}</version> </dependency>
<!– Used for StringUtils helper –> <dependency> <groupId>org.apache.commons</groupId> <artifactId>commons-lang3</artifactId> <version>${apache.commons.version}</version> </dependency>
<dependency> <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-core</artifactId> <version>${fasterxml.version}</version> </dependency> <!– https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-databind –> <dependency> <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-databind</artifactId> <version>${fasterxml.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/com.fasterxml.jackson.datatype/jackson-datatype-jsr310 –> <dependency> <groupId>com.fasterxml.jackson.datatype</groupId> <artifactId>jackson-datatype-jsr310</artifactId> <version>${fasterxml.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/com.fasterxml.jackson.datatype/jackson-datatype-jdk8 –> <dependency> <groupId>com.fasterxml.jackson.datatype</groupId> <artifactId>jackson-datatype-jdk8</artifactId> <version>${fasterxml.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/com.fasterxml.jackson.jaxrs/jackson-jaxrs-json-provider –> <dependency> <groupId>com.fasterxml.jackson.jaxrs</groupId> <artifactId>jackson-jaxrs-json-provider</artifactId> <version>${fasterxml.version}</version> </dependency>
<!– ================================================================= –> <!– Spring Testing Framework –> <!– ================================================================= –>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-test –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-test</artifactId> <version>${spring.boot.version}</version> <scope>test</scope> <!– Exclude JUnit as Spring Boot Starter Test uses JUnit 4 –> <exclusions> <exclusion> <groupId>junit</groupId> <artifactId>junit</artifactId> </exclusion> </exclusions> </dependency>
<!– ================================================================= –> <!– Spring Framework –> <!– ================================================================= –>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-parent –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>${spring.boot.version}</version> <type>pom</type> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-validation –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-validation</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-web –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId> <version>${spring.boot.version}</version> </dependency> <!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-web-services –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web-services</artifactId> <version>${spring.boot.version}</version> </dependency> <!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-websocket –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-websocket</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-webflux –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-webflux</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-actuator –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-actuator</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/io.micrometer/micrometer-tracing –> <dependency> <groupId>io.micrometer</groupId> <artifactId>micrometer-tracing</artifactId> <version>1.1.1</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-aop –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-aop</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– ================================================================= –> <!– Spring Apache Kafka –> <!– ================================================================= –>
<!– https://mvnrepository.com/artifact/org.springframework.kafka/spring-kafka –> <dependency> <groupId>org.springframework.kafka</groupId> <artifactId>spring-kafka</artifactId> <version>${spring.kafka.version}</version> </dependency>
<!– ================================================================= –> <!– Spring Cache - Redis / H2 DB / JPA –> <!– ================================================================= –>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-cache –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-cache</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-data-redis –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-redis</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-data-jpa –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-jpa</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.hibernate.orm/hibernate-core –> <dependency> <groupId>org.hibernate.orm</groupId> <artifactId>hibernate-core</artifactId> <version>6.2.3.Final</version> </dependency>
<dependency> <groupId>org.postgresql</groupId> <artifactId>postgresql</artifactId> <version>42.6.0</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.data/spring-data-commons –> <dependency> <groupId>org.springframework.data</groupId> <artifactId>spring-data-commons</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– ================================================================= –> <!– Following Libraries NOT REQUIRED for Production –> <!– For Testing Cache : Embedded Redis / H2 Database –> <!– ================================================================= –>
<!– https://mvnrepository.com/artifact/it.ozimov/embedded-redis –> <dependency> <groupId>it.ozimov</groupId> <artifactId>embedded-redis</artifactId> <version>0.7.3</version> <exclusions> <exclusion> <groupId>org.slf4j</groupId> <artifactId>slf4j-simple</artifactId> </exclusion> </exclusions> <scope>test</scope> </dependency>
<!– https://mvnrepository.com/artifact/com.h2database/h2 –> <dependency> <groupId>com.h2database</groupId> <artifactId>h2</artifactId> <version>2.1.214</version> <scope>runtime</scope> </dependency>
<!– ================================================================= –> <!– Security - Spring Security / JWT –> <!– ================================================================= –>
<!– https://mvnrepository.com/artifact/io.jsonwebtoken/jjwt-api –> <dependency> <groupId>io.jsonwebtoken</groupId> <artifactId>jjwt-api</artifactId> <version>${jwt.api.version}</version> </dependency> <!– https://mvnrepository.com/artifact/io.jsonwebtoken/jjwt-impl –> <dependency> <groupId>io.jsonwebtoken</groupId> <artifactId>jjwt-impl</artifactId> <version>${jwt.api.version}</version> <scope>runtime</scope> </dependency> <dependency> <groupId>io.jsonwebtoken</groupId> <artifactId>jjwt-jackson</artifactId> <version>${jwt.api.version}</version> <scope>runtime</scope> </dependency>
<!– https://mvnrepository.com/artifact/org.bouncycastle/bcprov-jdk16 –> <dependency> <groupId>org.bouncycastle</groupId> <artifactId>bcprov-jdk16</artifactId> <version>${bouncycastle.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.security/spring-security-core –> <dependency> <groupId>org.springframework.security</groupId> <artifactId>spring-security-core</artifactId> <version>${spring.security.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springframework.security/spring-security-web –> <dependency> <groupId>org.springframework.security</groupId> <artifactId>spring-security-web</artifactId> <version>${spring.security.version}</version> </dependency>
<!– This enables a default Auth Page for the Spring Boot App. Default loginId: user Password: will be printed in the console. –> <!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-security –>
<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-security</artifactId> <version>${spring.boot.version}</version> </dependency> <!– –> <!– https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-tomcat –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-tomcat</artifactId> <version>${spring.boot.version}</version> </dependency>
<!– ================================================================= –> <!– API Docs - Open API v3.0 (Swagger 3) –> <!– ================================================================= –>
<dependency> <groupId>org.springdoc</groupId> <artifactId>springdoc-openapi-starter-webmvc-ui</artifactId> <version>2.1.0</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springdoc/springdoc-openapi-webflux-ui –> <dependency> <groupId>org.springdoc</groupId> <artifactId>springdoc-openapi-webflux-ui</artifactId> <version>${openapi.version}</version> </dependency>
<!– https://mvnrepository.com/artifact/org.springdoc/springdoc-openapi-data-rest –> <dependency> <groupId>org.springdoc</groupId> <artifactId>springdoc-openapi-data-rest</artifactId> <version>${openapi.version}</version> </dependency>
<!– End of Dependency Definitions –> </dependencies>
<dependencyManagement> <dependencies> <!– https://mvnrepository.com/artifact/org.springframework.cloud/spring-cloud-dependencies –> <dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-dependencies</artifactId> <version>${spring.cloud.version}</version> <type>pom</type> <scope>import</scope> </dependency> </dependencies> </dependencyManagement>
<build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>${maven-compiler-plugin}</version> <configuration> <source>${java.version}</source> <target>${java.version}</target> </configuration> </plugin> <!– SpringBoot Jar (Single Jar) –> <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <version>${spring.boot.version}</version> <executions> <execution> <goals> <goal>repackage</goal> </goals> <configuration> <classifier>spring-boot</classifier> <mainClass>io.fusion.air.microservice.ServiceBootStrap</mainClass> <excludeGroupIds>test.fusion.air</excludeGroupIds> </configuration> </execution> </executions> </plugin> <!– Maven Jar Pluggin with dependencies in libs folder –> <!– https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-dependency-plugin –> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-dependency-plugin</artifactId> <version>${maven-dependency-plugin}</version> <executions> <execution> <id>copy-dependencies</id> <phase>prepare-package</phase> <goals> <goal>copy-dependencies</goal> </goals> <configuration> <outputDirectory> ${project.build.directory}/libs </outputDirectory> </configuration> </execution> </executions> </plugin> <!– https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-jar-plugin –> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId> <version>${maven-jar-plugin}</version> <configuration> <archive> <manifest> <addClasspath>true</addClasspath> <classpathPrefix>libs/</classpathPrefix> <mainClass>io.fusion.air.microservice.ServiceBootStrap</mainClass> </manifest> <manifestEntries> <Add-Exports>java.management/com.sun.management</Add-Exports> </manifestEntries> </archive> </configuration> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <version>${maven-surefire-plugin.version}</version> </plugin> </plugins> </build>
</project>