<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0">
  <modelVersion>4.0.0</modelVersion>
  <groupId>ai.shipeasy</groupId>
  <artifactId>shipeasy</artifactId>
  <version>0.8.0</version>
  <packaging>jar</packaging>
  <name>shipeasy</name>
  <description>Shipeasy server SDK for Java — flags, configs, experiments, metrics.</description>
  <url>https://shipeasy.dev</url>

  <licenses>
    <license><name>MIT</name><url>https://opensource.org/licenses/MIT</url></license>
  </licenses>

  <scm>
    <url>https://github.com/shipeasy-ai/sdk-java</url>
    <connection>scm:git:https://github.com/shipeasy-ai/sdk-java.git</connection>
    <developerConnection>scm:git:ssh://git@github.com/shipeasy-ai/sdk-java.git</developerConnection>
  </scm>

  <developers>
    <developer>
      <id>shipeasy</id>
      <name>Shipeasy</name>
      <email>sdk@shipeasy.ai</email>
      <organization>Shipeasy, Inc.</organization>
      <organizationUrl>https://shipeasy.ai</organizationUrl>
    </developer>
  </developers>

  <properties>
    <maven.compiler.source>11</maven.compiler.source>
    <maven.compiler.target>11</maven.compiler.target>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  </properties>

  <dependencies>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-databind</artifactId>
      <version>2.17.0</version>
    </dependency>
    <!-- For AnonIdFilter only. `provided`: the servlet container supplies it at
         runtime, so it adds nothing to consumers' deployments; non-servlet
         users never load the filter class. -->
    <dependency>
      <groupId>jakarta.servlet</groupId>
      <artifactId>jakarta.servlet-api</artifactId>
      <version>6.0.0</version>
      <scope>provided</scope>
    </dependency>
    <!-- For ShipeasyProvider only (OpenFeature server adapter). `provided`: the
         consuming app that uses OpenFeature supplies the SDK on its own
         classpath, so it adds nothing to non-OpenFeature consumers' deployments
         and the provider class is never loaded unless they opt in. It is still
         on this project's compile + test classpath. -->
    <dependency>
      <groupId>dev.openfeature</groupId>
      <artifactId>sdk</artifactId>
      <version>1.13.0</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter</artifactId>
      <version>5.10.0</version>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <version>3.2.5</version>
      </plugin>
    </plugins>
  </build>

  <profiles>
    <profile>
      <id>release</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <version>3.3.0</version>
            <executions><execution><id>attach-sources</id><goals><goal>jar-no-fork</goal></goals></execution></executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-javadoc-plugin</artifactId>
            <version>3.6.3</version>
            <executions><execution><id>attach-javadocs</id><goals><goal>jar</goal></goals></execution></executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <version>3.2.4</version>
            <executions><execution><id>sign-artifacts</id><phase>verify</phase><goals><goal>sign</goal></goals></execution></executions>
          </plugin>
          <plugin>
            <groupId>org.sonatype.central</groupId>
            <artifactId>central-publishing-maven-plugin</artifactId>
            <!-- 0.5.0 choked parsing the Central Portal status response after
                 upload (Unrecognized field "warnings"); 0.11.0 tracks the
                 current API. The artifact uploads fine on either; this fixes the
                 wait-until-published poll. -->
            <version>0.11.0</version>
            <extensions>true</extensions>
            <configuration>
              <publishingServerId>central</publishingServerId>
              <autoPublish>true</autoPublish>
              <waitUntil>published</waitUntil>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
