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

    Copyright 2010-2016 OrientDB LTD (http://orientdb.com)

    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.

    For more information: http://www.orientdb.com

-->
<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>com.orientechnologies</groupId>
        <artifactId>orientdb-parent</artifactId>
        <version>3.0.0RC2</version>
        <relativePath/>
    </parent>

    <artifactId>orientdb-spatial</artifactId>

    <packaging>jar</packaging>

    <properties>
        <orientdb.version>${project.parent.version}</orientdb.version>
        <lucene.version>6.6.1</lucene.version>
        <geotools.version>13.2</geotools.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <argLine>-ea -Xmx2048m -XX:MaxDirectMemorySize=512g -Dstorage.diskCache.bufferSize=4096 -Dindex.flushAfterCreate=false
            -Dstorage.makeFullCheckpointAfterCreate=false
            -Dstorage.makeFullCheckpointAfterClusterCreate=false -Dstorage.wal.syncOnPageFlush=false
            -Dstorage.configuration.syncOnUpdate=false
            -Dmemory.directMemory.trackMode=true
            -Djava.util.logging.manager=com.orientechnologies.common.log.OLogManager$DebugLogManager
            -Dstorage.diskCache.checksumMode=storeAndThrow
        </argLine>

        <!--Overrides parent pom's location-->
        <license.location>https://github.com/orientechnologies/orientdb/raw/develop/ODB-ASL-LICENSE.txt</license.location>

    </properties>

    <name>OrientDB Lucene spatial index</name>
    <description>Lucene plugin for OrientDB NoSQL document graph dbms</description>
    <url>http://maven.apache.org</url>
    <inceptionYear>2013</inceptionYear>

    <build>
        <plugins>
            <plugin>
                <groupId>org.jacoco</groupId>
                <artifactId>jacoco-maven-plugin</artifactId>
                <configuration>
                    <destFile>${project.basedir}/target/jacoco.exec</destFile>
                    <dataFile>${project.basedir}/target/jacoco.exec</dataFile>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-assembly-plugin</artifactId>
                <configuration>
                    <descriptors>
                        <descriptor>src/main/assembly/assembly.xml</descriptor>
                    </descriptors>
                </configuration>
                <executions>
                    <execution>
                        <id>make-assembly</id>
                        <!-- this is used for inheritance merges -->
                        <phase>package</phase>
                        <!-- bind to the packaging phase -->
                        <goals>
                            <goal>single</goal>
                        </goals>
                        <configuration></configuration>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <configuration>
                    <mavenExecutorId>forked-path</mavenExecutorId>
                    <useReleaseProfile>false</useReleaseProfile>
                    <localCheckout>true</localCheckout>
                    <pushChanges>false</pushChanges>
                    <allowTimestampedSnapshots>true</allowTimestampedSnapshots>
                    <arguments>-Prelease</arguments>
                </configuration>
            </plugin>

            <plugin>
                <groupId>com.spotify</groupId>
                <artifactId>docker-maven-plugin</artifactId>
                <version>0.4.13</version>
                <configuration>
                    <imageName>orientdb/orientdb-spatial</imageName>
                    <imageTags>
                        <imageTag>${project.version}</imageTag>
                    </imageTags>
                    <dockerDirectory>docker</dockerDirectory>
                    <!-- copy the service's jar file from target into the root directory of the image -->
                    <resources>
                        <resource>
                            <targetPath>/</targetPath>
                            <directory>${project.build.directory}/</directory>
                            <include>${project.build.finalName}-dist.jar</include>
                        </resource>
                    </resources>
                </configuration>
            </plugin>

            <plugin>
                <groupId>com.mycila</groupId>
                <artifactId>license-maven-plugin</artifactId>
                <configuration>
                    <header>https://github.com/orientechnologies/orientdb/raw/develop/ODB-ASL-LICENSE.txt</header>
                    <strictCheck>true</strictCheck>
                </configuration>
            </plugin>
        </plugins>
    </build>

    <repositories>
        <repository>
            <id>osgeo</id>
            <name>Open Source Geospatial Foundation Repository</name>
            <url>http://download.osgeo.org/webdav/geotools/</url>
        </repository>
    </repositories>
    
    <dependencies>

        <dependency>
            <groupId>com.orientechnologies</groupId>
            <artifactId>orientdb-test-commons</artifactId>
            <version>${orientdb.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.orientechnologies</groupId>
            <artifactId>orientdb-lucene</artifactId>
            <version>${orientdb.version}</version>
            <type>test-jar</type>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.orientechnologies</groupId>
            <artifactId>orientdb-core</artifactId>
            <version>${project.version}</version>
            <type>test-jar</type>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.apache.lucene</groupId>
            <artifactId>lucene-spatial</artifactId>
            <version>${lucene.version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.lucene</groupId>
            <artifactId>lucene-spatial-extras</artifactId>
            <version>${lucene.version}</version>
        </dependency>


        <dependency>
            <groupId>org.noggit</groupId>
            <artifactId>noggit</artifactId>
            <version>0.8</version>
        </dependency>
        <dependency>
            <groupId>com.vividsolutions</groupId>
            <artifactId>jts</artifactId>
            <version>1.13</version>
        </dependency>


        <dependency>
            <groupId>com.orientechnologies</groupId>
            <artifactId>orientdb-lucene</artifactId>
            <version>${orientdb.version}</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>com.google.code.gson</groupId>
            <artifactId>gson</artifactId>
            <version>2.2.4</version>
            <scope>test</scope>
        </dependency>

    </dependencies>
</project>
