<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements.  See the NOTICE file
distributed with this work for additional information
regarding copyright ownership.  The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License.  You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied.  See the License for the
specific language governing permissions and limitations
under the License.
-->
<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">
	<parent>
		<groupId>org.apache</groupId>
		<artifactId>apache</artifactId>
		<version>20</version>
	</parent>

	<modelVersion>4.0.0</modelVersion>

	<groupId>com.alibaba.ververica</groupId>
    <artifactId>flink-cep</artifactId>
	<version>1.15-vvr-6.0.4</version>
    <name>Flink : Libraries : CEP</name>
    <packaging>jar</packaging>
	<url>https://flink.apache.org</url>
	<inceptionYear>2014</inceptionYear>

	<licenses>
		<license>
			<name>The Apache Software License, Version 2.0</name>
			<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
			<distribution>repo</distribution>
		</license>
	</licenses>

	<scm>
		<url>https://github.com/apache/flink</url>
		<connection>git@github.com:apache/flink.git</connection>
		<developerConnection>scm:git:https://gitbox.apache.org/repos/asf/flink.git</developerConnection>
	</scm>

	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
		<flink.shaded.guava.version>30.1.1-jre-15.0</flink.shaded.guava.version>
		<target.java.version>1.8</target.java.version>
		<maven.compiler.source>${target.java.version}</maven.compiler.source>
		<maven.compiler.target>${target.java.version}</maven.compiler.target>
		<mockito.version>2.21.0</mockito.version>
		<hamcrest.version>1.3</hamcrest.version>
		<assertj.version>3.21.0</assertj.version>
		<testcontainers.version>1.16.2</testcontainers.version>
		<spotless.version>2.4.2</spotless.version>
		<aviator.version>5.3.1</aviator.version>

		<!-- Can be set to any value to reproduce a specific build. -->
		<test.randomization.seed/>
		<test.unit.pattern>**/*Test.*</test.unit.pattern>
	</properties>

	<distributionManagement>
		<repository>
			<id>oss</id>
			<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
		</repository>
		<snapshotRepository>
			<id>oss</id>
			<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
		</snapshotRepository>
	</distributionManagement>

	<dependencies>

        <!-- core dependencies -->

        <dependency>
            <groupId>org.apache.flink</groupId>
            <artifactId>flink-core</artifactId>
            <version>${project.version}</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>org.apache.flink</groupId>
            <artifactId>flink-streaming-java</artifactId>
            <version>${project.version}</version>
            <scope>provided</scope>
        </dependency>

		<dependency>
			<groupId>org.apache.flink</groupId>
			<artifactId>flink-shaded-guava</artifactId>
			<version>${flink.shaded.guava.version}</version>
		</dependency>

		<!-- Aviator -->
		<dependency>
			<groupId>com.googlecode.aviator</groupId>
			<artifactId>aviator</artifactId>
			<version>${aviator.version}</version>
		</dependency>

        <!-- test dependencies -->

		<dependency>
			<groupId>org.apache.flink</groupId>
			<artifactId>flink-core</artifactId>
			<version>${project.version}</version>
			<type>test-jar</type>
			<scope>test</scope>
		</dependency>

        <dependency>
            <groupId>org.apache.flink</groupId>
            <artifactId>flink-test-utils</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>
		<!-- test dependencies -->
		<dependency>
			<groupId>org.assertj</groupId>
			<artifactId>assertj-core</artifactId>
			<scope>test</scope>
			<version>${assertj.version}</version>
		</dependency>

		<dependency>
			<groupId>org.mockito</groupId>
			<artifactId>mockito-core</artifactId>
			<version>${mockito.version}</version>
			<type>jar</type>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.hamcrest</groupId>
			<artifactId>hamcrest-all</artifactId>
			<version>${hamcrest.version}</version>
			<type>jar</type>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.testcontainers</groupId>
			<artifactId>junit-jupiter</artifactId>
			<scope>test</scope>
			<version>${testcontainers.version}</version>
		</dependency>
        
        <dependency>
            <groupId>org.apache.flink</groupId>
            <artifactId>flink-streaming-java</artifactId>
            <version>${project.version}</version>
            <type>test-jar</type>
            <scope>test</scope>
        </dependency>

       <dependency>
            <groupId>org.apache.flink</groupId>
            <artifactId>flink-runtime</artifactId>
            <version>${project.version}</version>
            <type>test-jar</type>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.apache.flink</groupId>
            <artifactId>flink-statebackend-rocksdb</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>
		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>slf4j-api</artifactId>
			<scope>provided</scope>
			<version>1.7.32</version>
		</dependency>
		<dependency>
			<groupId>com.google.code.findbugs</groupId>
			<artifactId>jsr305</artifactId>
			<scope>provided</scope>
			<version>1.3.9</version>
		</dependency>

		<dependency>
			<groupId>org.apache.flink</groupId>
			<artifactId>flink-test-utils-junit</artifactId>
			<version>${project.version}</version>
			<scope>test</scope>
		</dependency>
    </dependencies>

	<profiles>
		<profile>
			<!-- used for SNAPSHOT and regular releases -->
			<id>docs-and-source</id>
			<activation>
				<property>
					<name>docs-and-source</name>
				</property>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-source-plugin</artifactId>
						<version>2.2.1</version><!--$NO-MVN-MAN-VER$-->
						<executions>
							<execution>
								<id>attach-sources</id>
								<goals>
									<goal>jar</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-javadoc-plugin</artifactId>
						<configuration>
							<quiet>true</quiet>
						</configuration>
						<executions>
							<execution>
								<id>attach-javadocs</id>
								<goals>
									<goal>jar</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>

		<profile>
			<id>release</id>
			<activation>
				<property>
					<name>release</name>
				</property>
			</activation>
			<properties>
				<target.java.version>1.8</target.java.version>
			</properties>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-gpg-plugin</artifactId>
						<version>1.4</version>
						<executions>
							<execution>
								<id>sign-artifacts</id>
								<phase>verify</phase>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-enforcer-plugin</artifactId>
						<executions>
							<execution>
								<id>enforce-maven</id>
								<goals>
									<goal>enforce</goal>
								</goals>
								<configuration>
									<rules>
										<requireMavenVersion>
											<!-- maven version must be lower than 3.3. See FLINK-3158 -->
											<version>(,3.3)</version>
										</requireMavenVersion>
										<requireJavaVersion>
											<version>1.8.0</version>
										</requireJavaVersion>
									</rules>
								</configuration>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-javadoc-plugin</artifactId>
						<executions>
							<execution>
								<id>attach-javadocs</id>
								<goals>
									<goal>jar</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
				</plugins>
				<pluginManagement>
					<plugins>
						<plugin>
							<groupId>org.apache.maven.plugins</groupId>
							<artifactId>maven-release-plugin</artifactId>
							<version>2.1</version>
							<configuration>
								<mavenExecutorId>forked-path</mavenExecutorId>
								<useReleaseProfile>false</useReleaseProfile>
								<arguments>${arguments} -Psonatype-oss-release</arguments>
							</configuration>
						</plugin>
					</plugins>
				</pluginManagement>
			</build>
		</profile>
	</profiles>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <executions>
                    <execution>
                        <goals>
                            <goal>test-jar</goal>
                        </goals>
                    </execution>
					<execution>
						<id>default-jar</id>
						<goals>
							<goal>jar</goal>
						</goals>
						<configuration>
							<excludes>
								<exclude>org/apache/flink/cep/dynamic/coordinator</exclude>
								<exclude>org/apache/flink/cep/dynamic/coordinator/*.*</exclude>
							</excludes>
						</configuration>
					</execution>
                </executions>
            </plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-javadoc-plugin</artifactId>
				<version>2.9.1</version><!--$NO-MVN-MAN-VER$-->
				<configuration>
					<quiet>true</quiet>
					<detectOfflineLinks>false</detectOfflineLinks>
					<additionalJOptions combine.children="append">
						<additionalJOption>-Xdoclint:none</additionalJOption>
					</additionalJOptions>
				</configuration>
			</plugin>
        </plugins>
    </build>
</project>
