Set explicit versions for conflicting transitive dependencies Also check if transitive dependencies' versions match - "dependencyConvergence" rule in the enforcer plugin.
Project: http://git-wip-us.apache.org/repos/asf/brooklyn-library/repo Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-library/commit/957087d0 Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-library/tree/957087d0 Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-library/diff/957087d0 Branch: refs/heads/0.7.0-incubating Commit: 957087d0dce2fa4a3acb53757f8372f81f7b3559 Parents: b575ad7 Author: Svetoslav Neykov <[email protected]> Authored: Wed Jun 17 23:57:26 2015 +0300 Committer: Svetoslav Neykov <[email protected]> Committed: Wed Jun 17 23:57:26 2015 +0300 ---------------------------------------------------------------------- examples/webapps/hello-world-sql/pom.xml | 29 +++++++ software/messaging/pom.xml | 110 ++++++++++++++++++++++++++ software/nosql/pom.xml | 37 +++++++++ usage/camp/pom.xml | 14 ++++ 4 files changed, 190 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/brooklyn-library/blob/957087d0/examples/webapps/hello-world-sql/pom.xml ---------------------------------------------------------------------- diff --git a/examples/webapps/hello-world-sql/pom.xml b/examples/webapps/hello-world-sql/pom.xml index cc610a8..11c5251 100644 --- a/examples/webapps/hello-world-sql/pom.xml +++ b/examples/webapps/hello-world-sql/pom.xml @@ -46,11 +46,25 @@ <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-databind</artifactId> <version>${fasterxml.jackson.version}</version> + <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>com.fasterxml.jackson.core</groupId> + <artifactId>jackson-annotations</artifactId> + </exclusion> + </exclusions> </dependency> <dependency> <groupId>com.fasterxml.jackson.datatype</groupId> <artifactId>jackson-datatype-joda</artifactId> <version>${fasterxml.jackson.version}</version> + <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>com.fasterxml.jackson.core</groupId> + <artifactId>jackson-annotations</artifactId> + </exclusion> + </exclusions> </dependency> <dependency> <groupId>mysql</groupId> @@ -66,6 +80,21 @@ <groupId>com.basho.riak</groupId> <artifactId>riak-client</artifactId> <version>${riak.version}</version> + <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>com.fasterxml.jackson.core</groupId> + <artifactId>jackson-core</artifactId> + </exclusion> + <exclusion> + <groupId>com.fasterxml.jackson.core</groupId> + <artifactId>jackson-annotations</artifactId> + </exclusion> + <exclusion> + <groupId>com.fasterxml.jackson.datatype</groupId> + <artifactId>jackson-datatype-joda</artifactId> + </exclusion> + </exclusions> </dependency> </dependencies> http://git-wip-us.apache.org/repos/asf/brooklyn-library/blob/957087d0/software/messaging/pom.xml ---------------------------------------------------------------------- diff --git a/software/messaging/pom.xml b/software/messaging/pom.xml index 8730164..8d6bbb1 100644 --- a/software/messaging/pom.xml +++ b/software/messaging/pom.xml @@ -174,6 +174,17 @@ <artifactId>kafka</artifactId> <version>${kafka.version}</version> <scope>test</scope> + <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>org.apache.zookeeper</groupId> + <artifactId>zookeeper</artifactId> + </exclusion> + <exclusion> + <groupId>log4j</groupId> + <artifactId>log4j</artifactId> + </exclusion> + </exclusions> </dependency> <!-- for storm --> @@ -184,18 +195,117 @@ <!-- keep storm out of the jar-with-dependencies --> <scope>test</scope> <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>log4j</groupId> + <artifactId>log4j</artifactId> + </exclusion> <exclusion> <groupId>org.slf4j</groupId> <artifactId>slf4j-log4j12</artifactId> </exclusion> + <exclusion> + <groupId>org.clojure</groupId> + <artifactId>clojure</artifactId> + </exclusion> + <exclusion> + <groupId>org.apache.zookeeper</groupId> + <artifactId>zookeeper</artifactId> + </exclusion> + <exclusion> + <groupId>ring</groupId> + <artifactId>ring-core</artifactId> + </exclusion> + <exclusion> + <groupId>clj-time</groupId> + <artifactId>clj-time</artifactId> + </exclusion> + <exclusion> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + </exclusion> </exclusions> </dependency> + + <!-- Transitive dependencies, declared explicitly due to version mismatch --> + <dependency> + <groupId>log4j</groupId> + <artifactId>log4j</artifactId> + <version>${log4j.version}</version> + <scope>test</scope> + </dependency> <dependency> <groupId>org.slf4j</groupId> <artifactId>slf4j-log4j12</artifactId> <version>${slf4j.version}</version> <scope>test</scope> + <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>log4j</groupId> + <artifactId>log4j</artifactId> + </exclusion> + </exclusions> + </dependency> + <dependency> + <groupId>org.clojure</groupId> + <artifactId>clojure</artifactId> + <version>${clojure.version}</version> + <scope>test</scope> + </dependency> + <dependency> + <groupId>org.apache.zookeeper</groupId> + <artifactId>zookeeper</artifactId> + <version>${zookeeper.version}</version> + <scope>test</scope> + <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>log4j</groupId> + <artifactId>log4j</artifactId> + </exclusion> + </exclusions> + </dependency> + <dependency> + <groupId>ring</groupId> + <artifactId>ring-core</artifactId> + <version>${ring-core.version}</version> + <scope>test</scope> + <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>org.clojure</groupId> + <artifactId>clojure</artifactId> + </exclusion> + <exclusion> + <groupId>clj-time</groupId> + <artifactId>clj-time</artifactId> + </exclusion> + <exclusion> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + </exclusion> + </exclusions> + </dependency> + <dependency> + <groupId>clj-time</groupId> + <artifactId>clj-time</artifactId> + <version>${clj-time.version}</version> + <scope>test</scope> + <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>org.clojure</groupId> + <artifactId>clojure</artifactId> + </exclusion> + </exclusions> + </dependency> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>${commons-codec.version}</version> </dependency> + <!-- End of transitive dependencies --> </dependencies> </project> http://git-wip-us.apache.org/repos/asf/brooklyn-library/blob/957087d0/software/nosql/pom.xml ---------------------------------------------------------------------- diff --git a/software/nosql/pom.xml b/software/nosql/pom.xml index 29ca32a..d7e25b4 100644 --- a/software/nosql/pom.xml +++ b/software/nosql/pom.xml @@ -38,6 +38,17 @@ <groupId>org.apache.brooklyn</groupId> <artifactId>brooklyn-software-base</artifactId> <version>${project.version}</version> + <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + </exclusion> + <exclusion> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + </exclusion> + </exclusions> </dependency> <dependency> <groupId>org.apache.brooklyn</groupId> @@ -118,6 +129,7 @@ <version>${astyanax.version}</version> <scope>test</scope> <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> <exclusion> <artifactId>slf4j-log4j12</artifactId> <groupId>org.slf4j</groupId> @@ -126,6 +138,10 @@ <artifactId>log4j</artifactId> <groupId>log4j</groupId> </exclusion> + <exclusion> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + </exclusion> </exclusions> </dependency> <dependency> @@ -142,6 +158,15 @@ <version>${jcouchdb.version}</version> <scope>test</scope> <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + </exclusion> + <exclusion> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + </exclusion> <exclusion> <artifactId>slf4j-log4j12</artifactId> <groupId>org.slf4j</groupId> @@ -204,6 +229,18 @@ <version>${project.version}</version> <scope>test</scope> </dependency> + + <!-- Transitive dependencies, declared explicitly due to version mismatch --> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>${commons-logging.version}</version> + </dependency> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>${commons-codec.version}</version> + </dependency> </dependencies> <build> <pluginManagement> http://git-wip-us.apache.org/repos/asf/brooklyn-library/blob/957087d0/usage/camp/pom.xml ---------------------------------------------------------------------- diff --git a/usage/camp/pom.xml b/usage/camp/pom.xml index 96db968..2ac11e6 100644 --- a/usage/camp/pom.xml +++ b/usage/camp/pom.xml @@ -78,6 +78,13 @@ <groupId>commons-beanutils</groupId> <artifactId>commons-beanutils</artifactId> <version>1.9.1</version> + <exclusions> + <!-- Dependency versions mismatch between transitive dependencies, declare explicitly --> + <exclusion> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + </exclusion> + </exclusions> </dependency> <!-- TODO not enamoured of including software-base here, but it allows us to reference chef and vanilla for short names; @@ -133,6 +140,13 @@ <artifactId>testng</artifactId> <scope>test</scope> </dependency> + + <!-- Transitive dependencies, declared explicitly due to version mismatch --> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>${commons-logging.version}</version> + </dependency> </dependencies> <build>
