[jboss-cvs] JBossAS SVN: r100818 - in branches/Branch_Hornet_Temporary_2: hornetq-int/src/main/java/org/jboss/as/integration/hornetq/jopr/util and 2 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Wed Feb 10 13:07:41 EST 2010


Author: ataylor
Date: 2010-02-10 13:07:41 -0500 (Wed, 10 Feb 2010)
New Revision: 100818

Modified:
   branches/Branch_Hornet_Temporary_2/build/build.xml
   branches/Branch_Hornet_Temporary_2/hornetq-int/src/main/java/org/jboss/as/integration/hornetq/jopr/util/ResultsFormatter.java
   branches/Branch_Hornet_Temporary_2/hornetq-int/src/resources/META-INF/rhq-plugin.xml
   branches/Branch_Hornet_Temporary_2/server/src/etc/conf/all/bindingservice.beans/META-INF/bindings-jboss-beans.xml
Log:
added new hornetq component and fixed all target

Modified: branches/Branch_Hornet_Temporary_2/build/build.xml
===================================================================
--- branches/Branch_Hornet_Temporary_2/build/build.xml	2010-02-10 17:48:08 UTC (rev 100817)
+++ branches/Branch_Hornet_Temporary_2/build/build.xml	2010-02-10 18:07:41 UTC (rev 100818)
@@ -1797,7 +1797,7 @@
     -->
     <mkdir dir="${install.all.deploy}/hornetq.sar"/>
     <unzip src="${org.hornetq:hornetq-resources:jar}" dest="${install.all.deploy}/hornetq.sar">
-    	  <patternset includes="jboss-as/non-clustered/*" excludes="**/hornetq-users.properties,**/hornetq-roles.properties,**/hornetq-roles.properties,**/login-config.xml">
+    	  <patternset includes="jboss-as/clustered/*" excludes="**/hornetq-users.properties,**/hornetq-roles.properties,**/hornetq-roles.properties,**/login-config.xml">
     	  </patternset>
     	  <mapper type="flatten"/>
     </unzip>

Modified: branches/Branch_Hornet_Temporary_2/hornetq-int/src/main/java/org/jboss/as/integration/hornetq/jopr/util/ResultsFormatter.java
===================================================================
--- branches/Branch_Hornet_Temporary_2/hornetq-int/src/main/java/org/jboss/as/integration/hornetq/jopr/util/ResultsFormatter.java	2010-02-10 17:48:08 UTC (rev 100817)
+++ branches/Branch_Hornet_Temporary_2/hornetq-int/src/main/java/org/jboss/as/integration/hornetq/jopr/util/ResultsFormatter.java	2010-02-10 18:07:41 UTC (rev 100818)
@@ -78,6 +78,11 @@
          {
             data = formatConnectorPairsMetric((Object[]) attr);
          }
