<?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 -->
  <parent>
    <groupId>io.stargate</groupId>
    <artifactId>stargate</artifactId>
    <version>2.0.51</version>
  </parent>
  <!-- Artifact props -->
  <groupId>io.stargate.graphql</groupId>
  <artifactId>graphqlapi</artifactId>
  <name>Stargate - Coordinator - Graphql API (deprecated)</name>
  <properties>
    <osgi.bundle.version>${project.version}</osgi.bundle.version>
  </properties>
  <dependencies>
    <!-- Stargate component dependencies -->
    <dependency>
      <groupId>io.stargate.db</groupId>
      <artifactId>persistence-api</artifactId>
      <version>${project.version}</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>io.stargate.auth</groupId>
      <artifactId>authnz</artifactId>
      <version>${project.version}</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>io.stargate.core</groupId>
      <artifactId>core</artifactId>
      <version>${project.version}</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>io.stargate.metrics</groupId>
      <artifactId>metrics-jersey</artifactId>
      <version>${project.version}</version>
    </dependency>
    <!-- 3rd party dependencies -->
    <dependency>
      <groupId>io.dropwizard.metrics</groupId>
      <artifactId>metrics-servlet</artifactId>
    </dependency>
    <dependency>
      <groupId>com.datastax.oss</groupId>
      <artifactId>java-driver-shaded-guava</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>com.graphql-java</groupId>
      <artifactId>graphql-java</artifactId>
      <version>18.5</version>
    </dependency>
    <dependency>
      <groupId>io.dropwizard</groupId>
      <artifactId>dropwizard-jersey</artifactId>
    </dependency>
    <dependency>
      <groupId>io.dropwizard</groupId>
      <artifactId>dropwizard-core</artifactId>
      <exclusions>
        <exclusion>
          <groupId>io.dropwizard.metrics</groupId>
          <artifactId>metrics-healthchecks</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>io.dropwizard</groupId>
      <artifactId>dropwizard-forms</artifactId>
    </dependency>
    <dependency>
      <groupId>io.dropwizard.metrics</groupId>
      <artifactId>metrics-healthchecks</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>javax.servlet</groupId>
      <artifactId>javax.servlet-api</artifactId>
    </dependency>
    <dependency>
      <groupId>org.eclipse.jetty</groupId>
      <artifactId>jetty-server</artifactId>
    </dependency>
    <dependency>
      <groupId>org.eclipse.jetty</groupId>
      <artifactId>jetty-util</artifactId>
    </dependency>
    <dependency>
      <groupId>org.eclipse.jetty</groupId>
      <artifactId>jetty-http</artifactId>
    </dependency>
    <dependency>
      <groupId>org.eclipse.jetty</groupId>
      <artifactId>jetty-io</artifactId>
    </dependency>
    <dependency>
      <groupId>org.eclipse.jetty</groupId>
      <artifactId>jetty-servlet</artifactId>
    </dependency>
    <dependency>
      <groupId>org.eclipse.jetty</groupId>
      <artifactId>jetty-servlets</artifactId>
    </dependency>
    <dependency>
      <groupId>org.javassist</groupId>
      <artifactId>javassist</artifactId>
      <version>3.27.0-GA</version>
    </dependency>
    <dependency>
      <groupId>io.jsonwebtoken</groupId>
      <artifactId>jjwt</artifactId>
      <version>0.9.1</version>
    </dependency>
    <dependency>
      <groupId>com.apollographql.federation</groupId>
      <artifactId>federation-graphql-java-support</artifactId>
      <version>2.0.3</version>
    </dependency>
    <!-- Test dependencies -->
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-inline</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-junit-jupiter</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.assertj</groupId>
      <artifactId>assertj-core</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>
  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.felix</groupId>
        <artifactId>maven-bundle-plugin</artifactId>
        <configuration>
          <unpackBundle>true</unpackBundle>
          <instructions>
            <Bundle-Name>GraphqlAPI</Bundle-Name>
            <Bundle-Description>Graphql API for Stargate project</Bundle-Description>
            <Bundle-SymbolicName>io.stargate.graphql</Bundle-SymbolicName>
            <Bundle-Activator>io.stargate.graphql.GraphqlActivator</Bundle-Activator>
            <Embed-Transitive>true</Embed-Transitive>
            <Import-Package><![CDATA[
                            org.slf4j,
                            org.slf4j.helpers,
                            org.slf4j.spi,
                            org.osgi.framework,
                            io.stargate.db.*,
                            org.apache.cassandra.stargate,
                            org.apache.cassandra.stargate.*,
                            com.datastax.oss.driver.api.core,
                            com.datastax.oss.driver.api.core.*,
                            org.javatuples,
                            io.stargate.core.*,
                            io.stargate.auth,
                            io.stargate.auth.*,
                            com.codahale.metrics,
                            com.codahale.metrics.*,
                            io.micrometer.core.*,
                            com.datastax.oss.driver.shaded.guava.common.*,
                        ]]></Import-Package>
            <Export-Package>!*</Export-Package>
            <Embed-Dependency>*;scope=compile|runtime</Embed-Dependency>
          </instructions>
          <buildDirectory>${project.basedir}/../stargate-lib</buildDirectory>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-jar-plugin</artifactId>
        <configuration>
          <archive>
            <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
            <manifestEntries>
              <x-Stargate-Health-Checkers>graphql</x-Stargate-Health-Checkers>
            </manifestEntries>
          </archive>
          <outputDirectory>${project.basedir}/../stargate-lib</outputDirectory>
        </configuration>
      </plugin>
    </plugins>
  </build>
</project>
