Hello,

I am trying to use the ServiceBindingManager to change the mcast_addr setting. We use 
this service successfully to allow us to run more than 1 JBoss node on a machine but 
also want to do this so that we can run independent clusters. Ideally I only want 1 
version of cluster-service.xml and use ServiceBinding to change the mcast_addr value.

I am using the XSLTConfigDelegate to do this. I supply the cluster-service.xml extract 
along with my service-config.

I get the following exception:


  | 14:25:25,678 INFO  [MainDeployer] Starting deployment of package: 
file:/J:/3rdparty_javadev_vob/jboss/server/ro1/deploy/cluster-service.xml
  | 14:25:25,819 WARN  [ServiceConfigurator] Failed to apply service binding override
  | javax.management.AttributeNotFoundException: Readable attribute 'PartitionConfig' 
not found
  |         at 
org.jboss.mx.capability.ReflectedMBeanDispatcher.getAttribute(ReflectedMBeanDispatcher.java:136)
  |         at 
org.jboss.mx.server.MBeanServerImpl.getAttribute(MBeanServerImpl.java:453)
  |         at 
org.jboss.services.binding.XSLTConfigDelegate.applyConfig(XSLTConfigDelegate.java:73)
  |         at org.jboss.services.binding.ServiceBindingManager.applyServiceConfig(S
  | 

It states that PartitionConfig is not readable.

When I look at my DefaultPartition MBean through jmx-console it shows that 
PartitionConfig is WRITE-ONLY. Is there a reason for this? Could this be causing my 
problem?

Many thanks in advance.

Regards

mark

CLUSTER XML

  |   <!-- ==================================================================== -->
  |   <!-- Cluster Partition: defines cluster                                   -->
  |   <!-- ==================================================================== -->
  | 
  |   <mbean code="org.jboss.ha.framework.server.ClusterPartition"
  |          name="jboss:service=DefaultPartition">
  |          
  |     <attribute name="PartitionConfig">
  |       <Config>
  |         <!-- UDP: if you have a multihomed machine, 
  |              set the bind_addr attribute to the appropriate NIC IP address -->
  |         <!-- UDP: On Windows machines, because of the media sense feature
  |              being broken with multicast (even after disabling media sense)
  |              set the loopback attribute to true -->
  |         <!--<UDP mcast_addr="${uk.co.hemscott.UDP.mcast_addr}" mcast_port="45566" 
-->
  |         <UDP mcast_addr="228.1.2.5" mcast_port="45566"
  |              ip_ttl="64" ip_mcast="true"
  |              mcast_send_buf_size="150000" mcast_recv_buf_size="80000" 
  |              ucast_send_buf_size="150000" ucast_recv_buf_size="80000" 
  |              loopback="false" />
  |         <PING timeout="2000" num_initial_members="3" 
  |               up_thread="true" down_thread="true" />
  |         <MERGE2 min_interval="5000" max_interval="10000" />
  |         <FD shun="true" up_thread="true" down_thread="true" 
  |             timeout="2500" max_tries="5" />
  |         <VERIFY_SUSPECT timeout="3000" num_msgs="3"
  |                         up_thread="true" down_thread="true" />
  |         <pbcast.NAKACK gc_lag="50" retransmit_timeout="300,600,1200,2400,4800"
  |                        up_thread="true" down_thread="true" />
  |         <pbcast.STABLE desired_avg_gossip="20000"
  |                        up_thread="true" down_thread="true" />
  |         <UNICAST timeout="5000" window_size="100" min_threshold="10"
  |                  down_thread="true" />
  |         <FRAG frag_size="8192"
  |               down_thread="true" up_thread="true" />
  |         <pbcast.GMS join_timeout="5000" join_retry_timeout="2000"
  |                     shun="true" print_local_addr="true" />
  |         <pbcast.STATE_TRANSFER up_thread="true" down_thread="true" />
  |       </Config>
  |     </attribute>
  |     
  |     <!-- Name of the partition being built -->
  |     <attribute name="PartitionName">DefaultPartition</attribute>
  |     <!-- Determine if deadlock detection is enabled -->
  |     <attribute name="DeadlockDetection">False</attribute>
  |     <!-- The JGroups protocol configuration -->    
  |   </mbean>
  | 

SERVICE BINDING XML

  |       <service-config name="jboss:service=DefaultPartition"
  |          delegateClass="org.jboss.services.binding.XSLTConfigDelegate"
  |       >
  |          <delegate-config>
  |          <xslt-config configName="PartitionConfig"><![CDATA[
  | <xsl:stylesheet
  |       xmlns:xsl='http://www.w3.org/1999/XSL/Transform' version='1.0'>
  | 
  |   <xsl:output method="xml" />
  |   <!--<xsl:param name="port"/>
  | 
  |   <xsl:variable name="portAJP" select="$port - 71"/>-->
  | 
  |   <xsl:template match="/">
  |     <xsl:apply-templates/>
  |   </xsl:template>
  | 
  |   <xsl:template match = "UDP">
  |       <UDP>
  |          <xsl:for-each select="@*">
  |          <xsl:choose>
  |             <xsl:when test="(name() = 'mcast_addr'">
  |                <!--<xsl:attribute name="mcast_addr"><xsl:value-of 
select="$port"/></xsl:attribute>-->
  |                <xsl:attribute name="mcast_addr">228.1.2.4</xsl:attribute>
  |             </xsl:when>
  |             <xsl:otherwise>
  |                <xsl:attribute name="{name()}"><xsl:value-of select="." 
/></xsl:attribute>
  |             </xsl:otherwise>
  |          </xsl:choose>
  |          </xsl:for-each>
  |       </UDP>
  |    </xsl:template>
  | 
  |   <xsl:template match="*|@*">
  |     <xsl:copy>
  |       <xsl:apply-templates select="@*|node()"/>
  |     </xsl:copy>
  |   </xsl:template>
  | </xsl:stylesheet>
  | ]]>
  |          </xslt-config>
  |          </delegate-config>
  |          <!--<binding port="8180" />-->
  |       </service-config>
  | 

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3840303#3840303

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3840303


-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - 
digital self defense, top technical experts, no vendor pitches, 
unmatched networking opportunities. Visit www.blackhat.com
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to