<?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>org.kaazing</groupId>
        <artifactId>gateway</artifactId>
        <version>5.2.2</version>
    </parent>

    <artifactId>gateway.management</artifactId>
    <name>Kaazing WebSocket Gateway - Management</name>
    <description>Gateway Management using JMX, SNMP</description>

    <url>https://github.com/kaazing/gateway.management.git</url>
    <scm>
        <connection>scm:git:${project.scm.url}</connection>
        <developerConnection>scm:git:${project.scm.url}</developerConnection>
        <url>git@github.com:kaazing/gateway.management.git</url>
    </scm>

    <dependencyManagement>
        <dependencies>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>sigar.dist</artifactId>
            <version>1.0.0.0</version>
            <type>jar</type>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>sigar.dist</artifactId>
            <classifier>distribution</classifier>
            <type>zip</type>
            <version>1.0.0.0</version>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>snmp4j</artifactId>
            <version>1.11.3</version>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>snmp4j-agent</artifactId>
            <version>1.4.3</version>
        </dependency>

        </dependencies>
    </dependencyManagement>

    <dependencies>
        <!-- Because we depend on gateway.server, a ton of other dependencies 
            come in transitively -->
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.server</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.service</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.service.proxy</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.service.http.balancer</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.transport.ws</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.transport.wsn</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.transport.wseb</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.xmlbeans</groupId>
            <artifactId>xmlbeans</artifactId>
            <version>2.4.0</version>
        </dependency>
        <dependency>
            <groupId>org.json</groupId>
            <artifactId>json</artifactId>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.service.update.check</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.resource.address.httpxe</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.resource.address.wsxdraft</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.resource.address.wsn</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.resource.address.httpxdraft</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.resource.address.wsx</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.resource.address.httpx</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
        </dependency>
        <dependency>
            <groupId>org.jmock</groupId>
            <artifactId>jmock</artifactId>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>sigar.dist</artifactId>
            <type>jar</type>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>snmp4j</artifactId>
        </dependency>
        <dependency>
            <groupId>uk.co.real-logic</groupId>
            <artifactId>Agrona</artifactId>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>snmp4j-agent</artifactId>
        </dependency>
        <dependency>
            <groupId>org.jmock</groupId>
            <artifactId>jmock-legacy</artifactId>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.test.ca</artifactId>
            <version>1.0.0.24</version>
            <classifier>keystore</classifier>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.kaazing</groupId>
            <artifactId>gateway.service.echo</artifactId>
            <version>${project.version}</version>
        </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>org.kaazing</groupId>
                <artifactId>license-maven-plugin</artifactId>
                <configuration>
                    <projectHints>
                        <projectDescription>
                            <projectName>Java Native Access</projectName>
                            <licenseName>LGPL</licenseName>
                            <licenseUrl>http://www.gnu.org/licenses/licenses.html</licenseUrl>
                            <homePage>https://github.com/twall/jna</homePage>
                            <version>2.1</version>
                        </projectDescription>
                        <projectDescription>
                            <projectName>JDOM</projectName>
                            <licenseName>JDOM License</licenseName>
                            <licenseUrl>https://github.com/hunterhacker/jdom/blob/master/LICENSE.txt</licenseUrl>
                            <homePage>http://jdom.org</homePage>
                            <version>1.1</version>
                        </projectDescription>
                        <projectDescription>
                            <projectName>cglib</projectName>
                            <licenseName />
                            <version>2.0</version>
                        </projectDescription>
                    </projectHints>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-checkstyle-plugin</artifactId>
                <version>2.11</version>
                <executions>
                    <execution>
                        <id>validate</id>
                        <phase>validate</phase>
                        <configuration>
                            <encoding>UTF-8</encoding>
                            <!-- checkstyle doesn't like lambdas and· exceptions 
                                and bails -->
                            <consoleOutput>true</consoleOutput>
                            <failsOnError>true</failsOnError>
                            <failOnViolation>true</failOnViolation>
                        </configuration>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>org.kaazing</groupId>
                        <artifactId>code.quality</artifactId>
                        <version>1.1</version>
                    </dependency>
                </dependencies>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>cobertura-maven-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>xmlbeans-maven-plugin</artifactId>
                <version>2.3.3</version>
                <configuration>
                    <verbose>true</verbose>
                    <quiet>false</quiet>
                    <debug>${xmlbeans.debug}</debug>
                </configuration>
                <executions>
                    <execution>
                        <goals>
                            <goal>xmlbeans</goal>
                        </goals>
                    </execution>
                </executions>
                <inherited>true</inherited>
            </plugin>
            
            <plugin>
                <artifactId>maven-failsafe-plugin</artifactId>
                <executions>
                    <execution>
                        <configuration>
                            <argLine>@{failsafeArgLine}</argLine>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <version>2.8</version>
                <executions>
                    <execution>
                        <id>unpack-truststore</id>
                        <phase>generate-resources</phase>
                        <goals>
                            <goal>unpack-dependencies</goal>
                        </goals>
                        <configuration>
                            <includeArtifactIds>gateway.test.ca</includeArtifactIds>
                            <outputDirectory>${basedir}/target/truststore</outputDirectory>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
        <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.apache.maven.plugins
                                        </groupId>
                                        <artifactId>
                                            maven-dependency-plugin
                                        </artifactId>
                                        <versionRange>
                                            [2.0,)
                                        </versionRange>
                                        <goals>
                                            <goal>unpack</goal>
                                        </goals>
                                    </pluginExecutionFilter>
                                    <action>
                                        <ignore />
                                    </action>
                                </pluginExecution>
                            </pluginExecutions>
                        </lifecycleMappingMetadata>
                    </configuration>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>

    <reporting>
        <plugins>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>cobertura-maven-plugin</artifactId>
                <version>2.2</version>
            </plugin>
        </plugins>
    </reporting>

    <properties>
        <failsafeArgLine>-Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false -Djava.rmi.server.hostname=localhost -Djava.library.path=target/sigar -Djavax.net.ssl.truststore=${project.basedir}/target/truststore/truststore.db</failsafeArgLine>
        <xmlbeans.debug>false</xmlbeans.debug>
        <checkstyle.config.location>org/kaazing/code/quality/checkstyle.xml</checkstyle.config.location>
    </properties>
</project>
