activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jstrac...@apache.org
Subject svn commit: r646334 - in /activemq/trunk: ./ activemq-web-console/ activemq-web-console/src/main/java/org/apache/activemq/web/handler/ activemq-web/src/main/java/org/apache/activemq/web/
Date Wed, 09 Apr 2008 13:29:08 GMT
Author: jstrachan
Date: Wed Apr  9 06:29:07 2008
New Revision: 646334

URL: http://svn.apache.org/viewvc?rev=646334&view=rev
Log:
updated to the latest/greatest jetty & sl4j along with patching the web console so it
works again :)

Modified:
    activemq/trunk/activemq-web-console/pom.xml
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/handler/BindingBeanNameUrlHandlerMapping.java
    activemq/trunk/activemq-web/src/main/java/org/apache/activemq/web/DestinationFacade.java
    activemq/trunk/pom.xml

Modified: activemq/trunk/activemq-web-console/pom.xml
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/pom.xml?rev=646334&r1=646333&r2=646334&view=diff
==============================================================================
--- activemq/trunk/activemq-web-console/pom.xml (original)
+++ activemq/trunk/activemq-web-console/pom.xml Wed Apr  9 06:29:07 2008
@@ -18,7 +18,7 @@
 -->
 
 <project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"
-  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0">
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0">
 
   <modelVersion>4.0.0</modelVersion>
 
@@ -39,16 +39,16 @@
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-war-plugin</artifactId>
         <configuration>
-           <warSourceExcludes>
-           	WEB-INF/lib/activation*.jar,
-           	WEB-INF/lib/activeio*.jar,
-           	WEB-INF/lib/activemq-console*.jar,
-           	WEB-INF/lib/activemq-core*.jar,
-           	WEB-INF/lib/activemq-xmpp*.jar,
-           	WEB-INF/lib/geronimo*.jar,
-           	WEB-INF/lib/xml-apis*.jar,
-           	WEB-INF/lib/xerces*.jar
-           </warSourceExcludes>
+          <warSourceExcludes>
+            WEB-INF/lib/activation*.jar,
+            WEB-INF/lib/activeio*.jar,
+            WEB-INF/lib/activemq-console*.jar,
+            WEB-INF/lib/activemq-core*.jar,
+            WEB-INF/lib/activemq-xmpp*.jar,
+            WEB-INF/lib/geronimo*.jar,
+            WEB-INF/lib/xml-apis*.jar,
+            WEB-INF/lib/xerces*.jar
+          </warSourceExcludes>
         </configuration>
       </plugin>
       <plugin>
@@ -62,39 +62,39 @@
               <maxIdleTime>60000</maxIdleTime>
             </connector>
           </connectors>
-          
+
           <webAppConfig>
             <contextPath>/</contextPath>
           </webAppConfig>
-          
+
           <systemProperties>
             <!-- enable easy connection to JConsole -->
             <systemProperty>
               <name>com.sun.management.jmxremote</name>
               <value></value>
             </systemProperty>
-             
-             <!-- Start an own broker -->
+
+            <!-- Start an own broker -->
             <systemProperty>
               <name>webconsole.type</name>
               <value>embedded</value>
             </systemProperty>
 
-<!--
-   Use the following configuration to connect to a remote broker using JMX
-            <systemProperty>
-              <name>webconsole.type</name>
-              <value>properties</value>
-            </systemProperty>
-            <systemProperty>
-              <name>webconsole.jms.url</name>
-              <value>tcp://localhost:61616</value>
-            </systemProperty>
-            <systemProperty>
-              <name>webconsole.jmx.url</name>
-              <value>service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi</value>
-            </systemProperty>
--->
+            <!--
+               Use the following configuration to connect to a remote broker using JMX
+                        <systemProperty>
+                          <name>webconsole.type</name>
+                          <value>properties</value>
+                        </systemProperty>
+                        <systemProperty>
+                          <name>webconsole.jms.url</name>
+                          <value>tcp://localhost:61616</value>
+                        </systemProperty>
+                        <systemProperty>
+                          <name>webconsole.jmx.url</name>
+                          <value>service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi</value>
+                        </systemProperty>
+            -->
           </systemProperties>
           <scanIntervalSeconds>10</scanIntervalSeconds>
         </configuration>
@@ -191,10 +191,28 @@
     </dependency>
 
     <!-- enable commons-logging when inside jetty6:run -->
+    <!--
+    <dependency>
+        <groupId>org.slf4j</groupId>
+        <artifactId>jcl104-over-slf4j</artifactId>
+        <version>1.5.0</version>
+    </dependency>
+    -->
+    <!--
+        <dependency>
+          <groupId>org.slf4j</groupId>
+          <artifactId>slf4j-jcl</artifactId>
+        </dependency>
+    -->
     <dependency>
       <groupId>org.slf4j</groupId>
-      <artifactId>slf4j-jcl</artifactId>
+      <artifactId>slf4j-api</artifactId>
     </dependency>
