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

    <artifactId>rdm-rest</artifactId>

    <parent>
        <groupId>ru.i-novus.ms.rdm</groupId>
        <artifactId>rdm</artifactId>
        <version>3.1.15</version>
    </parent>

    <properties>
        <backend.default.port>8081</backend.default.port>
        <commons.fileupload.version>1.4</commons.fileupload.version>

        <maven.deploy.skip>true</maven.deploy.skip>
        <jacoco.skip>false</jacoco.skip>
    </properties>

    <dependencies>

        <dependency>
            <groupId>ru.i-novus.ms.rdm</groupId>
            <artifactId>rdm-api</artifactId>
        </dependency>

        <dependency>
            <groupId>ru.i-novus.ms.rdm</groupId>
            <artifactId>rdm-impl</artifactId>
            <scope>runtime</scope>
        </dependency>

        <dependency>
            <groupId>net.n2oapp.platform</groupId>
            <artifactId>n2o-platform-jaxrs-commons</artifactId>
        </dependency>

        <dependency>
            <groupId>net.n2oapp.platform</groupId>
            <artifactId>n2o-platform-starter-jaxrs-server</artifactId>
        </dependency>

        <dependency>
            <groupId>net.n2oapp.platform</groupId>
            <artifactId>n2o-platform-starter-ms</artifactId>
        </dependency>

        <dependency>
            <groupId>org.apache.cxf</groupId>
            <artifactId>cxf-rt-rs-client</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
        </dependency>

        <dependency>
            <groupId>ru.i-novus.components</groupId>
            <artifactId>liquibase-core</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-data-jpa</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-jdbc</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-test</artifactId>
        </dependency>

        <dependency>
            <groupId>org.postgresql</groupId>
            <artifactId>postgresql</artifactId>
        </dependency>

        <dependency>
            <groupId>com.sun.xml.ws</groupId>
            <artifactId>rt</artifactId>
        </dependency>

        <dependency>
            <groupId>net.n2oapp.platform</groupId>
            <artifactId>n2o-platform-starter-jwt</artifactId>
        </dependency>

        <dependency>
            <groupId>ru.i-novus.ms.audit</groupId>
            <artifactId>audit-client-spring-boot-starter</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-activemq</artifactId>
        </dependency>

        <dependency>
            <groupId>net.n2oapp.platform</groupId>
            <artifactId>n2o-platform-starter-loader-server</artifactId>
        </dependency>

        <!-- fix NoClassDefFoundError for CommonsMultipartResolver -->
        <dependency>
            <groupId>commons-fileupload</groupId>
            <artifactId>commons-fileupload</artifactId>
            <version>${commons.fileupload.version}</version>
        </dependency>
        <!-- / fix NoClassDefFoundError for CommonsMultipartResolver -->

        <!-- test -->
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-core</artifactId>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>net.n2oapp.platform</groupId>
            <artifactId>n2o-platform-starter-jaxrs-client</artifactId>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.apache.activemq</groupId>
            <artifactId>activemq-kahadb-store</artifactId>
            <version>5.15.13</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>net.n2oapp.platform</groupId>
            <artifactId>n2o-platform-starter-test</artifactId>
            <scope>test</scope>
        </dependency>
        <!-- / test -->

    </dependencies>

    <build>
        <finalName>rdm-rest</finalName>
    </build>

    <profiles>
        <profile>
            <id>production</id>
            <properties>
                <backend.default.port>8080</backend.default.port>
            </properties>
            <activation>
                <activeByDefault>false</activeByDefault>
            </activation>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.springframework.boot</groupId>
                        <artifactId>spring-boot-maven-plugin</artifactId>
                        <configuration>
                            <executable>true</executable>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>

        <profile>
            <id>external-tracing-tool</id>
            <activation>
                <activeByDefault>false</activeByDefault>
            </activation>

            <dependencies>
                <dependency>
                    <groupId>org.springframework.cloud</groupId>
                    <artifactId>spring-cloud-sleuth-zipkin</artifactId>
                </dependency>
            </dependencies>
        </profile>

        <profile>
            <id>l10n</id>
            <activation>
                <activeByDefault>false</activeByDefault>
            </activation>

            <dependencies>
                <dependency>
                    <groupId>ru.i-novus.components</groupId>
                    <artifactId>l10n-versioned-data-storage-pg-impl</artifactId>
                </dependency>

                <dependency>
                    <groupId>ru.i-novus.ms.rdm</groupId>
                    <artifactId>rdm-l10n-api</artifactId>
                </dependency>

                <dependency>
                    <groupId>ru.i-novus.ms.rdm</groupId>
                    <artifactId>rdm-l10n-impl</artifactId>
                </dependency>
            </dependencies>
        </profile>
    </profiles>

</project>