+
+         else if("clusternodes".equalsIgnoreCase(operation.getResultsType()))
+         {
+            data = formatClusterNodesMetric((Map<String, String>) attr);
+         }
          else if(attr instanceof Object[])
          {
             Object[] objects = (Object[]) attr;
@@ -119,18 +124,41 @@
       String formatConnectorPairsMetric(Object[] results)
       {
          StringBuffer sb = new StringBuffer();
-         for (int i = 0, resultsLength = results.length; i < resultsLength; i++)
+         if (results != null)
          {
-            Object[] result = (Object[]) results[i];
-            if(i > 0)
+            for (int i = 0, resultsLength = results.length; i < resultsLength; i++)
             {
-               sb.append(",");
+               Object[] result = (Object[]) results[i];
+               if(i > 0)
+               {
+                  sb.append(",");
+               }
+               sb.append("{a=").append(result[0].toString());
+               sb.append(",b=").append(result[1] == null?null:result[1].toString()).append("}");
             }
-            sb.append("{a=").append(result[0].toString());
-            sb.append(",b=").append(result[1].toString()).append("}");
          }
          return sb.toString();
       }
+
+      String formatClusterNodesMetric(Map<String, String> results)
+      {
+         StringBuffer sb = new StringBuffer();
+         boolean first = true;
+         if (results != null)
+         {
+            for (String s : results.keySet())
+            {
+               if(!first)
+               {
+                  sb.append(",");
+               }
+               first = false;
+               sb.append("{").append(s).append("=").append(results.get(s)).append("}");
+            }
+         }
+         return sb.toString();
+      }
+
       OperationResult formatJmsMessageResults(final Object result)
       {
          OperationResult operationResult = new OperationResult();

Modified: branches/Branch_Hornet_Temporary_2/hornetq-int/src/resources/META-INF/rhq-plugin.xml
===================================================================
--- branches/Branch_Hornet_Temporary_2/hornetq-int/src/resources/META-INF/rhq-plugin.xml	2010-02-10 17:48:08 UTC (rev 100817)
+++ branches/Branch_Hornet_Temporary_2/hornetq-int/src/resources/META-INF/rhq-plugin.xml	2010-02-10 18:07:41 UTC (rev 100818)
@@ -947,6 +947,180 @@
                  description="the pairs of live-backup connectors that are broadcasted by this broadcast group"
                  dataType="trait" displayType="summary"/>
          </service>
+         <service name="Cluster Connections"
+                  discovery="HornetQDiscoveryComponent"
+                  subCategory="Core"
+                  class="HornetQComponent">
+            <plugin-configuration>
+                <c:simple-property name="objectName" default="org.hornetq:module=Core,type=ClusterConnection"/>
+                <c:simple-property name="useResourceKeyForName" type="boolean" default="true"/>
+            </plugin-configuration>
+            &hornetqcomponentMetrics;
+            <metric property="Name"
+                 displayName="Name"
+                 description="the configuration name of this cluster connection"
+                 dataType="trait" displayType="summary"/>
+            <metric property="Address"
+                 displayName="Address"
+                 description="the address used by this cluster connection"
+                 dataType="trait" displayType="summary"/>
+            <metric property="NodeID"
+                 displayName="Node ID"
+                 description="the node id name of this cluster connection"
+                 dataType="trait" displayType="summary"/>
+            <metric property="DuplicateDetection"
+                 displayName="Duplicate Detection"
+                 description="whether this cluster connection uses duplicate detection"
+                 dataType="trait" displayType="summary"/>
+            <metric property="ForwardWhenNoConsumers"
+                 displayName="Forward When No Consumers"
+                 description="whether this cluster connection forward messages when it has no local consumers"
+                 dataType="trait" displayType="summary"/>
+            <metric property="MaxHops"
+                 displayName="Max Hops"
+                 description="the maximum number of hops used by this cluster connection"
+                 dataType="trait" displayType="summary"/>
+            <metric property="StaticConnectorNamePairs,result=connectorpairs"
+                 displayName="Static Connector Name Pairs"
+                 description="the pairs of live-backup connectors used by this cluster connection"
+                 dataType="trait" displayType="summary"/>
+            <metric property="DiscoveryGroupName"
+                 displayName="Discovery Group Name"
+                 description="name of the discovery group used by this cluster connection"
+                 dataType="trait" displayType="summary"/>
+            <metric property="RetryInterval"
+                 displayName="Retry Interval"
+                 description="the connection retry interval used by this cluster connection"
+                 dataType="trait" displayType="summary"/>
+           <!-- <metric property="Nodes,result=clusternodes"
+                 displayName="Nodes"
+                 description="the nodes connected to this cluster connection"
+                 dataType="trait" displayType="summary"/>-->
+         </service>
+         <service name="Discovery Groups"
+                  discovery="HornetQDiscoveryComponent"
+                  subCategory="Core"
+                  class="HornetQComponent">
+            <plugin-configuration>
+                <c:simple-property name="objectName" default="org.hornetq:module=Core,type=DiscoveryGroup"/>
+                <c:simple-property name="useResourceKeyForName" type="boolean" default="true"/>
+            </plugin-configuration>
+            &hornetqcomponentMetrics;
+            <metric property="Name"
+                 displayName="Name"
+                 description="name of this discovery group"
+                 dataType="trait" displayType="summary"/>
+            <metric property="GroupAddress"
+                 displayName="Group Address"
+                 description="the address that this discovery group is listening to"
+                 dataType="trait" displayType="summary"/>
+            <metric property="GroupPort"
+                 displayName="Group Port"
+                 description="the port that this discovery group is listening to"
+                 dataType="trait" displayType="summary"/>
+            <metric property="RefreshTimeout"
+                 displayName="Refresh Timeout"
+                 description="the refresh timeout used by this discovery group"
+                 dataType="trait" displayType="summary"/>
+         </service>
+         <service name="Divert Groups"
+                  discovery="HornetQDiscoveryComponent"
+                  subCategory="Core"
+                  class="HornetQComponent">
+            <plugin-configuration>
+                <c:simple-property name="objectName" default="org.hornetq:module=Core,type=Divert"/>
+                <c:simple-property name="useResourceKeyForName" type="boolean" default="true"/>
+            </plugin-configuration>
+            <metric property="Filter"
+                 displayName="Filter"
+                 description="the filter used by this divert"
+                 dataType="trait" displayType="summary"/>
+            <metric property="Exclusive"
+                 displayName="Exclusive"
+                 description="if true messages will be exclusively diverted and will not be routed to the origin address"
+                 dataType="trait" displayType="summary"/>
+            <metric property="UniqueName"
+                 displayName="Unique Name"
+                 description="the cluster-wide unique name of this divert"
+                 dataType="trait" displayType="summary"/>
+            <metric property="RoutingName"
+                 displayName="Routing Name"
+                 description="the routing name of this divert"
+                 dataType="trait" displayType="summary"/>
+            <metric property="Address"
+                 displayName="Address"
+                 description="the origin address used by this divert"
+                 dataType="trait" displayType="summary"/>
+            <metric property="ForwardingAddress"
+                 displayName="Forwarding Address"
+                 description="the forwarding address used by this divert"
+                 dataType="trait" displayType="summary"/>
+            <metric property="TransformerClassName"
+                 displayName="Transformer Class Name"
+                 description="the name of the org.hornetq.core.server.cluster.Transformer implementation associated to this divert"
+                 dataType="trait" displayType="summary"/>
+         </service>
+         <service name="Core Queues"
+                  discovery="HornetQDiscoveryComponent"
+                  subCategory="Core"
+                  class="HornetQComponent">
+            <plugin-configuration>
+                <c:simple-property name="objectName" default="org.hornetq:module=Core,type=Queue"/>
+                <c:simple-property name="useResourceKeyForName" type="boolean" default="true"/>
+            </plugin-configuration>
+            <metric property="Name"
+                 displayName="Name"
+                 description="name of this queue"
+                 dataType="trait" displayType="summary"/>
+            <metric property="Address"
+                 displayName="Address"
+                 description="the address this queue is bound to"
+                 dataType="trait" displayType="summary"/>
+            <metric property="ID"
+                 displayName="ID"
+                 description="this queue ID"
+                 dataType="trait" displayType="summary"/>
+            <metric property="Temporary"
+                 displayName="Temporary"
+                 description="whether this queue is temporary"
+                 dataType="trait" displayType="summary"/>
+            <metric property="Durable"
+                 displayName="Durable"
+                 description="whether this queue is durable"
+                 dataType="trait" displayType="summary"/>
+            <metric property="Filter"
+                 displayName="Filter"
+                 description="the filter used by this queue"
+                 dataType="trait" displayType="summary"/>
+            <metric property="MessageCount"
+                 displayName="Message Count"
+                 description="the number of messages currently in this queue"
+                 dataType="trait" displayType="summary"/>
+            <metric property="ScheduledCount"
+                 displayName="Scheduled Count"
+                 description="the number of scheduled messages in this queue"
+                 dataType="trait" displayType="summary"/>
+            <metric property="ConsumerCount"
+                 displayName="Consumer Count"
+                 description="the number of consumers consuming messages from this queue"
+                 dataType="trait" displayType="summary"/>
+            <metric property="DeliveringCount"
+                 displayName="Delivering Count"
+                 description="the number of messages that this queue is currently delivering to its consumers"
+                 dataType="trait" displayType="summary"/>
+            <metric property="MessagesAdded"
+                 displayName="Messages Added"
+                 description="the number of messages added to this queue since it was created"
+                 dataType="trait" displayType="summary"/>
+            <metric property="ExpiryAddress"
+                 displayName="Expiry Address"
+                 description="the expiry address associated to this queue"
+                 dataType="trait" displayType="summary"/>
+            <metric property="DeadLetterAddress"
+                 displayName="Dead Letter Address"
+                 description="the dead-letter address associated to this queue"
+                 dataType="trait" displayType="summary"/>
+         </service>
       </server>
 
 </plugin>

Modified: branches/Branch_Hornet_Temporary_2/server/src/etc/conf/all/bindingservice.beans/META-INF/bindings-jboss-beans.xml
===================================================================
--- branches/Branch_Hornet_Temporary_2/server/src/etc/conf/all/bindingservice.beans/META-INF/bindings-jboss-beans.xml	2010-02-10 17:48:08 UTC (rev 100817)
+++ branches/Branch_Hornet_Temporary_2/server/src/etc/conf/all/bindingservice.beans/META-INF/bindings-jboss-beans.xml	2010-02-10 18:07:41 UTC (rev 100818)
@@ -300,20 +300,20 @@
                <property name="description">Socket for JBoss Messaging 1.x</property>
             </bean>
 
-            <!-- ********************* JBoss Messaging 2 **************** -->
+            <!-- ********************* HornetQ          **************** -->
 
             <bean class="org.jboss.services.binding.ServiceBindingMetadata">
-                <property name="serviceName">JBM2</property>
+                <property name="serviceName">HornetQ</property>
                 <property name="bindingName">netty-port</property>
                 <property name="port">5445</property>
-                <property name="description">Socket for JBoss Messaging 2.x</property>
+                <property name="description">Socket for HornetQ</property>
             </bean>
 
             <bean class="org.jboss.services.binding.ServiceBindingMetadata">
-                <property name="serviceName">JBM2</property>
+                <property name="serviceName">HornetQ</property>
                 <property name="bindingName">netty-ssl-port</property>
                 <property name="port">5446</property>
-                <property name="description">SSL socket for JBoss Messaging 2.x</property>
+                <property name="description">SSL socket for HornetQ</property>
             </bean>
 
             <!-- ********************* deploy/transaction-jboss-beans.xml ********************** -->
@@ -412,25 +412,25 @@
                      </parameter>
                   </constructor>
                </bean>
-               <!-- JBM2 netty connector -->
+               <!-- HornetQ netty connector -->
                <bean class="org.jboss.services.binding.SystemPropertyBinding">
                   <constructor>
-                     <parameter>jbm.remoting.netty.port</parameter>
+                     <parameter>hornetq.remoting.netty.port</parameter>
                      <parameter class="int">
                         <value-factory bean="ServiceBindingManager" method="getIntBinding">
-                             <parameter>JBM2</parameter>
+                             <parameter>HornetQ</parameter>
                              <parameter>netty-port</parameter>
                         </value-factory>
                      </parameter>
                   </constructor>
                </bean>
-               <!-- JBM2 netty ssl connector  -->
+               <!-- HornetQ netty ssl connector  -->
                <bean class="org.jboss.services.binding.SystemPropertyBinding">
                   <constructor>
-                     <parameter>jbm.remoting.netty.ssl.port</parameter>
+                     <parameter>hornetq.remoting.netty.ssl.port</parameter>
                      <parameter class="int">
                         <value-factory bean="ServiceBindingManager" method="getIntBinding">
-                             <parameter>JBM2</parameter>
+                             <parameter>HornetQ</parameter>
                              <parameter>netty-ssl-port</parameter>
                         </value-factory>
                      </parameter>




More information about the jboss-cvs-commits mailing list