activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jstrac...@apache.org
Subject svn commit: r504235 - in /activemq/trunk/activemq-web-console/src/main: java/org/apache/activemq/web/ java/org/apache/activemq/web/controller/ java/org/apache/activemq/web/filter/ java/org/apache/activemq/web/handler/ webapp/ webapp/WEB-INF/ webapp/dec...
Date Tue, 06 Feb 2007 18:48:09 GMT
Author: jstrachan
Date: Tue Feb  6 10:48:07 2007
New Revision: 504235

URL: http://svn.apache.org/viewvc?view=rev&rev=504235
Log:
refactor the code to make it easy to support non-local brokers such as for connecting via
JMX to a remote broker

Added:
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java
  (with props)
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/LocalBrokerFacade.java
  (contents, props changed)
      - copied, changed from r504175, activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java
Modified:
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/DestinationFacade.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/DurableSubscriberFacade.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/MessageQuery.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/QueueBrowseQuery.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/SessionPool.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CreateDestination.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CreateSubscriber.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteDestination.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteSubscriber.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/PurgeDestination.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/SendMessage.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/filter/ApplicationContextFilter.java
    activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/handler/BindingBeanNameUrlHandlerMapping.java
    activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/applicationContext.xml
    activemq/trunk/activemq-web-console/src/main/webapp/decorators/main.jsp
    activemq/trunk/activemq-web-console/src/main/webapp/queueGraph.jsp

Added: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java?view=auto&rev=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java
(added)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java
Tue Feb  6 10:48:07 2007
@@ -0,0 +1,46 @@
+/**
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF 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.
+ */
+package org.apache.activemq.web;
+
+import org.apache.activemq.broker.jmx.BrokerViewMBean;
+import org.apache.activemq.command.ActiveMQDestination;
+
+import java.util.Collection;
+
+/**
+ * A facade for either a local in JVM broker or a remote broker over JMX
+ *
+ * @version $Revision$
+ */
+public interface BrokerFacade {
+
+    BrokerViewMBean getBrokerAdmin() throws Exception;
+
+    Collection getQueues() throws Exception;
+
+    Collection getTopics() throws Exception;
+
+    Collection getDurableTopicSubscribers() throws Exception;
+
+    /**
+     * Purges the given destination
+     * @param destination
+     * @throws Exception
+     */
+    void purgeQueue(ActiveMQDestination destination) throws Exception;
+}

Propchange: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/DestinationFacade.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/DestinationFacade.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/DestinationFacade.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/DestinationFacade.java
Tue Feb  6 10:48:07 2007
@@ -17,7 +17,7 @@
  */
 package org.apache.activemq.web;
 
-import org.apache.activemq.broker.BrokerService;
+import org.apache.activemq.broker.jmx.BrokerViewMBean;
 import org.apache.activemq.command.ActiveMQDestination;
 import org.apache.activemq.command.ActiveMQQueue;
 import org.apache.activemq.command.ActiveMQTopic;
@@ -29,16 +29,16 @@
  *
  * @version $Revision$
  */
