<?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.dtflys.forest</groupId>
	<artifactId>forest</artifactId>
		<version>1.5.28</version>
	<packaging>pom</packaging>
	<name>forest</name>
	<description>A easy HTTP client framework for Java</description>
	<url>https://github.com/dromara/forest</url>

	<licenses>
		<license>
			<name>The MIT License (MIT)</name>
			<url>https://mit-license.org</url>
			<distribution>repo</distribution>
		</license>
	</licenses>

	<developers>
		<developer>
			<id>gongjun</id>
			<name>gongjun</name>
			<email>dt_flys@hotmail.com</email>
			<url>https://forest.dtflyx.com</url>
		</developer>
	</developers>

	<scm>
		<url>https://github.com/dromara/forest</url>
		<connection>scm:git:https://github.com/dromara/forest.git</connection>
		<developerConnection>https://forest.dtflyx.com</developerConnection>
		<tag>1.5.28</tag>
	</scm>

	<properties>
		<maven.compiler.source>1.8</maven.compiler.source>
		<maven.compiler.target>1.8</maven.compiler.target>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

		<spring.version>5.3.20</spring.version>
		<spring-boot.version>2.6.8</spring-boot.version>
		<common-io.version>2.7</common-io.version>
		<commons-fileupload.version>1.3.3</commons-fileupload.version>
		<commons-logging.version>1.2</commons-logging.version>
		<commons-lang3.version>3.9</commons-lang3.version>
		<juniversalchardet.version>1.0.3</juniversalchardet.version>
		<jsr305.version>3.0.1</jsr305.version>
		<fastjson.version>1.2.83</fastjson.version>
		<jackson.version>2.13.3</jackson.version>
		<jackson-databind.version>2.13.3</jackson-databind.version>
		<jackson-annotations.version>2.13.3</jackson-annotations.version>
		<gson.version>2.8.9</gson.version>
		<xercesImpl.version>2.12.2</xercesImpl.version>
		<slf4j.version>1.7.10</slf4j.version>
		<log4j.version>2.13.3</log4j.version>
		<okhttp.version>3.14.9</okhttp.version>
		<httpcore.version>4.4.14</httpcore.version>
		<httpclient.version>4.5.13</httpclient.version>

		<mockwebserver.version>3.14.9</mockwebserver.version>
		<mockserver-netty.version>5.4.1</mockserver-netty.version>
		<mockito.version>4.5.1</mockito.version>
		<junit.version>4.13.2</junit.version>
		<moco-core.version>1.2.0</moco-core.version>
		<spring-boot-starter-test.version>2.5.12</spring-boot-starter-test.version>

		<maven-compiler-plugin.version>3.8.0</maven-compiler-plugin.version>
		<maven-source-plugin.version>2.1.2</maven-source-plugin.version>
		<maven-javadoc-plugin.version>3.2.0</maven-javadoc-plugin.version>
		<cobertura-maven-plugin.version>2.7</cobertura-maven-plugin.version>
		<nexus-staging-maven-plugin.version>1.6.3</nexus-staging-maven-plugin.version>
		<spring-boot-maven-plugin.version>2.0.1.RELEASE</spring-boot-maven-plugin.version>
		<maven-deploy-plugin.version>2.8.2</maven-deploy-plugin.version>
		<maven-gpg-plugin.version>1.5</maven-gpg-plugin.version>
		<protobuf.version>3.16.1</protobuf.version>
	</properties>

	<modules>
		<module>forest-core</module>
		<module>forest-spring</module>
		<module>forest-spring-boot-starter</module>
		<module>forest-mock</module>
	</modules>

	<dependencies>
		<!-- mockito -->
		<dependency>
			<groupId>org.mockito</groupId>
			<artifactId>mockito-core</artifactId>
			<version>${mockito.version}</version>
			<exclusions>
				<exclusion>
					<artifactId>byte-buddy-agent</artifactId>
					<groupId>net.bytebuddy</groupId>
				</exclusion>
				<exclusion>
					<artifactId>byte-buddy</artifactId>
					<groupId>net.bytebuddy</groupId>
				</exclusion>
			</exclusions>
			<scope>test</scope>
		</dependency>

		<!-- junit -->
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>${junit.version}</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>xerces</groupId>
			<artifactId>xercesImpl</artifactId>
			<version>${xercesImpl.version}</version>
			<scope>provided</scope>
		</dependency>

		<!-- Netty -->
		<dependency>
			<groupId>io.netty</groupId>
			<artifactId>netty-all</artifactId>
			<version>4.1.45.Final</version>
			<scope>test</scope>
		</dependency>

		<!-- mock server -->
		<dependency>
			<groupId>org.mock-server</groupId>
			<artifactId>mockserver-netty</artifactId>
			<version>${mockserver-netty.version}</version>
			<scope>provided</scope>
			<exclusions>
				<exclusion>
					<groupId>xerces</groupId>
					<artifactId>xercesImpl</artifactId>
				</exclusion>
				<exclusion>
					<groupId>io.netty</groupId>
					<artifactId>netty-buffer</artifactId>
				</exclusion>
				<exclusion>
					<groupId>io.netty</groupId>
					<artifactId>netty-codec</artifactId>
				</exclusion>
				<exclusion>
					<groupId>io.netty</groupId>
					<artifactId>netty-codec-http</artifactId>
				</exclusion>
				<exclusion>
					<groupId>io.netty</groupId>
					<artifactId>netty-codec-socks</artifactId>
				</exclusion>
				<exclusion>
					<groupId>io.netty</groupId>
					<artifactId>netty-common</artifactId>
				</exclusion>
				<exclusion>
					<groupId>io.netty</groupId>
					<artifactId>netty-handler</artifactId>
				</exclusion>
				<exclusion>
					<groupId>io.netty</groupId>
					<artifactId>netty-transport</artifactId>
				</exclusion>
				<exclusion>
					<artifactId>guava</artifactId>
					<groupId>com.google.guava</groupId>
				</exclusion>
				<exclusion>
					<groupId>com.fasterxml.jackson.core</groupId>
					<artifactId>jackson-annotations</artifactId>
				</exclusion>
				<exclusion>
					<groupId>com.fasterxml.jackson</groupId>
					<artifactId>jackson-base</artifactId>
				</exclusion>
				<exclusion>
					<groupId>com.fasterxml.jackson.core</groupId>
					<artifactId>jackson-core</artifactId>
				</exclusion>
				<exclusion>
					<groupId>com.fasterxml.jackson.core</groupId>
					<artifactId>jackson-databind</artifactId>
				</exclusion>
			</exclusions>
		</dependency>

		<dependency>
			<groupId>org.mock-server</groupId>
			<artifactId>mockserver-client-java</artifactId>
			<version>${mockserver-netty.version}</version>
			<scope>test</scope>
			<exclusions>
				<exclusion>
					<artifactId>guava</artifactId>
					<groupId>com.google.guava</groupId>
				</exclusion>
			</exclusions>
		</dependency>

		<dependency>
			<groupId>com.github.dreamhead</groupId>
			<artifactId>moco-core</artifactId>
			<version>${moco-core.version}</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.assertj</groupId>
			<artifactId>assertj-core</artifactId>
			<version>3.13.2</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>com.squareup.okhttp3</groupId>
			<artifactId>mockwebserver</artifactId>
			<version>3.14.9</version>
			<scope>test</scope>
		</dependency>


		<dependency>
			<groupId>cn.hutool</groupId>
			<artifactId>hutool-all</artifactId>
			<version>5.5.2</version>
			<scope>test</scope>
		</dependency>

	</dependencies>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-starter-web</artifactId>
				<version>${spring-boot.version}</version>
				<exclusions>
					<exclusion>
						<groupId>org.apache.tomcat.embed</groupId>
						<artifactId>tomcat-embed-logging-juli</artifactId>
					</exclusion>
					<!-- use ctrip modified version instead -->
					<exclusion>
						<groupId>org.apache.tomcat.embed</groupId>
						<artifactId>tomcat-embed-core</artifactId>
					</exclusion>
				</exclusions>
			</dependency>

			<dependency>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-starter-test</artifactId>
				<version>${spring-boot-starter-test.version}</version>
				<scope>test</scope>
			</dependency>

			<dependency>
				<!-- Import dependency management from Spring Boot -->
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-dependencies</artifactId>
				<version>${spring-boot.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}</version>
				<inherited>true</inherited>
				<executions>
					<execution>
						<id>main-compile</id>
						<phase>compile</phase>
						<goals>
							<goal>compile</goal>
						</goals>
						<configuration>
							<source>${maven.compiler.source}</source>
							<target>${maven.compiler.target}</target>
							<encoding>UTF-8</encoding>
						</configuration>
					</execution>
					<execution>
						<id>test-compile</id>
						<phase>test-compile</phase>
						<goals>
							<goal>testCompile</goal>
						</goals>
						<configuration>
							<fork>true</fork>
							<compilerArgs>
								<arg>-parameters</arg>
							</compilerArgs>
							<source>${maven.compiler.source}</source>
							<target>${maven.compiler.target}</target>
						</configuration>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>cobertura-maven-plugin</artifactId>
				<version>${cobertura-maven-plugin.version}</version>
				<configuration>
					<formats>
						<format>html</format>
						<format>xml</format>
					</formats>
					<check />
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-deploy-plugin</artifactId>
				<version>${maven-deploy-plugin.version}</version>
			</plugin>
		</plugins>
	</build>

	<distributionManagement>
		<snapshotRepository>
			<id>oss-snapshot</id>
			<url>https://oss.sonatype.org/content/repositories/snapshots</url>
		</snapshotRepository>
		<repository>
			<id>oss-release</id>
			<url>https://oss.sonatype.org/service/local/staging/deploy/maven2</url>
		</repository>
	</distributionManagement>


	<profiles>
		<profile>
			<id>disable-javadoc-doclint</id>
			<activation>
				<jdk>[1.8,)</jdk>
			</activation>
			<properties>
				<additionalparam>-Xdoclint:none</additionalparam>
			</properties>
		</profile>
		<profile>
			<id>oss-release</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.sonatype.plugins</groupId>
						<artifactId>nexus-staging-maven-plugin</artifactId>
						<version>${nexus-staging-maven-plugin.version}</version>
						<extensions>true</extensions>
						<configuration>
							<serverId>oss-snapshot</serverId>
							<nexusUrl>https://oss.sonatype.org/</nexusUrl>
							<autoReleaseAfterClose>false</autoReleaseAfterClose>
						</configuration>
					</plugin>

					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-source-plugin</artifactId>
						<version>${maven-source-plugin.version}</version>
						<executions>
							<execution>
								<id>attach-sources</id>
								<goals>
									<goal>jar</goal>
								</goals>
							</execution>
						</executions>
					</plugin>

					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-javadoc-plugin</artifactId>
						<version>${maven-javadoc-plugin.version}</version>
						<executions>
							<execution>
								<id>attach-javadocs</id>
								<phase>package</phase>
								<goals>
									<goal>jar</goal>
								</goals>
								<configuration>
									<encoding>UTF-8</encoding>
									<charset>UTF-8</charset>
									<docencoding>UTF-8</docencoding>
<!--									<additionalJOption>-Xdoclint:none</additionalJOption>-->
								</configuration>
							</execution>
						</executions>
					</plugin>

					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-gpg-plugin</artifactId>
						<version>${maven-gpg-plugin.version}</version>
						<executions>
							<execution>
								<id>sign-artifacts</id>
								<phase>verify</phase>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>

</project>
