<?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/maven-v4_0_0.xsd">

    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>ru.entaxy.esb.system</groupId>
        <artifactId>management</artifactId>
        <version>1.8.0</version>
        <relativePath>../pom.xml</relativePath>
    </parent>

    <groupId>ru.entaxy.esb.system.management</groupId>
    <artifactId>system-management-api</artifactId>
    <packaging>bundle</packaging>

    <name>SYSTEM :: ENTAXY :: SYSTEM :: MANAGEMENT :: API</name>
    <description>SYSTEM :: ENTAXY :: SYSTEM :: MANAGEMENT :: API</description>

    <properties>
        <bundle.osgi.import.pkg>
            !com.sun.org.apache.xml.internal.dtm.ref,
            !org.mapstruct.*,
            javax.jws.*;version="[2.0.0,3.0.0)",
            javax.jws.soap.*;version="[2.0.0,3.0.0)",
            javax.xml.ws.*;version="[2.2.0,3.0.0)",
            ru.entaxy.esb.system.management.permission.manager.*,
            ru.entaxy.esb.system.management.profile.manager.*,
            ru.entaxy.esb.system.management.connector.manager.*,
            ru.entaxy.esb.system.management.bridge.profile.manager.*,
            ru.entaxy.esb.system.management.bundle.jpa.dto,
            org.apache.commons.logging,
            org.osgi.service.blueprint;version="[1.0.0,2.0.0)",
            javax.xml.bind;version="[2,3)",
            javax.xml.bind.annotation;version="[2,3)",
            *
        </bundle.osgi.import.pkg>
    </properties>

    <dependencies>
        <dependency>
            <groupId>javax.interceptor</groupId>
            <artifactId>javax.interceptor-api</artifactId>
            <version>${javax.interceptor.version}</version>
        </dependency>
        <dependency>
            <groupId>org.mapstruct</groupId>
            <artifactId>mapstruct</artifactId>
            <version>${mapstruct.version}</version>
        </dependency>
        <dependency>
            <groupId>org.mapstruct</groupId>
            <artifactId>mapstruct-processor</artifactId>
            <version>${mapstruct.version}</version>
        </dependency>
        <dependency>
            <groupId>ru.entaxy.esb.system.management.profile.manager</groupId>
            <artifactId>profile-manager</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>ru.entaxy.esb.system.management.connector.manager</groupId>
            <artifactId>connector-manager</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>ru.entaxy.esb.system.management.bridge.profile.manager</groupId>
            <artifactId>bridge-profile-manager</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>ru.entaxy.esb.system.management.permission.manager</groupId>
            <artifactId>permission-manager</artifactId>
            <version>${project.version}</version>
        </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.8.0</version>
                <configuration>
                    <release>11</release>
                    <annotationProcessorPaths>
                        <path>
                            <groupId>org.mapstruct</groupId>
                            <artifactId>mapstruct-processor</artifactId>
                            <version>${mapstruct.version}</version>
                        </path>
                    </annotationProcessorPaths>
                </configuration>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>dev</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.cxf</groupId>
                        <artifactId>cxf-codegen-plugin</artifactId>
                        <version>${cxf.version}</version>
                        <executions>
                            <execution>
                                <id>generate-sources</id>
                                <phase>generate-sources</phase>
                                <configuration>
                                    <sourceRoot>src/main/java</sourceRoot>
                                    <wsdlOptions>
                                        <wsdlOption>
                                            <wsdl>${basedir}/src/main/resources/wsdl/system-management-service.wsdl
                                            </wsdl>
                                            <extraargs>
                                                <extraarg>-p</extraarg>
                                                <extraarg>ru.entaxy.esb.system.management.soap</extraarg>
                                                <extraarg>-bareMethods</extraarg>
                                            </extraargs>
                                            <extendedSoapHeaders>true</extendedSoapHeaders>
                                        </wsdlOption>
                                    </wsdlOptions>
                                </configuration>
                                <goals>
                                    <goal>wsdl2java</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>