<?xml version="1.0" encoding="UTF-8"?>
<!--

    Copyright (C) 2017 Red Hat, Inc.

    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

            http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.

-->
<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>io.atlasmap</groupId>
        <artifactId>atlas-service-parent</artifactId>
        <version>1.31.1</version>
        <relativePath>../pom.xml</relativePath>
    </parent>

    <artifactId>atlas-service</artifactId>
    <name>Atlas :: Service</name>
    <packaging>bundle</packaging>

    <dependencies>
        <dependency>
            <groupId>io.atlasmap</groupId>
            <artifactId>atlas-model</artifactId>
        </dependency>
        <dependency>
            <groupId>io.atlasmap</groupId>
            <artifactId>atlas-core</artifactId>
        </dependency>
        <dependency>
            <groupId>io.atlasmap</groupId>
            <artifactId>atlas-java-model</artifactId>
        </dependency>
        <dependency>
            <groupId>io.atlasmap</groupId>
            <artifactId>atlas-java-module</artifactId>
        </dependency>
        <dependency>
            <groupId>io.atlasmap</groupId>
            <artifactId>atlas-xml-model</artifactId>
        </dependency>
        <dependency>
            <groupId>io.atlasmap</groupId>
            <artifactId>atlas-json-model</artifactId>
        </dependency>
        <dependency>
            <groupId>org.glassfish.jersey.core</groupId>
            <artifactId>jersey-server</artifactId>
        </dependency>
        <dependency>
            <groupId>org.glassfish.jersey.core</groupId>
            <artifactId>jersey-common</artifactId>
        </dependency>
        <dependency>
            <groupId>org.glassfish.jersey.containers</groupId>
            <artifactId>jersey-container-servlet</artifactId>
        </dependency>
        <dependency>
            <groupId>org.glassfish.jersey.core</groupId>
            <artifactId>jersey-client</artifactId>
        </dependency>
        <dependency>
            <groupId>org.glassfish.jersey.media</groupId>
            <artifactId>jersey-media-json-jackson</artifactId>
         </dependency>
         <dependency>
            <groupId>javax.ws.rs</groupId>
            <artifactId>javax.ws.rs-api</artifactId>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
        </dependency>
    </dependencies>

    <build>
        <defaultGoal>clean site install</defaultGoal>
        <plugins>
            <plugin>
                <groupId>org.eclipse.jetty</groupId>
                <artifactId>jetty-maven-plugin</artifactId>
                <configuration>
                    <useTestScope>true</useTestScope>
                    <scanTargets>
                        <scanTarget>${project.basedir}/src/main</scanTarget>
                    </scanTargets>
                    <scanIntervalSeconds>10</scanIntervalSeconds>
                    <webApp>
                        <contextPath>/</contextPath>
                    </webApp>
                    <jettyXml>src/test/resources/jetty.xml</jettyXml>
                </configuration>
                <dependencies>
                    <dependency>
                        <groupId>javax.ws.rs</groupId>
                        <artifactId>javax.ws.rs-api</artifactId>
                        <version>${javax.ws.rs.version}</version>
                    </dependency>
                </dependencies>
            </plugin>
            <plugin>
                <artifactId>maven-resources-plugin</artifactId>
                <executions>
                    <execution>
                        <id>copy-resources</id>
                        <phase>process-test-resources</phase>
                        <goals>
                            <goal>copy-resources</goal>
                        </goals>
                        <configuration>
                            <outputDirectory>${basedir}/target/mappings</outputDirectory>
                            <resources>
                                <resource>
                                    <directory>src/test/resources/mappings</directory>
                                    <filtering>true</filtering>
                                </resource>
                            </resources>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

</project>
