From 81f876aac5bcc07a51a323be8116910c0cf2bdd7 Mon Sep 17 00:00:00 2001 From: Andy Wilkinson Date: Wed, 14 Oct 2015 20:36:43 +0100 Subject: [PATCH] Exclude bean-validator from jersey-spring3 to avoid classpath pollution MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit jersey-spring3 has a transtive dependencies on HK2’s bean-validator module that embeds JBoss Logging, Hibernate Validator, and Classmate without repackaging them. This makes it impossible to control the version of those three libraries that will be used without relying on classpath ordering. This commit excludes the bean-validator dependency from jersey-spring3. The Jersey starter already depends on our Validation starter which pulls in the proper, and controllable, version of the three dependencies listed above so users of our starters will be unaffected. Closes gh-4186 --- spring-boot-dependencies/pom.xml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/spring-boot-dependencies/pom.xml b/spring-boot-dependencies/pom.xml index d34ed31169..3784320ce3 100644 --- a/spring-boot-dependencies/pom.xml +++ b/spring-boot-dependencies/pom.xml @@ -1446,6 +1446,12 @@ org.glassfish.jersey.ext jersey-spring3 ${jersey.version} + + + org.glassfish.hk2.external + bean-validator + + org.glassfish.jersey.media