killbill-aplcache

jaxrs: profiles: util: update Dropwizard metrics Signed-off-by:

3/16/2015 2:36:56 PM

Details

jaxrs/pom.xml 25(+11 -14)

diff --git a/jaxrs/pom.xml b/jaxrs/pom.xml
index 40d06a3..d3025dd 100644
--- a/jaxrs/pom.xml
+++ b/jaxrs/pom.xml
@@ -1,8 +1,10 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!--
   ~ Copyright 2010-2013 Ning, Inc.
+  ~ Copyright 2014-2015 Groupon, Inc
+  ~ Copyright 2014-2015 The Billing Project, LLC
   ~
-  ~ Ning licenses this file to you under the Apache License, version 2.0
+  ~ The Billing Project 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:
   ~
@@ -27,14 +29,6 @@
     <name>killbill-jaxrs</name>
     <dependencies>
         <dependency>
-            <groupId>com.codahale.metrics</groupId>
-            <artifactId>metrics-annotation</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>com.codahale.metrics</groupId>
-            <artifactId>metrics-jersey</artifactId>
-        </dependency>
-        <dependency>
             <groupId>com.fasterxml.jackson.core</groupId>
             <artifactId>jackson-annotations</artifactId>
         </dependency>
@@ -61,15 +55,18 @@
             <scope>provided</scope>
         </dependency>
         <dependency>
-            <!-- Required to bump the com.codahale.metrics:metrics-jersey dependency -->
-            <groupId>com.sun.jersey</groupId>
-            <artifactId>jersey-server</artifactId>
-        </dependency>
-        <dependency>
             <groupId>com.wordnik</groupId>
             <artifactId>swagger-annotations</artifactId>
         </dependency>
         <dependency>
+            <groupId>io.dropwizard.metrics</groupId>
+            <artifactId>metrics-annotation</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>io.dropwizard.metrics</groupId>
+            <artifactId>metrics-jersey</artifactId>
+        </dependency>
+        <dependency>
             <groupId>javax.inject</groupId>
             <artifactId>javax.inject</artifactId>
             <scope>provided</scope>

pom.xml 2(+1 -1)

diff --git a/pom.xml b/pom.xml
index 60c5cf4..489e0c2 100644
--- a/pom.xml
+++ b/pom.xml
@@ -20,7 +20,7 @@
     <parent>
         <artifactId>killbill-oss-parent</artifactId>
         <groupId>org.kill-bill.billing</groupId>
-        <version>0.9.15</version>
+        <version>0.9.16-SNAPSHOT</version>
     </parent>
     <artifactId>killbill</artifactId>
     <version>0.13.6-SNAPSHOT</version>
diff --git a/profiles/killbill/pom.xml b/profiles/killbill/pom.xml
index 7eb3c28..9b21cd9 100644
--- a/profiles/killbill/pom.xml
+++ b/profiles/killbill/pom.xml
@@ -1,8 +1,8 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!--
   ~ Copyright 2010-2013 Ning, Inc.
-  ~ Copyright 2014 Groupon, Inc
-  ~ Copyright 2014 The Billing Project, LLC
+  ~ Copyright 2014-2015 Groupon, Inc
+  ~ Copyright 2014-2015 The Billing Project, LLC
   ~
   ~ The Billing Project 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
@@ -60,6 +60,11 @@
             <scope>compile</scope>
         </dependency>
         <dependency>
+            <groupId>com.palominolabs.metrics</groupId>
+            <artifactId>metrics-guice</artifactId>
+            <scope>runtime</scope>
+        </dependency>
+        <dependency>
             <groupId>com.sun.jersey.contribs</groupId>
             <artifactId>jersey-guice</artifactId>
         </dependency>
@@ -67,11 +72,21 @@
             <groupId>com.wordnik</groupId>
             <artifactId>swagger-jersey-jaxrs_2.10</artifactId>
         </dependency>
+        <!-- Will be required when we upgrade metrics-guice to 3.1.3 -->
+        <!--<dependency>-->
+        <!--<groupId>com.palominolabs.metrics</groupId>-->
+        <!--<artifactId>metrics-guice-servlet</artifactId>-->
+        <!--<scope>runtime</scope>-->
+        <!--</dependency>-->
         <dependency>
             <groupId>com.zaxxer</groupId>
             <artifactId>HikariCP-java6</artifactId>
         </dependency>
         <dependency>
+            <groupId>io.dropwizard.metrics</groupId>
+            <artifactId>metrics-servlet</artifactId>
+        </dependency>
+        <dependency>
             <groupId>javax.servlet</groupId>
             <artifactId>javax.servlet-api</artifactId>
             <scope>provided</scope>
