[jboss-cvs] JBossAS SVN: r107891 - branches/JBPAPP_5_0_1_GA_JBPAPP-4961/tomcat/src/main/org/jboss/web/tomcat/service/deployers.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Mon Aug 30 12:24:52 EDT 2010


Author: miclark
Date: 2010-08-30 12:24:51 -0400 (Mon, 30 Aug 2010)
New Revision: 107891

Modified:
   branches/JBPAPP_5_0_1_GA_JBPAPP-4961/tomcat/src/main/org/jboss/web/tomcat/service/deployers/TomcatDeployerMBean.java
   branches/JBPAPP_5_0_1_GA_JBPAPP-4961/tomcat/src/main/org/jboss/web/tomcat/service/deployers/TomcatService.java
Log:
JBPAPP-4961: Backported addition of tomcat start/stop notifications.

Modified: branches/JBPAPP_5_0_1_GA_JBPAPP-4961/tomcat/src/main/org/jboss/web/tomcat/service/deployers/TomcatDeployerMBean.java
===================================================================
--- branches/JBPAPP_5_0_1_GA_JBPAPP-4961/tomcat/src/main/org/jboss/web/tomcat/service/deployers/TomcatDeployerMBean.java	2010-08-30 14:37:02 UTC (rev 107890)
+++ branches/JBPAPP_5_0_1_GA_JBPAPP-4961/tomcat/src/main/org/jboss/web/tomcat/service/deployers/TomcatDeployerMBean.java	2010-08-30 16:24:51 UTC (rev 107891)
@@ -39,6 +39,9 @@
    /** JMX notification type to signal after-start connector event */
    public final String TOMCAT_CONNECTORS_STARTED = "jboss.tomcat.connectors.started";
 
+   /** JMX notification type to signal after-start connector event */
+   public final String TOMCAT_CONNECTORS_STOPPED = "jboss.tomcat.connectors.stopped";
+
    /**
     * @return the jmx domain for the tomcat management mbeans
     */

Modified: branches/JBPAPP_5_0_1_GA_JBPAPP-4961/tomcat/src/main/org/jboss/web/tomcat/service/deployers/TomcatService.java
===================================================================
--- branches/JBPAPP_5_0_1_GA_JBPAPP-4961/tomcat/src/main/org/jboss/web/tomcat/service/deployers/TomcatService.java	2010-08-30 14:37:02 UTC (rev 107890)
+++ branches/JBPAPP_5_0_1_GA_JBPAPP-4961/tomcat/src/main/org/jboss/web/tomcat/service/deployers/TomcatService.java	2010-08-30 16:24:51 UTC (rev 107891)
@@ -622,11 +622,11 @@
          Lifecycle lc = connectors[n];
          lc.start();
       }
-      /*
-       * TODO: // Notify listeners that connectors have started processing requests sendNotification(new
-       * Notification(TOMCAT_CONNECTORS_STARTED, this, getNextNotificationSequenceNumber()));
-       */
+
       connectorsRunning = true;
+
+      // Notify listeners that connectors have started processing requests (JBPAPP-4960)
+      sendNotification(new Notification(TOMCAT_CONNECTORS_STARTED, this, getNextNotificationSequenceNumber()));
    }
 
    public void stopConnectors() throws Exception
@@ -636,6 +636,9 @@
       if (!connectorsRunning)
          return;
 
+      // Notify listeners that connectors have stopped processing requests (JBPAPP-4960)
+      sendNotification(new Notification(TOMCAT_CONNECTORS_STOPPED, this, getNextNotificationSequenceNumber()));
+
       MBeanServer server = super.getServer();
       ObjectName service = new ObjectName(tomcatDeployer.getDomain() + ":type=Service,serviceName=jboss.web");
       Object[] args = {};



More information about the jboss-cvs-commits mailing list