+    <dependency>
+      <groupId>org.slf4j</groupId>
+      <artifactId>slf4j-log4j12</artifactId>
+    </dependency>
+
     <dependency>
       <groupId>log4j</groupId>
       <artifactId>log4j</artifactId>

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/handler/BindingBeanNameUrlHandlerMapping.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/handler/BindingBeanNameUrlHandlerMapping.java?rev=646334&r1=646333&r2=646334&view=diff
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/handler/BindingBeanNameUrlHandlerMapping.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/handler/BindingBeanNameUrlHandlerMapping.java
Wed Apr  9 06:29:07 2008
@@ -22,6 +22,7 @@
 import org.apache.commons.logging.LogFactory;
 import org.springframework.web.bind.ServletRequestDataBinder;
 import org.springframework.web.servlet.handler.BeanNameUrlHandlerMapping;
+import org.springframework.web.servlet.HandlerExecutionChain;
 
 /**
  * @version $Revision$
@@ -33,17 +34,28 @@
         Object object = super.getHandlerInternal(request);
 
         if (object instanceof String) {
-            String handlerName = (String)object;
+            String handlerName = (String) object;
             object = getApplicationContext().getBean(handlerName);
         }
+        if (object instanceof HandlerExecutionChain) {
+            HandlerExecutionChain handlerExecutionChain = (HandlerExecutionChain) object;
+            object = handlerExecutionChain.getHandler();
+        }
 
-        ServletRequestDataBinder binder = new ServletRequestDataBinder(object, "request");
-        binder.bind(request);
-        binder.setIgnoreUnknownFields(true);
-        if (LOG.isDebugEnabled()) {
-            LOG.debug("Bound POJO is now: " + object);
+        if (object != null) {
+            ServletRequestDataBinder binder = new ServletRequestDataBinder(object, "request");
+            try {
+                binder.bind(request);
+                binder.setIgnoreUnknownFields(true);
+                if (LOG.isDebugEnabled()) {
+                    LOG.debug("Bound POJO is now: " + object);
+                }
+            }
+            catch (Exception e) {
+                LOG.warn("Caught: " + e, e);
+                throw e;
+            }
         }
         return object;
     }
-
 }

Modified: activemq/trunk/activemq-web/src/main/java/org/apache/activemq/web/DestinationFacade.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web/src/main/java/org/apache/activemq/web/DestinationFacade.java?rev=646334&r1=646333&r2=646334&view=diff
==============================================================================
--- activemq/trunk/activemq-web/src/main/java/org/apache/activemq/web/DestinationFacade.java
(original)
+++ activemq/trunk/activemq-web/src/main/java/org/apache/activemq/web/DestinationFacade.java
Wed Apr  9 06:29:07 2008
@@ -61,7 +61,14 @@
     // Properties
     // -------------------------------------------------------------------------
     public BrokerViewMBean getBrokerAdmin() throws Exception {
-        return brokerFacade.getBrokerAdmin();
+        if (brokerFacade == null) {
+            throw new IllegalArgumentException("No brokerFacade injected!");
+        }
+        BrokerViewMBean answer = brokerFacade.getBrokerAdmin();
+        if (answer == null) {
+            throw new IllegalArgumentException("No brokerAdmin on the injected brokerFacade:
" + brokerFacade);
+        }
+        return answer;
     }
 
     public BrokerFacade getBrokerFacade() {

Modified: activemq/trunk/pom.xml
URL: http://svn.apache.org/viewvc/activemq/trunk/pom.xml?rev=646334&r1=646333&r2=646334&view=diff
==============================================================================
--- activemq/trunk/pom.xml (original)
+++ activemq/trunk/pom.xml Wed Apr  9 06:29:07 2008
@@ -65,7 +65,7 @@
     <howl-version>0.1.8</howl-version>
     <hsqldb-version>1.7.2.2</hsqldb-version>
     <jdom-version>1.0</jdom-version>
-    <jetty-version>6.1.4</jetty-version>
+    <jetty-version>6.1.9</jetty-version>
     <jmock-version>1.0.1</jmock-version>
     <junit-version>3.8.1</junit-version>
     <jxta-version>2.0</jxta-version>
@@ -75,8 +75,7 @@
     <p2psockets-version>1.1.2</p2psockets-version>
     <regexp-version>1.3</regexp-version>
     <rome-version>0.8</rome-version>
-    <slf4j-version>1.4.0</slf4j-version>
-    <!--<slf4j-version>1.0-rc5</slf4j-version>-->
+    <slf4j-version>1.5.0</slf4j-version>
     <stax-version>1.2.0</stax-version>
     <xalan-version>2.6.0</xalan-version>
     <xmlbeans-version>2.0.0-beta1</xmlbeans-version>
@@ -845,6 +844,11 @@
       <dependency>
         <groupId>org.slf4j</groupId>
         <artifactId>slf4j-jcl</artifactId>
+        <version>${slf4j-version}</version>
+      </dependency>
+      <dependency>
+        <groupId>org.slf4j</groupId>
+        <artifactId>slf4j-log4j12</artifactId>
         <version>${slf4j-version}</version>
       </dependency>
       <dependency>



Mime
View raw message