1 Reply Latest reply on Jan 3, 2010 10:14 PM by Yong Hao Gao

    ClusteredConnectionFactory Problems

    David Roberts Newbie

      Using:

      JBoss 4.3 release.

      JBM Version 1.4

       

      I am not seeing the behavior described below in regard to supportsLoadBalancing and supportsFailover.  I would like to use both of these features, but neither is working.

       

       If the supportsLoadBalancing attribute of the
      connection factory is set to true then consecutive create connection
      attempts will round robin between available servers. The first node to
      try is chosen randomly 
       If the supportsFailover attribute of the
      connection factory is set to true then automatic failover is enabled.
      This will automatically failover from one server to another,
      transparently to the user, in case of failure. 
      
      
      

      http://www.redhat.com/docs/en-US/JBoss_Enterprise_Application_Platform/4.3.0.cp07/html-single/JBoss_Messaging_User_Guide_EAP_4_3_7/index.html#c_conf.clusteredcfs

       

       

      I have verified the following:

      • The test is using a two node cluster
      • the test uses an HAJNDI look up for ClusteredConnectionFactory
      • The ClusteredConnectionFactory has set both supportsLoadBalancing and supportsFailover to true

       

      When I stop one of the nodes I see my exception listener fire.  This is the first suprise because I thought the supportsFailover attribute protects me from that.  In any case, the exception listener is coded to try and reconnect when there is a problem and it asks for a new connection from the ClusteredConnectionFactory, however it always get refused connections from the down node.  I thought it would at least go to the other node every other time.

       

      Any ideas?