<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

    <parent>
        <groupId>net.spals.appbuilder</groupId>
        <artifactId>spals-appbuilder-parent</artifactId>
        <version>0.6.0</version>
    </parent>

    <modelVersion>4.0.0</modelVersion>
    <groupId>net.spals.appbuilder</groupId>
    <artifactId>spals-appbuilder-app-examples</artifactId>
    <version>0.6.0</version>
    <packaging>jar</packaging>

    <dependencies>
        <dependency>
            <groupId>com.google.protobuf</groupId>
            <artifactId>protobuf-java</artifactId>
        </dependency>
        <dependency>
            <groupId>com.xorlev.grpc-jersey</groupId>
            <artifactId>jersey-rpc-support</artifactId>
        </dependency>
        <!-- Include mock opentracing to support functional testing. -->
        <dependency>
            <groupId>io.opentracing</groupId>
            <artifactId>opentracing-mock</artifactId>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder</groupId>
            <artifactId>spals-appbuilder-executor-core</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder</groupId>
            <artifactId>spals-appbuilder-filestore-core</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder</groupId>
            <artifactId>spals-appbuilder-keystore-core</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder</groupId>
            <artifactId>spals-appbuilder-mapstore-core</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder</groupId>
            <artifactId>spals-appbuilder-message-core</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder</groupId>
            <artifactId>spals-appbuilder-model-core</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-app-dropwizard</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-app-finatra</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-app-grpc</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-filestore-s3</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-mapstore-cassandra</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-mapstore-dynamodb</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-mapstore-mongodb</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-message-kafka</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-message-kinesis</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-model-protobuf</artifactId>
        </dependency>
        <dependency>
            <groupId>net.spals.appbuilder.plugins</groupId>
            <artifactId>spals-appbuilder-monitor-lightstep</artifactId>
        </dependency>
        <!-- Include mockito to support functional testing. -->
        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-core</artifactId>
            <scope>compile</scope>
        </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>org.xolstice.maven.plugins</groupId>
                <artifactId>protobuf-maven-plugin</artifactId>
                <configuration>
                    <protocArtifact>com.google.protobuf:protoc:${protobuf.version}:exe:${os.detected.classifier}</protocArtifact>
                    <outputDirectory>target/generated-sources</outputDirectory>
                    <clearOutputDirectory>false</clearOutputDirectory>
                </configuration>
                <executions>
                    <execution>
                        <id>generate-protobuf-java</id>
                        <goals>
                            <goal>compile</goal>
                        </goals>
                    </execution>
                    <execution>
                        <id>generate-protobuf-grpc-java</id>
                        <goals>
                            <goal>compile-custom</goal>
                        </goals>
                        <configuration>
                            <pluginId>grpc-java</pluginId>
                            <pluginArtifact>
                                io.grpc:protoc-gen-grpc-java:${grpc.version}:exe:${os.detected.classifier}
                            </pluginArtifact>
                        </configuration>
                    </execution>
                    <execution>
                        <id>generate-protobuf-grpc-jersey</id>
                        <goals>
                            <goal>compile-custom</goal>
                        </goals>
                        <configuration>
                            <pluginId>grpc-jersey</pluginId>
                            <pluginArtifact>com.xorlev.grpc-jersey:protoc-gen-jersey:${grpc.jersey.version}:exe:${os.detected.classifier}</pluginArtifact>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

</project>
