<?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>xyz.tcheeric</groupId>
        <artifactId>cashu-ledger</artifactId>
        <version>0.7.2</version>
    </parent>

    <artifactId>cashu-ledger-trace-publisher</artifactId>
    <packaging>jar</packaging>
    <name>Cashu Ledger Trace Publisher</name>
    <description>
        Embeddable producer SDK for transaction traceability: builds, signs, and
        asynchronously delivers kind-9079 trace events through a durable outbox.
        Depends only on cashu-ledger-trace-core (+ nostr-java for signing/publishing);
        no dependency on cashu-ledger-core.
    </description>

    <dependencies>
        <dependency>
            <groupId>xyz.tcheeric</groupId>
            <artifactId>cashu-ledger-trace-core</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>org.xerial</groupId>
            <artifactId>sqlite-jdbc</artifactId>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-databind</artifactId>
        </dependency>
        <!-- Schnorr signing + hex utils (nostr-java 2.x core module) -->
        <dependency>
            <groupId>xyz.tcheeric</groupId>
            <artifactId>nostr-java-core</artifactId>
        </dependency>
        <!-- Relay transport for the default RelayPublisher -->
        <dependency>
            <groupId>xyz.tcheeric</groupId>
            <artifactId>nostr-java-client</artifactId>
        </dependency>

        <!-- Optional: Spring Boot starter autoconfiguration (only used when present) -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-autoconfigure</artifactId>
            <optional>true</optional>
        </dependency>
        <!-- Optional: Micrometer, for the outbox-depth and publish-attempt
             meters the spec-048 alert rules match on. Optional and guarded by
             @ConditionalOnClass so a non-Spring or non-actuator consumer is
             unaffected, exactly like the OpenTelemetry decorator below. -->
        <dependency>
            <groupId>io.micrometer</groupId>
            <artifactId>micrometer-core</artifactId>
            <optional>true</optional>
        </dependency>
        <!-- Optional: OpenTelemetry tracing decorator (only used when present) -->
        <dependency>
            <groupId>io.opentelemetry</groupId>
            <artifactId>opentelemetry-api</artifactId>
            <version>${opentelemetry.version}</version>
            <optional>true</optional>
        </dependency>

        <!-- Test -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-test</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>io.opentelemetry</groupId>
            <artifactId>opentelemetry-sdk-testing</artifactId>
            <version>${opentelemetry.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.assertj</groupId>
            <artifactId>assertj-core</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-junit-jupiter</artifactId>
            <scope>test</scope>
        </dependency>
    </dependencies>
</project>