diff --git a/profiles/killbill/src/main/webapp/WEB-INF/web.xml b/profiles/killbill/src/main/webapp/WEB-INF/web.xml
index c101cb0..229fe97 100644
--- a/profiles/killbill/src/main/webapp/WEB-INF/web.xml
+++ b/profiles/killbill/src/main/webapp/WEB-INF/web.xml
@@ -43,6 +43,14 @@
         <filter-name>guiceFilter</filter-name>
         <url-pattern>/*</url-pattern>
     </filter-mapping>
+    <filter>
+        <filter-name>instrumentedFilter</filter-name>
+        <filter-class>com.codahale.metrics.servlet.InstrumentedFilter</filter-class>
+    </filter>
+    <filter-mapping>
+        <filter-name>instrumentedFilter</filter-name>
+        <url-pattern>/*</url-pattern>
+    </filter-mapping>
     <listener>
         <!-- Jersey insists on using java.util.logging (JUL) -->
         <listener-class>org.killbill.commons.skeleton.listeners.JULServletContextListener</listener-class>
diff --git a/profiles/killpay/pom.xml b/profiles/killpay/pom.xml
index a9ed5d8..1368c3f 100644
--- a/profiles/killpay/pom.xml
+++ b/profiles/killpay/pom.xml
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!--
-  ~ Copyright 2014 Groupon, Inc
-  ~ Copyright 2014 The Billing Project, LLC
+  ~ Copyright 2014-2015 Groupon, Inc
+  ~ Copyright 2014-2015 The Billing Project, LLC
   ~
   ~ The Billing Project 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
@@ -49,6 +49,21 @@
             <scope>compile</scope>
         </dependency>
         <dependency>
+            <groupId>com.palominolabs.metrics</groupId>
+            <artifactId>metrics-guice</artifactId>
+            <scope>runtime</scope>
+        </dependency>
+        <!-- Will be required when we upgrade metrics-guice to 3.1.3 -->
+        <!--<dependency>-->
+        <!--<groupId>com.palominolabs.metrics</groupId>-->
+        <!--<artifactId>metrics-guice-servlet</artifactId>-->
+        <!--<scope>runtime</scope>-->
+        <!--</dependency>-->
+        <dependency>
+            <groupId>io.dropwizard.metrics</groupId>
+            <artifactId>metrics-servlet</artifactId>
+        </dependency>
+        <dependency>
             <groupId>javax.servlet</groupId>
             <artifactId>javax.servlet-api</artifactId>
             <scope>provided</scope>
diff --git a/profiles/killpay/src/main/webapp/WEB-INF/web.xml b/profiles/killpay/src/main/webapp/WEB-INF/web.xml
index 6090924..dfe4911 100644
--- a/profiles/killpay/src/main/webapp/WEB-INF/web.xml
+++ b/profiles/killpay/src/main/webapp/WEB-INF/web.xml
@@ -44,6 +44,14 @@
         <filter-name>guiceFilter</filter-name>
         <url-pattern>/*</url-pattern>
     </filter-mapping>
+    <filter>
+        <filter-name>instrumentedFilter</filter-name>
+        <filter-class>com.codahale.metrics.servlet.InstrumentedFilter</filter-class>
+    </filter>
+    <filter-mapping>
+        <filter-name>instrumentedFilter</filter-name>
+        <url-pattern>/*</url-pattern>
+    </filter-mapping>
     <listener>
         <!-- Jersey insists on using java.util.logging (JUL) -->
         <listener-class>org.killbill.commons.skeleton.listeners.JULServletContextListener</listener-class>

util/pom.xml 37(+25 -12)

diff --git a/util/pom.xml b/util/pom.xml
index c1a80d1..4cbec28 100644
--- a/util/pom.xml
+++ b/util/pom.xml
@@ -1,12 +1,21 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!-- ~ Copyright 2010-2011 Ning, Inc. ~ ~ Ning 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. -->
+<!--
+  ~ Copyright 2010-2011 Ning, Inc.
+  ~ Copyright 2014-2015 Groupon, Inc
+  ~ Copyright 2014-2015 The Billing Project, LLC
+  ~
+  ~ The Billing Project 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/xsd/maven-4.0.0.xsd">
     <modelVersion>4.0.0</modelVersion>
     <parent>
@@ -20,10 +29,6 @@
     <name>killbill-util</name>
     <dependencies>
         <dependency>
-            <groupId>com.codahale.metrics</groupId>
-            <artifactId>metrics-core</artifactId>
-        </dependency>
-        <dependency>
             <groupId>com.fasterxml.jackson.core</groupId>
             <artifactId>jackson-annotations</artifactId>
         </dependency>
@@ -69,6 +74,14 @@
             <artifactId>jmustache</artifactId>
         </dependency>
         <dependency>
+            <groupId>io.dropwizard.metrics</groupId>
+            <artifactId>metrics-core</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>io.dropwizard.metrics</groupId>
+            <artifactId>metrics-ehcache</artifactId>
+        </dependency>
+        <dependency>
             <groupId>javax.inject</groupId>
             <artifactId>javax.inject</artifactId>
             <scope>provided</scope>