activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chir...@apache.org
Subject svn commit: r1237319 - in /activemq/activemq-apollo/trunk: apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/ apollo-dto/src/main/java/org/apache/activemq/apollo/dto/ apollo-openwire/ apollo-openwire/src/main/webapp/ apollo-openwire/src/ma...
Date Sun, 29 Jan 2012 15:57:07 GMT
Author: chirino
Date: Sun Jan 29 15:57:06 2012
New Revision: 1237319

URL: http://svn.apache.org/viewvc?rev=1237319&view=rev
Log:
Fixes APLO-141 : The connection screen displays 'transport: tcp' even though the connection
came in over the tls port.

renamed the 'transport' field to 'connector' and now it's set to the id of the connector which
created the connection.
Alos added a connection status HTML page for openwire and also provide the protocol session
id in the connection status screens.

Added:
    activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/
    activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/
    activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/
    activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/apache/
    activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/apache/activemq/
    activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/apache/activemq/apollo/
    activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/apache/activemq/apollo/openwire/
    activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/apache/activemq/apollo/openwire/dto/
    activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/apache/activemq/apollo/openwire/dto/OpenwireConnectionStatusDTO.jade
      - copied, changed from r1237311, activemq/activemq-apollo/trunk/apollo-stomp/src/main/webapp/WEB-INF/org/apache/activemq/apollo/stomp/dto/StompConnectionStatusDTO.jade
