<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>

	<name>Fastnate Root</name>
	<description>The Fastnate root project</description>
	<url>https://fastnate.org/</url>

	<groupId>org.fastnate</groupId>
	<artifactId>fastnate-base</artifactId>
	<version>2.0.0</version>
	<packaging>pom</packaging>

	<organization>
		<name>fastnate.org</name>
		<url>http://fastnate.org</url>
	</organization>

	<licenses>
		<license>
			<name>Apache License, Version 2.0</name>
			<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
		</license>
	</licenses>

	<developers>
		<developer>
			<name>Tobias Liefke</name>
			<email>liefke@fastnate.org</email>
			<url>https://github.com/liefke</url>
		</developer>
	</developers>

	<contributors>
		<contributor>
			<name>Andreas Penski</name>
		</contributor>
		<contributor>
			<name>Heiko Schefter</name>
		</contributor>
		<contributor>
			<name>André Babinski</name>
		</contributor>
		<contributor>
			<name>Mathieu Lavigne</name>
		</contributor>
	</contributors>

	<distributionManagement>
		<repository>
			<id>fastnate-download</id>
			<url>scpexe://download.fastnate.org${fastnate.download.path}/repository</url>
		</repository>
		<site>
			<id>fastnate-api</id>
			<url>scpexe://api.fastnate.org${fastnate.api.path}/latest</url>
		</site>
	</distributionManagement>

	<scm>
		<url>https://github.com/liefke/org.fastnate</url>
		<connection>scm:git:git://github.com/liefke/org.fastnate.git</connection>
		<developerConnection>scm:git:git@github.com:liefke/org.fastnate.git</developerConnection>
		<tag>fastnate-base-2.0.0</tag>
	</scm>

	<issueManagement>
		<url>https://github.com/liefke/org.fastnate/issues</url>
		<system>GitHub</system>
	</issueManagement>

	<modules>
		<module>fastnate-generator</module>
		<module>fastnate-generator-test</module>
		<module>fastnate-hibernate</module>
		<module>fastnate-data</module>
		<module>fastnate-csv</module>
		<module>fastnate-maven-plugin</module>
		<module>fastnate-maven-test</module>
		<module>fastnate-examples</module>
	</modules>

	<properties>
		<!-- Projectroot -->
		<fastnate.root>${basedir}</fastnate.root>

		<!-- Build specific properties -->
		<build.number>Local</build.number>
		<build.svnRevNumber>Unknown</build.svnRevNumber>
		<maven.build.timestamp.format>yyyyMMdd'T'HHmmss</maven.build.timestamp.format>
		<build.timestamp>${maven.build.timestamp}</build.timestamp>
		<project.scm.id>git-server</project.scm.id>

		<!-- Default encoding -->
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

		<!-- Versions -->
		<lombok.version>1.18.48</lombok.version>
		<slf4j.version>2.0.18</slf4j.version>
		<hibernate.version>6.6.3.Final</hibernate.version>
		<hibernate.validator.version>8.0.2.Final</hibernate.validator.version>
	</properties>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>org.projectlombok</groupId>
				<artifactId>lombok</artifactId>
				<version>${lombok.version}</version>
			</dependency>
			<dependency>
				<groupId>org.slf4j</groupId>
				<artifactId>slf4j-api</artifactId>
				<version>${slf4j.version}</version>
			</dependency>
			<dependency>
				<groupId>commons-io</groupId>
				<artifactId>commons-io</artifactId>
				<version>2.21.0</version>
			</dependency>
			<dependency>
				<groupId>org.apache.commons</groupId>
				<artifactId>commons-lang3</artifactId>
				<version>3.20.0</version>
			</dependency>
			<dependency>
				<groupId>jakarta.validation</groupId>
				<artifactId>jakarta.validation-api</artifactId>
				<version>3.0.2</version>
			</dependency>
			<dependency>
				<groupId>net.sf.supercsv</groupId>
				<artifactId>super-csv</artifactId>
				<version>2.4.0</version>
			</dependency>
	        <dependency>
	            <groupId>jakarta.xml.bind</groupId>
	            <artifactId>jakarta.xml.bind-api</artifactId>
	            <version>4.0.2</version>
	        </dependency>
			
			<!-- Reflections -->
			<dependency>
				<groupId>org.reflections</groupId>
				<artifactId>reflections</artifactId>
				<version>0.10.2</version>
				<exclusions>
					<exclusion>
						<groupId>dom4j</groupId>
						<artifactId>dom4j</artifactId>
					</exclusion>
					<exclusion>
						<groupId>com.google.code.gson</groupId>
						<artifactId>gson</artifactId>
					</exclusion>
				</exclusions>
			</dependency>

			<!-- Injections for DataProvider -->
			<dependency>
				<groupId>jakarta.inject</groupId>
				<artifactId>jakarta.inject-api</artifactId>
				<version>2.0.1</version>
			</dependency>
			<dependency>
				<groupId>jakarta.annotation</groupId>
				<artifactId>jakarta.annotation-api</artifactId>
				<version>2.0.0</version>
			</dependency>

			<!-- The JPA standalone API -->
			<dependency>
				<groupId>jakarta.persistence</groupId>
				<artifactId>jakarta.persistence-api</artifactId>
				<version>3.1.0</version>
			</dependency>

			<!-- Hibernate dependencies -->
			<dependency>
				<groupId>org.hibernate.orm</groupId>
				<artifactId>hibernate-core</artifactId>
				<version>${hibernate.version}</version>
				<exclusions>
					<exclusion>
						<groupId>dom4j</groupId>
						<artifactId>dom4j</artifactId>
					</exclusion>
				</exclusions>
			</dependency>

			<dependency>
				<groupId>org.hibernate.orm</groupId>
				<artifactId>hibernate-entitymanager</artifactId>
				<version>${hibernate.version}</version>
				<exclusions>
					<exclusion>
						<groupId>dom4j</groupId>
						<artifactId>dom4j</artifactId>
					</exclusion>
				</exclusions>
			</dependency>

			<dependency>
				<groupId>org.hibernate.validator</groupId>
				<artifactId>hibernate-validator</artifactId>
				<version>${hibernate.validator.version}</version>
			</dependency>
			
			<!-- Test dependencies -->
			<dependency>
			    <groupId>org.junit.jupiter</groupId>
			    <artifactId>junit-jupiter-api</artifactId>
			    <version>5.14.4</version>
			</dependency>

			<dependency>
			    <groupId>org.junit.platform</groupId>
			    <artifactId>junit-platform-suite-engine</artifactId>
			    <version>1.14.2</version>
			</dependency>

			<dependency>
				<groupId>org.slf4j</groupId>
				<artifactId>slf4j-jdk14</artifactId>
				<version>${slf4j.version}</version>
			</dependency>

			<dependency>
			    <groupId>jakarta.el</groupId>
			    <artifactId>jakarta.el-api</artifactId>
			    <version>5.0.0</version>
			</dependency>

			<dependency>
				<groupId>com.h2database</groupId>
				<artifactId>h2</artifactId>
				<version>2.5.252</version>
			</dependency>

			<dependency>
				<groupId>org.assertj</groupId>
				<artifactId>assertj-core</artifactId>
				<version>3.27.7</version>
			</dependency>

			<dependency>
				<groupId>org.springframework.data</groupId>
				<artifactId>spring-data-jpa</artifactId>
				<version>4.0.1</version>
			</dependency>

			<dependency>
				<groupId>org.liquibase</groupId>
				<artifactId>liquibase-core</artifactId>
				<version>4.33.0</version>
			</dependency>

		</dependencies>
	</dependencyManagement>

	<build>
		<extensions>
			<!-- Enable the use of SSH for deployment -->
			<extension>
				<groupId>org.apache.maven.wagon</groupId>
				<artifactId>wagon-ssh-external</artifactId>
				<version>3.5.3</version>
			</extension>
		</extensions>
		<pluginManagement>
			<plugins>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-enforcer-plugin</artifactId>
					<version>3.6.3</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-clean-plugin</artifactId>
					<version>3.5.0</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-install-plugin</artifactId>
					<version>3.2.0</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-deploy-plugin</artifactId>
					<version>3.2.0</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-resources-plugin</artifactId>
					<version>3.5.0</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-compiler-plugin</artifactId>
					<version>3.16.0</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-source-plugin</artifactId>
					<version>3.4.0</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-jar-plugin</artifactId>
					<version>3.5.1</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-javadoc-plugin</artifactId>
					<version>3.12.0</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-site-plugin</artifactId>
					<version>3.22.0</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-checkstyle-plugin</artifactId>
					<version>3.6.0</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-surefire-plugin</artifactId>
					<version>3.6.0</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-release-plugin</artifactId>
					<version>3.3.1</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-gpg-plugin</artifactId>
					<version>3.2.8</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-plugin-plugin</artifactId>
					<version>3.16.0</version>
				</plugin>
				<plugin>
					<groupId>org.projectlombok</groupId>
					<artifactId>lombok-maven-plugin</artifactId>
					<version>1.18.20.0</version>
					<dependencies>
						<dependency>
							<groupId>org.projectlombok</groupId>
							<artifactId>lombok</artifactId>
							<version>${lombok.version}</version>
						</dependency>
					</dependencies>
				</plugin>
				<plugin>
					<groupId>org.sonatype.central</groupId>
					<artifactId>central-publishing-maven-plugin</artifactId>
					<version>0.11.0</version>
				</plugin>
			</plugins>
		</pluginManagement>
		<plugins>
			<plugin>
				<!-- Enforce correct plugin versions -->
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-enforcer-plugin</artifactId>
				<executions>
					<execution>
						<id>enforce-maven</id>
						<goals>
							<goal>enforce</goal>
						</goals>
						<configuration>
							<rules>
								<requireMavenVersion>
									<version>3.8.0</version>
								</requireMavenVersion>
								<requireJavaVersion>
									<version>21</version>
								</requireJavaVersion>
								<requirePluginVersions>
									<unCheckedPluginList>org.fastnate:fastnate-maven-plugin</unCheckedPluginList>
								</requirePluginVersions>
							</rules>
						</configuration>
					</execution>
				</executions>
			</plugin>

			<!-- Define the default compiler settings. -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<configuration>
					<source>21</source>
					<target>21</target>
					<encoding>UTF-8</encoding>
				</configuration>
			</plugin>

			<!-- We are open source - attach the sources. -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-source-plugin</artifactId>
				<executions>
					<execution>
						<id>attach-sources</id>
						<goals>
							<goal>jar</goal>
						</goals>
					</execution>
				</executions>
			</plugin>

			<!-- Define the default manifest entries -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-jar-plugin</artifactId>
				<configuration>
					<archive>
						<manifest>
							<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
						</manifest>
						<manifest-entries>
							<Implementation-Build>${build.number}</Implementation-Build>
							<Implementation-Revision>${build.svnRevNumber}</Implementation-Revision>
						</manifest-entries>
					</archive>
				</configuration>
			</plugin>

			<!-- Delombok for JavaDoc plugin -->
			<plugin>
				<groupId>org.projectlombok</groupId>
				<artifactId>lombok-maven-plugin</artifactId>
				<executions>
					<execution>
						<phase>generate-sources</phase>
						<goals>
							<goal>delombok</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					<addOutputDirectory>false</addOutputDirectory>
					<sourceDirectory>src/main/java</sourceDirectory>
				</configuration>
			</plugin>

			<!-- Add Javadoc -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-javadoc-plugin</artifactId>
				<executions>
					<execution>
						<id>make-javadoc</id>
						<phase>package</phase>
						<goals>
							<goal>jar</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					<sourcepath>target/generated-sources/delombok</sourcepath>
				</configuration>
			</plugin>

			<!-- Generate documentation for maven plugin(s). -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-site-plugin</artifactId>
			</plugin>

			<!-- Enable release of Fastnate -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-release-plugin</artifactId>
				<configuration>
					<autoVersionSubmodules>true</autoVersionSubmodules>
					<useReleaseProfile>false</useReleaseProfile>
					<releaseProfiles>release</releaseProfiles>
					<goals>deploy</goals>
				</configuration>
			</plugin>
		</plugins>
	</build>

	<!-- Generate Javadoc for site -->
	<reporting>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-javadoc-plugin</artifactId>
				<configuration>
					<sourcepath>target/generated-sources/delombok</sourcepath>
					<show>private</show>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-checkstyle-plugin</artifactId>
				<configuration>
					<configLocation>src/checkstyle/checkstyle.xml</configLocation>
					<propertyExpansion>config_loc=${fastnate.root}/src/checkstyle</propertyExpansion>
				</configuration>
			</plugin>
		</plugins>
	</reporting>

	<profiles>
		
		<!-- 
			 Additional JDBC drivers for testing. 
			 Integrated into its own profile to keep them optional for contributors. 
		-->
		<profile>
			<id>test-all-databases</id>

			<dependencies>
				<!-- Oracle -->
				<dependency>
					<groupId>com.oracle.database.jdbc</groupId>
					<artifactId>ojdbc11</artifactId>
					<version>23.26.3.0.0</version>
					<scope>test</scope>
				</dependency>

				<!-- PostgreSQL -->
				<dependency>
					<groupId>org.postgresql</groupId>
					<artifactId>postgresql</artifactId>
					<version>42.7.13</version>
					<scope>test</scope>
				</dependency>

				<!-- MySQL -->
				<dependency>
					<groupId>com.mysql</groupId>
					<artifactId>mysql-connector-j</artifactId>
					<version>26.7.0</version>
					<scope>test</scope>
				</dependency>

				<!-- MS SQL Server -->
				<dependency>
					<groupId>com.microsoft.sqlserver</groupId>
					<artifactId>mssql-jdbc</artifactId>
					<version>13.6.0.jre11</version>
					<scope>test</scope>
				</dependency>
			</dependencies>
		</profile>

		<!-- Sign everything -->
		<profile>
			<id>sign</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-gpg-plugin</artifactId>
						<executions>
							<execution>
								<id>sign-artifacts</id>
								<phase>verify</phase>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>

		<!-- Release to OSSRH -->
		<profile>
			<id>ossrh-release</id>
			<distributionManagement>
				<snapshotRepository>
					<id>ossrh</id>
					<url>https://oss.sonatype.org/content/repositories/snapshots</url>
				</snapshotRepository>
				<repository>
					<id>ossrh</id>
					<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
				</repository>
			</distributionManagement>
			<build>
				<plugins>
					<plugin>
						<groupId>org.sonatype.central</groupId>
						<artifactId>central-publishing-maven-plugin</artifactId>
						<version>0.9.0</version>
						<extensions>true</extensions>
						<configuration>
							<publishingServerId>ossrh</publishingServerId>
							<autoPublish>true</autoPublish>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>

		<profile>
			<id>only-eclipse</id>
			<activation>
				<property>
					<name>m2e.version</name>
				</property>
			</activation>
			<build>
				<pluginManagement>
					<plugins>
						<!-- This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build 
							itself. -->
						<plugin>
							<groupId>org.eclipse.m2e</groupId>
							<artifactId>lifecycle-mapping</artifactId>
							<version>1.0.0</version>
							<configuration>
								<lifecycleMappingMetadata>
									<pluginExecutions>
										<pluginExecution>
											<pluginExecutionFilter>
												<groupId>org.projectlombok</groupId>
												<artifactId>lombok-maven-plugin</artifactId>
												<versionRange>[1.0.0,)</versionRange>
												<goals>
													<goal>delombok</goal>
												</goals>
											</pluginExecutionFilter>
											<action>
												<ignore />
											</action>
										</pluginExecution>
									</pluginExecutions>
								</lifecycleMappingMetadata>
							</configuration>
						</plugin>
					</plugins>
				</pluginManagement>
			</build>
		</profile>
	</profiles>

</project>