<?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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>

	<groupId>com.github.mvallim</groupId>
	<artifactId>spring-schema-registry-parent</artifactId>
	<version>0.0.4</version>
	<packaging>pom</packaging>

	<properties>
		<java.version>1.8</java.version>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
		<schema.registry.version>5.2.1</schema.registry.version>
		<spring.boot.version>2.1.2.RELEASE</spring.boot.version>
		<avro.version>1.8.2</avro.version>
		<commons-cli>1.4</commons-cli>
	</properties>

	<scm>
		<url>scm:git:git@github.com:mvallim/spring-schema-registry</url>
		<connection>scm:git:git@github.com:mvallim/spring-schema-registry</connection>
		<developerConnection>scm:git:git@github.com:mvallim/spring-schema-registry</developerConnection>
		<tag>spring-schema-registry-parent-0.0.4</tag>
	</scm>

	<name>spring-schema-registry-parent</name>
	<description>The purpose of this module is to solve the problem of multiple keystores using Spring Boot + Kafka + Schema Registry + SSL</description>
	<url>https://github.com/mvallim/spring-schema-registry</url>
	<inceptionYear>2019</inceptionYear>

	<organization>
		<name>com.github.mvallim</name>
		<url>https://github.com/mvallim</url>
	</organization>

	<developers>
		<developer>
			<name>Marcos Tischer Vallim</name>
			<email>tischer@gmail.com</email>
			<timezone>-3</timezone>
		</developer>
	</developers>

	<licenses>
		<license>
			<name>Apache 2</name>
			<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
			<distribution>repo</distribution>
			<comments>A business-friendly OSS license</comments>
		</license>
	</licenses>

	<repositories>
		<repository>
			<id>confluent</id>
			<url>https://packages.confluent.io/maven/</url>
		</repository>
	</repositories>

	<parent>
		<groupId>org.springframework.boot</groupId>
		<artifactId>spring-boot-starter-parent</artifactId>
		<version>2.1.2.RELEASE</version>
		<relativePath />
	</parent>

	<dependencyManagement>
		<dependencies>
			<!-- Spring Boot -->
			<dependency>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-starter</artifactId>
				<version>${spring.boot.version}</version>
			</dependency>
			<dependency>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-configuration-processor</artifactId>
				<version>${spring.boot.version}</version>
			</dependency>

			<!-- Apache Avro -->
			<dependency>
				<groupId>org.apache.avro</groupId>
				<artifactId>avro</artifactId>
				<version>${avro.version}</version>
			</dependency>

			<!-- Apache Commons -->
			<dependency>
				<groupId>commons-cli</groupId>
				<artifactId>commons-cli</artifactId>
				<version>${commons-cli}</version>
			</dependency>

			<!-- Spring Kafka -->
			<dependency>
				<groupId>org.springframework.kafka</groupId>
				<artifactId>spring-kafka</artifactId>
				<version>${spring.boot.version}</version>
			</dependency>

			<!-- Confluent -->
			<dependency>
				<groupId>io.confluent</groupId>
				<artifactId>rest-utils</artifactId>
				<version>${schema.registry.version}</version>
			</dependency>
			<dependency>
				<groupId>io.confluent</groupId>
				<artifactId>kafka-avro-serializer</artifactId>
				<version>${schema.registry.version}</version>
			</dependency>
			<dependency>
				<groupId>io.confluent</groupId>
				<artifactId>kafka-schema-registry</artifactId>
				<version>${schema.registry.version}</version>
			</dependency>

			<!-- Test -->
			<dependency>
				<groupId>junit</groupId>
				<artifactId>junit</artifactId>
				<version>4.12</version>
				<scope>test</scope>
			</dependency>
			<dependency>
				<groupId>org.hamcrest</groupId>
				<artifactId>hamcrest-library</artifactId>
				<version>1.3</version>
				<scope>test</scope>
			</dependency>

			<dependency>
				<groupId>com.github.mvallim</groupId>
				<artifactId>spring-schema-registry</artifactId>
				<version>${project.version}</version>
			</dependency>

			<dependency>
				<groupId>com.github.mvallim</groupId>
				<artifactId>spring-schema-registry-test</artifactId>
				<version>${project.version}</version>
			</dependency>

		</dependencies>
	</dependencyManagement>

	<build>

		<resources>
			<resource>
				<directory>${project.basedir}</directory>
				<includes>
					<include>NOTICE*</include>
					<include>LICENSE*</include>
				</includes>
			</resource>
			<resource>
				<directory>${project.basedir}/src/main/resources</directory>
				<includes>
					<include>**/*</include>
				</includes>
			</resource>
		</resources>

		<pluginManagement>
			<plugins>
				<plugin>
					<groupId>org.apache.avro</groupId>
					<artifactId>avro-maven-plugin</artifactId>
					<version>${avro.version}</version>
				</plugin>
			</plugins>
		</pluginManagement>

		<plugins>

			<plugin>
				<groupId>org.jacoco</groupId>
				<artifactId>jacoco-maven-plugin</artifactId>
				<version>0.8.4</version>
				<executions>
					<execution>
						<id>prepare-agent</id>
						<goals>
							<goal>prepare-agent</goal>
						</goals>
					</execution>
				</executions>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-clean-plugin</artifactId>
				<inherited>true</inherited>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<configuration>
					<source>${java.version}</source>
					<target>${java.version}</target>
					<encoding>${project.build.sourceEncoding}</encoding>
					<debug>true</debug>
					<optimize>true</optimize>
					<showDeprecation>true</showDeprecation>
					<showWarnings>true</showWarnings>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-resources-plugin</artifactId>
				<configuration>
					<downloadSources>true</downloadSources>
					<downloadJavadocs>true</downloadJavadocs>
					<encoding>${project.build.sourceEncoding}</encoding>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-source-plugin</artifactId>
				<inherited>true</inherited>
				<configuration>
					<encoding>${project.build.sourceEncoding}</encoding>
				</configuration>
				<executions>
					<execution>
						<id>attach-source</id>
						<goals>
							<goal>jar</goal>
						</goals>
					</execution>
				</executions>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-install-plugin</artifactId>
				<inherited>true</inherited>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-deploy-plugin</artifactId>
				<inherited>true</inherited>
				<configuration>
					<updateReleaseInfo>true</updateReleaseInfo>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-release-plugin</artifactId>
				<configuration>
					<localCheckout>true</localCheckout>
					<pushChanges>false</pushChanges>
					<mavenExecutorId>forked-path</mavenExecutorId>
					<arguments>-Dgpg.passphrase=${gpg.passphrase}</arguments>
				</configuration>
			</plugin>

		</plugins>
	</build>

	<profiles>
		<profile>
			<id>release-sign-artifacts</id>
			<activation>
				<property>
					<name>performRelease</name>
					<value>true</value>
				</property>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-gpg-plugin</artifactId>
						<version>1.6</version>
						<executions>
							<execution>
								<id>sign-artifacts</id>
								<phase>verify</phase>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<id>nexus-release</id>
			<distributionManagement>
				<snapshotRepository>
					<id>nexus-release</id>
					<layout>default</layout>
					<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
				</snapshotRepository>
				<repository>
					<id>nexus-release</id>
					<layout>default</layout>
					<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
				</repository>
			</distributionManagement>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-source-plugin</artifactId>
						<version>2.2.1</version>
						<executions>
							<execution>
								<phase>package</phase>
								<goals>
									<goal>jar-no-fork</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-javadoc-plugin</artifactId>
						<version>2.9.1</version>
						<executions>
							<execution>
								<phase>package</phase>
								<goals>
									<goal>jar</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-gpg-plugin</artifactId>
						<version>1.6</version>
						<executions>
							<execution>
								<id>sign-artifacts</id>
								<phase>verify</phase>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>

	<modules>
		<module>spring-schema-registry</module>
		<module>spring-schema-registry-test</module>
		<module>spring-schema-registry-embedded</module>
	</modules>

</project>
