| POM文件内容: |
<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>org.cassandraunit</groupId>
<artifactId>cassandra-unit-parent</artifactId>
<version>3.0.0.1</version>
</parent>
<groupId>org.cassandraunit</groupId>
<artifactId>cassandra-unit</artifactId>
<packaging>jar</packaging>
<name>cassandra-unit</name>
<description>Test framework to develop with Cassandra</description>
<properties>
<shade.prefix>org.cassandraunit.shaded</shade.prefix>
</properties>
<build>
<resources>
<resource>
<directory>src/main/resources</directory>
</resource>
<resource>
<directory>src/main/xsd</directory>
<includes>
<include>**/*.xsd</include>
</includes>
</resource>
</resources>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jaxb2-maven-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<goals>
<goal>xjc</goal>
</goals>
<configuration>
<arguments>-enableIntrospection</arguments>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-xjc</artifactId>
<version>2.1.13</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.2.2</version>
<executions>
<execution>
<id>make-assembly</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<!-- The configuration of the plugin -->
<configuration>
<!-- Specifies the configuration file of the assembly plugin -->
<descriptors>
<descriptor>src/main/assembly/assembly.xml</descriptor>
</descriptors>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>2.3</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<shadedArtifactAttached>true</shadedArtifactAttached>
<minimizeJar>false</minimizeJar>
<dependencyReducedPomLocation>${basedir}/target/dependency-reduced-pom.xml</dependencyReducedPomLocation>
<artifactSet>
<includes>
<!-- included only to suppress dependency, not relocated -->
<include>org.cassandraunit:cassandra-unit</include>
<!-- included due to relocated sub-dependencies, but itself not relocated because Class.forName -->
<include>org.apache.cassandra:cassandra-all</include>
<!-- included and relocated due to clash between hector and cassandra itself -->
<include>org.apache.cassandra:cassandra-thrift</include>
<!-- included and relocated due to potential clashes, especially guava -->
<include>com.google.guava:guava</include>
<include>org.antlr:*</include>
<include>org.codehaus.jackson:*</include>
<include>com.yammer.metrics:metrics-core</include>
<include>com.addthis.metrics:*</include>
<include>io.netty:*</include>
</includes>
</artifactSet>
<relocations>
<relocation>
<pattern>org.apache.cassandra.thrift</pattern>
<shadedPattern>${shade.prefix}.org.apache.cassandra.thrift</shadedPattern>
</relocation>
<relocation><!-- guava. With Trailing dot else com.googlecode would also match -->
<pattern>com.google.</pattern>
<shadedPattern>${shade.prefix}.com.google.</shadedPattern>
</relocation>
<relocation>
<pattern>org.antlr</pattern>
<shadedPattern>${shade.prefix}.org.antlr</shadedPattern>
</relocation>
<relocation>
<pattern>org.codehaus.jackson</pattern>
<shadedPattern>${shade.prefix}.org.codehaus.jackson</shadedPattern>
</relocation>
<relocation>
<pattern>com.yammer.metrics</pattern>
<shadedPattern>${shade.prefix}.com.yammer.metrics</shadedPattern>
</relocation>
<relocation>
<pattern>com.addthis.metrics</pattern>
<shadedPattern>${shade.prefix}.com.addthis.metrics</shadedPattern>
</relocation>
<relocation>
<pattern>io.netty</pattern>
<shadedPattern>${shade.prefix}.io.netty</shadedPattern>
</relocation>
</relocations>
<transformers>
<transformer implementation="org.apache.maven.plugins.shade.resource.ApacheLicenseResourceTransformer">
</transformer>
<transformer implementation="org.apache.maven.plugins.shade.resource.ApacheNoticeResourceTransformer">
<addHeader>false</addHeader>
</transformer>
</transformers>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>${cu.junit.version}</version>
</dependency>
<dependency>
<groupId>org.apache.cassandra</groupId>
<artifactId>cassandra-all</artifactId>
<version>${cu.cassandra.all.version}</version>
<exclusions>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>log4j-over-slf4j</artifactId>
</exclusion>
<exclusion>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
</exclusion>
<exclusion>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-core</artifactId>
</exclusion>
<exclusion>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
</exclusion>
<exclusion>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpcore</artifactId>
</exclusion>
<exclusion>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
</exclusion>
<exclusion> <!-- ST4 and stringtemplate seem to contain the same classes... ST4 is newer -->
<groupId>org.antlr</groupId>
<artifactId>stringtemplate</artifactId>
</exclusion>
<exclusion> <!-- is this used at all? -->
<groupId>org.hibernate</groupId>
<artifactId>hibernate-validator</artifactId>
</exclusion>
<exclusion>
<groupId>io.netty</groupId>
<artifactId>netty-all</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency> <!-- for cassandra-all because maven fails to reliably resolve the conflict with cassandra-driver-core -->
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>18.0</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>3.4</version>
</dependency>
<dependency>
<groupId>io.netty</groupId>
<artifactId>netty-handler</artifactId>
<version>4.0.27.Final</version>
</dependency>
<!-- hamcrest could be moved to the test-scope. But as the examples do not declare hamcrest-deps in their pom,
better leave them in compile-scope -->
<dependency> <!-- dont mix self-contained hamcrest-all and hamcrest-submodules -->
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-core</artifactId>
<version>${cu.hamcrest.version}</version>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-library</artifactId>
<version>${cu.hamcrest.version}</version>
</dependency>
<!-- optional clients. The app defines which one to use and in which version -->
<dependency>
<groupId>org.hectorclient</groupId>
<artifactId>hector-core</artifactId>
<version>${cu.hector.version}</version>
<optional>true</optional>
<exclusions>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.datastax.cassandra</groupId>
<artifactId>cassandra-driver-core</artifactId>
<version>${cu.cassandra.driver.version}</version>
<optional>true</optional>
</dependency>
<!-- test -->
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<version>1.10.19</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.4</version>
<scope>test</scope>
</dependency>
<!-- log -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>${cu.slf4j.version}</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<version>${cu.slf4j.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
<version>${cu.slf4j.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.17</version>
<scope>test</scope>
</dependency>
</dependencies>
</project>
|