<?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>

    <parent>
        <groupId>eu.dnetlib.dhp</groupId>
        <artifactId>openaire-solr-docker</artifactId>
        <version>2.0.0</version>
        <relativePath>../pom.xml</relativePath>
    </parent>

    <artifactId>openaire-solr-payload-mapper</artifactId>
    <version>2.0.0</version>
    <packaging>jar</packaging>

    <dependencies>
        <dependency>
            <groupId>eu.dnetlib.dhp</groupId>
            <artifactId>dhp-index-schemas</artifactId>
            <exclusions>
                <exclusion>
                    <artifactId>lombok</artifactId>
                    <groupId>org.projectlombok</groupId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.apache.solr</groupId>
            <artifactId>solr-solrj</artifactId>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-databind</artifactId>
        </dependency>
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-lang3</artifactId>
        </dependency>
    </dependencies>

    <profiles>
        <profile>
            <id>java11</id>
            <activation>
                <jdk>[11</jdk>
            </activation>
            <build>
                <pluginManagement>
                    <plugins>
                        <plugin>
                            <groupId>org.apache.maven.plugins</groupId>
                            <artifactId>maven-surefire-plugin</artifactId>
                            <version>3.0.0-M4</version>
                            <configuration>
                                <!-- only for java 11+ to run spark in tests -->
                                <argLine>--add-opens=java.base/java.lang=ALL-UNNAMED
                                    --add-opens=java.base/java.lang.invoke=ALL-UNNAMED
                                    --add-opens=java.base/java.lang.reflect=ALL-UNNAMED
                                    --add-opens=java.base/java.io=ALL-UNNAMED
                                    --add-opens=java.base/java.net=ALL-UNNAMED
                                    --add-opens=java.base/java.nio=ALL-UNNAMED
                                    --add-opens=java.base/java.util=ALL-UNNAMED
                                    --add-opens=java.base/java.util.concurrent=ALL-UNNAMED
                                    --add-opens=java.base/java.util.concurrent.atomic=ALL-UNNAMED
                                    --add-opens=java.base/sun.nio.ch=ALL-UNNAMED
                                    --add-opens=java.base/sun.nio.cs=ALL-UNNAMED
                                    --add-opens=java.base/sun.security.action=ALL-UNNAMED
                                    --add-opens=java.base/sun.util.calendar=ALL-UNNAMED
                                </argLine>
                                <redirectTestOutputToFile>true</redirectTestOutputToFile>
                                <trimStackTrace>false</trimStackTrace>
                            </configuration>
                        </plugin>
                    </plugins>
                </pluginManagement>
            </build>
        </profile>
    </profiles>

</project>