-public class DestinationFacade extends BrokerFacade {
+public class DestinationFacade  {
 
     private String JMSDestination;
     private String JMSDestinationType;
+    private BrokerFacade brokerFacade;
 
-    public DestinationFacade(BrokerService brokerService) {
-        super(brokerService);
+    public DestinationFacade(BrokerFacade brokerFacade) {
+        this.brokerFacade = brokerFacade;
     }
 
-    
     public String toString() {
         return super.toString() + "[destination:" + JMSDestination + "; type=" + JMSDestinationType
+ "]";
     }
@@ -67,6 +67,14 @@
     
     // Properties
     // -------------------------------------------------------------------------
+    public BrokerViewMBean getBrokerAdmin() throws Exception {
+        return brokerFacade.getBrokerAdmin();
+    }
+
+    public BrokerFacade getBrokerFacade() {
+        return brokerFacade;
+    }
+
     public boolean isQueue() {
         if (JMSDestinationType != null && JMSDestinationType.equalsIgnoreCase("topic"))
{
             return false;
@@ -109,7 +117,7 @@
 
     protected ModelAndView redirectToRequest(HttpServletRequest request) {
         String view = "redirect:" + request.getRequestURI();
-        System.out.println("Redirecting to: " + view);
+//        System.out.println("Redirecting to: " + view);
         return new ModelAndView(view);
     }
 

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/DurableSubscriberFacade.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/DurableSubscriberFacade.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/DurableSubscriberFacade.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/DurableSubscriberFacade.java
Tue Feb  6 10:48:07 2007
@@ -17,8 +17,6 @@
  */
 package org.apache.activemq.web;
 
-import org.apache.activemq.broker.BrokerService;
-
 /**
  * 
  * @version $Revision$
@@ -28,8 +26,8 @@
     private String clientId;
     private String subscriberName;
 
-    public DurableSubscriberFacade(BrokerService brokerService) {
-        super(brokerService);
+    public DurableSubscriberFacade(BrokerFacade brokerFacade) {
+        super(brokerFacade);
     }
 
     public String getClientId() {

Copied: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/LocalBrokerFacade.java
(from r504175, activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java)
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/LocalBrokerFacade.java?view=diff&rev=504235&p1=activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java&r1=504175&p2=activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/LocalBrokerFacade.java&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/BrokerFacade.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/LocalBrokerFacade.java
Tue Feb  6 10:48:07 2007
@@ -24,30 +24,33 @@
 import org.apache.activemq.broker.jmx.DurableSubscriptionViewMBean;
 import org.apache.activemq.broker.jmx.ManagedRegionBroker;
 import org.apache.activemq.broker.jmx.ManagementContext;
-import org.apache.activemq.broker.jmx.QueueViewMBean;
 import org.apache.activemq.broker.jmx.TopicViewMBean;
+import org.apache.activemq.broker.region.Queue;
+import org.apache.activemq.command.ActiveMQDestination;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 
 import javax.management.MBeanServer;
 import javax.management.MBeanServerInvocationHandler;
 import javax.management.ObjectName;
-
 import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Collections;
+import java.util.Iterator;
 import java.util.List;
+import java.util.Set;
 
 /**
- * 
+ * An implementation of {@link BrokerFacade} which uses a local in JVM broker
+ *
  * @version $Revision$
  */
-public class BrokerFacade {
-    private static final Log log = LogFactory.getLog(BrokerFacade.class);
+public class LocalBrokerFacade implements BrokerFacade {
+    private static final Log log = LogFactory.getLog(LocalBrokerFacade.class);
 
     private BrokerService brokerService;
 
-    public BrokerFacade(BrokerService brokerService) {
+    public LocalBrokerFacade(BrokerService brokerService) {
         this.brokerService = brokerService;
     }
 
@@ -131,12 +134,19 @@
     }
 
     /**
-     * 
-     * 
+     *
+     *
      * public Collection getTopics() throws Exception { ManagedRegionBroker
      * broker = getManagedBroker(); if (broker == null) { return new
      * ArrayList(); } return
      * broker.getTopicRegion().getDestinationMap().values(); }
      */
 
+    public void purgeQueue(ActiveMQDestination destination) throws Exception {
+        Set destinations = getManagedBroker().getQueueRegion().getDestinations(destination);
+        for (Iterator i=destinations.iterator(); i.hasNext();) {
+            Queue regionQueue = (Queue)i.next();
+            regionQueue.purge();
+        }
+    }
 }

Propchange: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/LocalBrokerFacade.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/LocalBrokerFacade.java
------------------------------------------------------------------------------
    svn:keywords = Date Author Id Revision HeadURL

Propchange: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/LocalBrokerFacade.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/MessageQuery.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/MessageQuery.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/MessageQuery.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/MessageQuery.java
Tue Feb  6 10:48:07 2007
@@ -17,18 +17,14 @@
  */
 package org.apache.activemq.web;
 
-import org.apache.activemq.broker.BrokerService;
-
 import javax.jms.JMSException;
 import javax.jms.MapMessage;
 import javax.jms.Message;
 import javax.jms.ObjectMessage;
 import javax.jms.TextMessage;
-
 import java.util.Enumeration;
 import java.util.HashMap;
 import java.util.Map;
-import java.util.Set;
 
 /**
  * Allow the user to browse a message on a queue by its ID
@@ -40,8 +36,8 @@
     private String id;
     private Message message;
 
-    public MessageQuery(BrokerService brokerService, SessionPool sessionPool) throws JMSException
{
-        super(brokerService, sessionPool);
+    public MessageQuery(BrokerFacade brokerFacade, SessionPool sessionPool) throws JMSException
{
+        super(brokerFacade, sessionPool);
     }
 
     public String getId() {

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/QueueBrowseQuery.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/QueueBrowseQuery.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/QueueBrowseQuery.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/QueueBrowseQuery.java
Tue Feb  6 10:48:07 2007
@@ -17,7 +17,6 @@
  */
 package org.apache.activemq.web;
 
-import org.apache.activemq.broker.BrokerService;
 import org.springframework.beans.factory.DisposableBean;
 
 import javax.jms.JMSException;
@@ -36,8 +35,8 @@
     private Queue queue;
     private QueueBrowser browser;
 
-    public QueueBrowseQuery(BrokerService brokerService, SessionPool sessionPool) throws
JMSException {
-        super(brokerService);
+    public QueueBrowseQuery(BrokerFacade brokerFacade, SessionPool sessionPool) throws JMSException
{
+        super(brokerFacade);
         this.sessionPool = sessionPool;
         this.session = sessionPool.borrowSession();
         setJMSDestinationType("query");

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/SessionPool.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/SessionPool.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/SessionPool.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/SessionPool.java
Tue Feb  6 10:48:07 2007
@@ -22,7 +22,6 @@
 import javax.jms.ConnectionFactory;
 import javax.jms.JMSException;
 import javax.jms.Session;
-
 import java.util.LinkedList;
 
 /**

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CreateDestination.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CreateDestination.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CreateDestination.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CreateDestination.java
Tue Feb  6 10:48:07 2007
@@ -17,9 +17,8 @@
  */
 package org.apache.activemq.web.controller;
 
-import org.apache.activemq.broker.BrokerService;
+import org.apache.activemq.web.BrokerFacade;
 import org.apache.activemq.web.DestinationFacade;
-import org.apache.activemq.web.DurableSubscriberFacade;
 import org.springframework.web.servlet.ModelAndView;
 import org.springframework.web.servlet.mvc.Controller;
 
@@ -32,8 +31,8 @@
  */
 public class CreateDestination extends DestinationFacade implements Controller {
 
-    public CreateDestination(BrokerService brokerService) {
-        super(brokerService);
+    public CreateDestination(BrokerFacade brokerFacade) {
+        super(brokerFacade);
     }
 
     public ModelAndView handleRequest(HttpServletRequest request, HttpServletResponse response)
throws Exception {

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CreateSubscriber.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CreateSubscriber.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CreateSubscriber.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/CreateSubscriber.java
Tue Feb  6 10:48:07 2007
@@ -17,7 +17,7 @@
  */
 package org.apache.activemq.web.controller;
 
-import org.apache.activemq.broker.BrokerService;
+import org.apache.activemq.web.BrokerFacade;
 import org.apache.activemq.web.DurableSubscriberFacade;
 import org.springframework.web.servlet.ModelAndView;
 import org.springframework.web.servlet.mvc.Controller;
@@ -32,8 +32,8 @@
 public class CreateSubscriber extends DurableSubscriberFacade implements Controller {
     private String selector;
 
-    public CreateSubscriber(BrokerService brokerService) {
-        super(brokerService);
+    public CreateSubscriber(BrokerFacade brokerFacade) {
+        super(brokerFacade);
     }
 
     public String getSelector() {

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteDestination.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteDestination.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteDestination.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteDestination.java
Tue Feb  6 10:48:07 2007
@@ -17,9 +17,8 @@
  */
 package org.apache.activemq.web.controller;
 
-import org.apache.activemq.broker.BrokerService;
+import org.apache.activemq.web.BrokerFacade;
 import org.apache.activemq.web.DestinationFacade;
-import org.apache.activemq.web.DurableSubscriberFacade;
 import org.springframework.web.servlet.ModelAndView;
 import org.springframework.web.servlet.mvc.Controller;
 
@@ -32,8 +31,8 @@
  */
 public class DeleteDestination extends DestinationFacade implements Controller {
 
-    public DeleteDestination(BrokerService brokerService) {
-        super(brokerService);
+    public DeleteDestination(BrokerFacade brokerFacade) {
+        super(brokerFacade);
     }
 
     public ModelAndView handleRequest(HttpServletRequest request, HttpServletResponse response)
throws Exception {

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteSubscriber.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteSubscriber.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteSubscriber.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/DeleteSubscriber.java
Tue Feb  6 10:48:07 2007
@@ -17,7 +17,7 @@
  */
 package org.apache.activemq.web.controller;
 
-import org.apache.activemq.broker.BrokerService;
+import org.apache.activemq.web.BrokerFacade;
 import org.apache.activemq.web.DurableSubscriberFacade;
 import org.springframework.web.servlet.ModelAndView;
 import org.springframework.web.servlet.mvc.Controller;
@@ -31,8 +31,8 @@
  */
 public class DeleteSubscriber extends DurableSubscriberFacade implements Controller {
 
-    public DeleteSubscriber(BrokerService brokerService) {
-        super(brokerService);
+    public DeleteSubscriber(BrokerFacade brokerFacade) {
+        super(brokerFacade);
     }
 
     public ModelAndView handleRequest(HttpServletRequest request, HttpServletResponse response)
throws Exception {

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/PurgeDestination.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/PurgeDestination.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/PurgeDestination.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/PurgeDestination.java
Tue Feb  6 10:48:07 2007
@@ -17,16 +17,13 @@
  */
 package org.apache.activemq.web.controller;
 
-import org.apache.activemq.broker.BrokerService;
-import org.apache.activemq.broker.region.Queue;
+import org.apache.activemq.web.BrokerFacade;
 import org.apache.activemq.web.DestinationFacade;
 import org.springframework.web.servlet.ModelAndView;
 import org.springframework.web.servlet.mvc.Controller;
 
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
-import java.util.Set;
-import java.util.Iterator;
 
 /**
  *
@@ -34,8 +31,8 @@
  */
 public class PurgeDestination extends DestinationFacade implements Controller {
 
-    public PurgeDestination(BrokerService brokerService) {
-        super(brokerService);
+    public PurgeDestination(BrokerFacade brokerFacade) {
+        super(brokerFacade);
     }
 
     public ModelAndView handleRequest(HttpServletRequest request, HttpServletResponse response)
throws Exception {
@@ -45,11 +42,7 @@
 
     public void purgeDestination() throws Exception {
         if (isQueue()) {
-            Set destinations = getManagedBroker().getQueueRegion().getDestinations(createDestination());
-            for (Iterator i=destinations.iterator(); i.hasNext();) {
-                Queue regionQueue = (Queue)i.next();
-                regionQueue.purge();
-            }
+            getBrokerFacade().purgeQueue(createDestination());
         }
         else {
             throw new UnsupportedOperationException("Purge supported for queues only. Receieved
JMSDestinationType=" + getJMSDestinationType());

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/SendMessage.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/SendMessage.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/SendMessage.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/controller/SendMessage.java
Tue Feb  6 10:48:07 2007
@@ -17,8 +17,8 @@
  */
 package org.apache.activemq.web.controller;
 
-import org.apache.activemq.broker.BrokerService;
 import org.apache.activemq.command.ActiveMQDestination;
+import org.apache.activemq.web.BrokerFacade;
 import org.apache.activemq.web.DestinationFacade;
 import org.apache.activemq.web.WebClient;
 import org.springframework.web.servlet.ModelAndView;
@@ -28,7 +28,6 @@
 import javax.jms.Message;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
-
 import java.util.Iterator;
 import java.util.Map;
 
@@ -50,8 +49,8 @@
     private String JMSMessageCountHeader = "JMSXMessageNumber";
     private boolean redirectToBrowse;
 
-    public SendMessage(BrokerService brokerService) {
-        super(brokerService);
+    public SendMessage(BrokerFacade brokerFacade) {
+        super(brokerFacade);
     }
 
     public ModelAndView handleRequest(HttpServletRequest request, HttpServletResponse response)
throws Exception {

Modified: activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/filter/ApplicationContextFilter.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/filter/ApplicationContextFilter.java?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/filter/ApplicationContextFilter.java
(original)
+++ activemq/trunk/activemq-web-console/src/main/java/org/apache/activemq/web/filter/ApplicationContextFilter.java
Tue Feb  6 10:48:07 2007
@@ -28,7 +28,6 @@
 import javax.servlet.ServletException;
 import javax.servlet.ServletRequest;
 import javax.servlet.ServletResponse;
-
 import java.io.IOException;
 import java.util.AbstractMap;
 import java.util.Collections;

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?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- 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
Tue Feb  6 10:48:07 2007
@@ -17,10 +17,10 @@
  */
 package org.apache.activemq.web.handler;
 
-import org.springframework.web.bind.ServletRequestDataBinder;
-import org.springframework.web.servlet.handler.BeanNameUrlHandlerMapping;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.springframework.web.bind.ServletRequestDataBinder;
+import org.springframework.web.servlet.handler.BeanNameUrlHandlerMapping;
 
 import javax.servlet.http.HttpServletRequest;
 

Modified: activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/applicationContext.xml
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/applicationContext.xml?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/applicationContext.xml (original)
+++ activemq/trunk/activemq-web-console/src/main/webapp/WEB-INF/applicationContext.xml Tue
Feb  6 10:48:07 2007
@@ -27,7 +27,7 @@
 
   <bean id="sessionPool" class="org.apache.activemq.web.SessionPool"/>
   
-  <bean id="brokerQuery" class="org.apache.activemq.web.BrokerFacade" autowire='constructor'
singleton="false"/>
+  <bean id="brokerQuery" class="org.apache.activemq.web.LocalBrokerFacade" autowire='constructor'
singleton="false"/>
   <bean id="queueBrowser" class="org.apache.activemq.web.QueueBrowseQuery" autowire='constructor'
singleton="false"/>
   <bean id="messageQuery" class="org.apache.activemq.web.MessageQuery" autowire='constructor'
singleton="false"/>
 

Modified: activemq/trunk/activemq-web-console/src/main/webapp/decorators/main.jsp
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/webapp/decorators/main.jsp?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/webapp/decorators/main.jsp (original)
+++ activemq/trunk/activemq-web-console/src/main/webapp/decorators/main.jsp Tue Feb  6 10:48:07
2007
@@ -88,7 +88,7 @@
 <div id="wrapper-footer">
     <div id="footer">
         <p>
-            Copyright 2005-2006 The Apache Software Foundation
+            Copyright 2005-2007 The Apache Software Foundation
         </p>
 
         <p>

Modified: activemq/trunk/activemq-web-console/src/main/webapp/queueGraph.jsp
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-web-console/src/main/webapp/queueGraph.jsp?view=diff&rev=504235&r1=504234&r2=504235
==============================================================================
--- activemq/trunk/activemq-web-console/src/main/webapp/queueGraph.jsp (original)
+++ activemq/trunk/activemq-web-console/src/main/webapp/queueGraph.jsp Tue Feb  6 10:48:07
2007
@@ -42,7 +42,7 @@
     var layout = new PlotKit.Layout("bar", options);
     
     layout.addDataset("sqrt",  [<c:forEach items="${requestContext.brokerQuery.queues}"
var="row" varStatus="status"><c:if 
-         test="${status.count > 1}">, </c:if> [${status.count},  ${row.queueSize}]
</c:forEach> ]);
+         test="${status.count > 1}">, </c:if> [${status.count},  ${row.destinationStatistics.messages.count}]
</c:forEach> ]);
     layout.evaluate();
     
     var canvas = MochiKit.DOM.getElement("graph");



Mime
View raw message