<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/maven-v4_0_0.xsd">
	<modelVersion>4.0.0</modelVersion>
	
	<parent>
		<groupId>org.restcomm</groupId>
		<artifactId>restcomm-parent</artifactId>
		<version>3.0.4</version>
	</parent>
	
	<groupId>org.restcomm.cluster</groupId>
	<artifactId>restcomm-cluster</artifactId>
	<version>3.0.0.13</version>
	
	<packaging>pom</packaging>
	
	<name>Restcomm Cluster Framework Parent</name>
	<description>Restcomm Cluster Framework Parent</description>
	<url>https://github.com/Restcomm/cluster</url>
	
	<scm>
		<connection>scm:git:https://github.com/RestComm/cluster.git</connection>
		<developerConnection>scm:git:git@github.com:RestComm/cluster.git</developerConnection>
		<url>https://github.com/RestComm/cluster</url>
	</scm>

	<modules>
		<module>cache</module>
		<module>core</module>
		<module>timers</module>
	</modules>

	<dependencies>
		<!-- Infinispan dependencies for WildFly 10.x -->
		<dependency>
			<groupId>org.infinispan</groupId>
			<artifactId>infinispan-core</artifactId>
			<version>8.2.4.Final</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>org.infinispan</groupId>
			<artifactId>infinispan-tree</artifactId>
			<version>8.2.4.Final</version>
			<scope>provided</scope>
		</dependency>
	</dependencies>

	<profiles>
		<profile>
			<id>example</id>
			<modules>
				<module>example</module>
				<!--<module>example_temp</module>-->
			</modules>
		</profile>
		<profile>
			<id>jboss-as-7</id>
			<dependencies>
				<!--
				<dependency>
					<groupId>org.jboss.as</groupId>
					<artifactId>jboss-as-clustering-infinispan</artifactId>
					<version>7.1.1.Final</version>
				</dependency>
				-->
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-core</artifactId>
					<version>5.1.2.FINAL</version>
				</dependency>
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-tree</artifactId>
					<version>5.1.2.Final</version>
				</dependency>
			</dependencies>
		</profile>
		<profile>
			<id>jboss-as-72</id>
			<activation>
				<!--
				Never use <activeByDefault>
				<activeByDefault>true</activeByDefault>
				https://dzone.com/articles/maven-profile-best-practices
				-->
				<!--<property><name>!foo.bar</name></property>-->
			</activation>
			<dependencies>
				<!--
				<dependency>
					<groupId>org.jboss.as</groupId>
					<artifactId>jboss-as-clustering-infinispan</artifactId>
					<version>7.2.0.Final</version>
				</dependency>
				-->
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-core</artifactId>
					<version>5.2.1.Final</version>
					<!--<scope>provided</scope>-->
				</dependency>
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-tree</artifactId>
					<version>5.2.1.Final</version>
					<!--<scope>provided</scope>-->
				</dependency>
			</dependencies>
		</profile>
		<profile>
			<id>jboss-as-72-example</id>
			<activation>
				<!--
				Never use <activeByDefault>
				<activeByDefault>true</activeByDefault>
				https://dzone.com/articles/maven-profile-best-practices
				-->
				<!--<property><name>!foo.bar</name></property>-->
			</activation>
			<dependencies>
				<!--
				<dependency>
					<groupId>org.jboss.as</groupId>
					<artifactId>jboss-as-clustering-infinispan</artifactId>
					<version>7.2.0.Final</version>
				</dependency>
				-->
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-core</artifactId>
					<version>5.2.1.Final</version>
				</dependency>
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-tree</artifactId>
					<version>5.2.1.Final</version>
				</dependency>
			</dependencies>
			<modules>
				<module>example</module>
			</modules>
		</profile>
		<profile>
			<id>jboss-as-10</id>
			<activation>
				<!--<property><name>!foo.bar</name></property>-->
			</activation>
			<dependencies>
				<!--
				<dependency>
					<groupId>org.wildfly</groupId>
					<artifactId>wildfly-clustering-infinispan-extension</artifactId>
					<version>10.0.0.Final</version>
				</dependency>
				-->
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-core</artifactId>
					<version>8.1.0.Final</version>
				</dependency>
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-tree</artifactId>
					<version>8.1.0.Final</version>
				</dependency>
			</dependencies>
		</profile>
		<profile>
			<id>jboss-eap-6.4</id>
			<dependencies>
				<!--
				<dependency>
					<groupId>org.jboss.as</groupId>
					<artifactId>jboss-as-clustering-infinispan</artifactId>
					<version>7.5.0.Final-redhat-21</version>
				</dependency>
				-->
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-tree</artifactId>
					<version>5.2.10.Final-redhat-1</version>
				</dependency>
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-core</artifactId>
					<version>5.2.11.Final-redhat-2</version>
				</dependency>
			</dependencies>
		</profile>
		<profile>
			<id>jboss-eap-6.4-example</id>
			<dependencies>
				<!--
				<dependency>
					<groupId>org.jboss.as</groupId>
					<artifactId>jboss-as-clustering-infinispan</artifactId>
					<version>7.5.0.Final-redhat-21</version>
				</dependency>
				-->
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-tree</artifactId>
					<version>5.2.10.Final-redhat-1</version>
				</dependency>
				<dependency>
					<groupId>org.infinispan</groupId>
					<artifactId>infinispan-core</artifactId>
					<version>5.2.11.Final-redhat-2</version>
				</dependency>
			</dependencies>
			<modules>
				<module>example</module>
			</modules>
		</profile>
		<profile>
			<id>maven-release</id>
			<modules>
				<module>example</module>
			</modules>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-release-plugin</artifactId>
						<configuration>
							<autoVersionSubmodules>true</autoVersionSubmodules>							
							<arguments>-Dmaven.test.skip</arguments>						
						</configuration>
					</plugin>
				</plugins>
			</build>		
		</profile>
	</profiles>
	
	<build>
		<plugins>
			<plugin>
				<artifactId>maven-eclipse-plugin</artifactId>
   				<groupId>org.mobicents.tools</groupId>
				<inherited>false</inherited>
				<executions />
				<configuration>
					<excludePoms />
					<classpathExcludes>
						<exclude>xml-apis:xml-apis</exclude>
						<exclude>jtidy:jtidy</exclude>																							
					</classpathExcludes>
					<resolveTransitiveDependencies>true</resolveTransitiveDependencies>
					<eclipseProjectName>restcomm-cluster</eclipseProjectName>
				</configuration>
			</plugin>
			<plugin>
				<artifactId>maven-javadoc-plugin</artifactId>
				<!-- Note: Older versions will not work. -->
				<version>2.7</version>
				<configuration>
					<doclet>org.jboss.apiviz.APIviz</doclet>
					<docletArtifact>
						<groupId>org.jboss.apiviz</groupId>
						<artifactId>apiviz</artifactId>
						<version>1.3.2.GA</version>
					</docletArtifact>
					<useStandardDocletOptions>true</useStandardDocletOptions>
					<charset>UTF-8</charset>
					<encoding>UTF-8</encoding>
					<docencoding>UTF-8</docencoding>
					<breakiterator>true</breakiterator>
					<version>true</version>
					<author>true</author>
					<keywords>true</keywords>
					<stylesheetfile>${basedir}/javadoc/stylesheet.css</stylesheetfile>
					<javadocDirectory>${basedir}/javadoc</javadocDirectory>
					<docfilessubdirs>true</docfilessubdirs>
					<overview>${basedir}/javadoc/overview.html</overview>
					<detectLinks />
					<detectOfflineLinks />
					<includeDependencySources />
					<includeTransitiveDependencySources />
				</configuration>
				<executions>
					<execution>
						<id>javadoc</id>
						<goals>
							<goal>javadoc</goal>
						</goals>
						<phase>site</phase>
					</execution>
					<execution>
						<id>aggregate</id>
						<goals>
							<goal>aggregate</goal>
						</goals>
						<phase>site</phase>
					</execution>
				</executions>
      		</plugin>
		</plugins>		
	</build>
	
	<!-- dupe info from parent, but it's only way to retrieve the parent without checkout -->

	<repositories>
		<repository>
			<id>restcomm-public-repository-group</id>
			<name>Restcomm Public Maven Repository Group</name>
			<url>https://oss.sonatype.org/content/groups/public</url>
			<layout>default</layout>
			<releases>
				<enabled>true</enabled>
				<updatePolicy>never</updatePolicy>
			</releases>
			<snapshots>
				<enabled>true</enabled>
				<updatePolicy>never</updatePolicy>
			</snapshots>
		</repository>
		<repository>
			<id>jboss-public-repository-group</id>
			<name>JBoss Public Maven Repository Group</name>
			<url>https://repository.jboss.org/nexus/content/groups/public</url>
			<layout>default</layout>
			<releases>
				<enabled>true</enabled>
				<updatePolicy>never</updatePolicy>
			</releases>
			<snapshots>
				<enabled>true</enabled>
				<updatePolicy>never</updatePolicy>
			</snapshots>
		</repository>
		<repository>
			<id>rht-public-repository-group</id>
			<name>RHT Public Maven Repository Group</name>
			<url>https://maven.repository.redhat.com/ga/</url>
			<layout>default</layout>
			<releases>
				<enabled>true</enabled>
				<updatePolicy>never</updatePolicy>
			</releases>
			<snapshots>
				<enabled>true</enabled>
				<updatePolicy>never</updatePolicy>
			</snapshots>
		</repository>
	</repositories>
	
</project>