Modified:
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Connection.scala
    activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/ConnectionStatusDTO.java
    activemq/activemq-apollo/trunk/apollo-openwire/pom.xml
    activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
    activemq/activemq-apollo/trunk/apollo-stomp/src/main/webapp/WEB-INF/org/apache/activemq/apollo/stomp/dto/StompConnectionStatusDTO.jade
    activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/ConnectionStatusDTO.jade
    activemq/activemq-apollo/trunk/apollo-website/src/documentation/management-api.md

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Connection.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Connection.scala?rev=1237319&r1=1237318&r2=1237319&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Connection.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/Connection.scala
Sun Jan 29 15:57:06 2012
@@ -142,9 +142,10 @@ class BrokerConnection(var connector: Co
     result.state = service_state.toString
     result.state_since = service_state.since
     result.protocol = protocol_handler.protocol
-    result.transport = transport.getTypeId
+    result.connector = connector.id
     result.remote_address = transport.getRemoteAddress.toString
     result.local_address = transport.getLocalAddress.toString
+    result.protocol_session_id = protocol_handler.session_id.getOrElse(null)
     val wf = transport.getProtocolCodec
     if( wf!=null ) {
       result.write_counter = wf.getWriteCounter

Modified: activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/ConnectionStatusDTO.java
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/ConnectionStatusDTO.java?rev=1237319&r1=1237318&r2=1237319&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/ConnectionStatusDTO.java
(original)
+++ activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/ConnectionStatusDTO.java
Sun Jan 29 15:57:06 2012
@@ -58,10 +58,10 @@ public class ConnectionStatusDTO extends
 	public long write_counter;
 
     /**
-     * The transport the connection is using.
+     * The connector that created the connection.
      */
 	@XmlAttribute
-	public String transport;
+	public String connector;
 
     /**
      * The protocol the connection is using.
@@ -72,7 +72,7 @@ public class ConnectionStatusDTO extends
     /**
      * The version of the protocol being used.
      */
-	@XmlAttribute
+	@XmlAttribute(name="protocol_version")
 	public String protocol_version;
 
     /**
@@ -88,6 +88,12 @@ public class ConnectionStatusDTO extends
 	public String local_address;
 
     /**
+     * The session id of the protocol.
+     */
+	@XmlAttribute(name="protocol_session_id")
+	public String protocol_session_id;
+
+    /**
      * The connected user
      */
 	@XmlAttribute

Modified: activemq/activemq-apollo/trunk/apollo-openwire/pom.xml
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-openwire/pom.xml?rev=1237319&r1=1237318&r2=1237319&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-openwire/pom.xml (original)
+++ activemq/activemq-apollo/trunk/apollo-openwire/pom.xml Sun Jan 29 15:57:06 2012
@@ -184,6 +184,19 @@
         </executions>
       </plugin>
 
+      <plugin>
+        <groupId>org.fusesource.scalate</groupId>
+        <artifactId>maven-scalate-plugin</artifactId>
+        <version>${scalate-version}</version>
+        <executions>
+          <execution>
+            <goals>
+              <goal>precompile</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+
     </plugins>
   </build>
 

Copied: activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/apache/activemq/apollo/openwire/dto/OpenwireConnectionStatusDTO.jade
(from r1237311, activemq/activemq-apollo/trunk/apollo-stomp/src/main/webapp/WEB-INF/org/apache/activemq/apollo/stomp/dto/StompConnectionStatusDTO.jade)
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/apache/activemq/apollo/openwire/dto/OpenwireConnectionStatusDTO.jade?p2=activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/apache/activemq/apollo/openwire/dto/OpenwireConnectionStatusDTO.jade&p1=activemq/activemq-apollo/trunk/apollo-stomp/src/main/webapp/WEB-INF/org/apache/activemq/apollo/stomp/dto/StompConnectionStatusDTO.jade&r1=1237311&r2=1237319&rev=1237319&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-stomp/src/main/webapp/WEB-INF/org/apache/activemq/apollo/stomp/dto/StompConnectionStatusDTO.jade
(original)
+++ activemq/activemq-apollo/trunk/apollo-openwire/src/main/webapp/WEB-INF/org/apache/activemq/apollo/openwire/dto/OpenwireConnectionStatusDTO.jade
Sun Jan 29 15:57:06 2012
@@ -26,15 +26,23 @@ p state: #{state} #{ uptime(state_since)
   form(method="post" action={path("action/delete")})
     input(type="submit" value="shutdown")
 
+h4 Connection Info
+
+p connector: #{connector}
 p local address: #{local_address}
 p remote address: #{remote_address}
+
+h4 Protocol Info
+
 p protocol: #{protocol}
 p protocol version: #{protocol_version}
-p transport: #{transport}
+p protocol session id: #{protocol_session_id}
+p user: #{user}
+p subscription count: #{subscription_count}
+
+h4 Metrics
+
 p read counter: #{memory(read_counter)}
 p write counter: #{memory(write_counter)}
 p last read size: #{memory(last_read_size)}
 p last write size: #{memory(last_write_size)}
-p user: #{user}
-p waiting on: #{waiting_on}
-p subscription count: #{subscription_count}

Modified: activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala?rev=1237319&r1=1237318&r2=1237319&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-stomp/src/main/scala/org/apache/activemq/apollo/stomp/StompProtocolHandler.scala
Sun Jan 29 15:57:06 2012
@@ -928,7 +928,7 @@ class StompProtocolHandler extends Proto
         noop
       } else {
         this.host=host
-        security_context.session_id = Some("%s-%x-".format(destination_parser.sanitize_destination_part(this.host.config.id),
this.host.session_counter.incrementAndGet))
+        security_context.session_id = Some("%s-%x".format(destination_parser.sanitize_destination_part(this.host.config.id),
this.host.session_counter.incrementAndGet))
         connection_log = host.connection_log
         if( host.authenticator!=null &&  host.authorizer!=null ) {
           suspend_read("authenticating and authorizing connect")

Modified: activemq/activemq-apollo/trunk/apollo-stomp/src/main/webapp/WEB-INF/org/apache/activemq/apollo/stomp/dto/StompConnectionStatusDTO.jade
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-stomp/src/main/webapp/WEB-INF/org/apache/activemq/apollo/stomp/dto/StompConnectionStatusDTO.jade?rev=1237319&r1=1237318&r2=1237319&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-stomp/src/main/webapp/WEB-INF/org/apache/activemq/apollo/stomp/dto/StompConnectionStatusDTO.jade
(original)
+++ activemq/activemq-apollo/trunk/apollo-stomp/src/main/webapp/WEB-INF/org/apache/activemq/apollo/stomp/dto/StompConnectionStatusDTO.jade
Sun Jan 29 15:57:06 2012
@@ -26,15 +26,23 @@ p state: #{state} #{ uptime(state_since)
   form(method="post" action={path("action/delete")})
     input(type="submit" value="shutdown")
 
+h4 Connection Info
+
+p connector: #{connector}
 p local address: #{local_address}
 p remote address: #{remote_address}
+
+h4 Protocol Info
+
 p protocol: #{protocol}
 p protocol version: #{protocol_version}
-p transport: #{transport}
+p protocol session id: #{protocol_session_id}
+p user: #{user}
+p subscription count: #{subscription_count}
+
+h4 Metrics
+
 p read counter: #{memory(read_counter)}
 p write counter: #{memory(write_counter)}
 p last read size: #{memory(last_read_size)}
 p last write size: #{memory(last_write_size)}
-p user: #{user}
-p waiting on: #{waiting_on}
-p subscription count: #{subscription_count}

Modified: activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/ConnectionStatusDTO.jade
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/ConnectionStatusDTO.jade?rev=1237319&r1=1237318&r2=1237319&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/ConnectionStatusDTO.jade
(original)
+++ activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/ConnectionStatusDTO.jade
Sun Jan 29 15:57:06 2012
@@ -17,23 +17,33 @@
 - val helper = new org.apache.activemq.apollo.web.resources.ViewHelper
 - import helper._
 
+
 .breadcumbs
-  a(href={strip_resolve("..")+".html"}) Back
+  a(href={strip_resolve("..")}) Back
 
 p state: #{state} #{ uptime(state_since) } ago
+
 - if( state == "STARTED" )
   form(method="post" action={path("action/delete")})
     input(type="submit" value="shutdown")
 
+h4 Connection Info
+
+p connector: #{connector}
 p local address: #{local_address}
 p remote address: #{remote_address}
+
+h4 Protocol Info
+
 p protocol: #{protocol}
 p protocol version: #{protocol_version}
-p transport: #{transport}
+p protocol session id: #{protocol_session_id}
+p user: #{user}
+p subscription count: #{subscription_count}
+
+h4 Metrics
+
 p read counter: #{memory(read_counter)}
 p write counter: #{memory(write_counter)}
 p last read size: #{memory(last_read_size)}
 p last write size: #{memory(last_write_size)}
-p user: #{user}
-p waiting on: #{waiting_on}
-p subscription count: #{subscription_count}

Modified: activemq/activemq-apollo/trunk/apollo-website/src/documentation/management-api.md
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-website/src/documentation/management-api.md?rev=1237319&r1=1237318&r2=1237319&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-website/src/documentation/management-api.md (original)
+++ activemq/activemq-apollo/trunk/apollo-website/src/documentation/management-api.md Sun
Jan 29 15:57:06 2012
@@ -93,7 +93,7 @@ Results in a [Data Page](./api/apollo-dt
       "state_since":1306848325102,
       "read_counter":103,
       "write_counter":239110628,
-      "transport":"tcp",
+      "connector":"tcp",
       "protocol":"stomp",
       "remote_address":"/127.0.0.1:61775",
       "protocol_version":"1.0",
@@ -107,7 +107,7 @@ Results in a [Data Page](./api/apollo-dt
       "state_since":1306848325102,
       "read_counter":227739229,
       "write_counter":113,
-      "transport":"tcp",
+      "connector:"tcp",
       "protocol":"stomp",
       "remote_address":"/127.0.0.1:61776",
       "protocol_version":"1.0",
@@ -681,7 +681,7 @@ parameter to define the order in which t
         "last_write_size": 32973,
         "read_counter": 106,
         "write_counter": 632923992,
-        "transport": "tcp",
+        "connector: "tcp",
         "protocol": "stomp",
         "protocol_version": "1.0",
         "remote_address": "/127.0.0.1:51733",



Mime
View raw message