1 Reply Latest reply on Jun 12, 2007 5:39 AM by thoism

    Question about clustering

    thoism

      Hello everybody

      I deployed my application on a clustered configuration with all my EJBs clustered e.t.c. I added the Clustered annotation on each one of them. My question is "Is it possible to add all ejbs of my jar as clustered by using the jboss.xml?"

      Does this descriptor below work for example(notice the *)?
      <?xml version="1.0" encoding="utf-8"?>
      <!DOCTYPE jboss PUBLIC "-//JBoss//DTD JBOSS 4.0//EN" "http://www.jboss.org/j2ee/dtd/jboss_4_0.dtd">

      <security-domain>myRealm</security-domain>
      <unauthenticated-principal>guest</unauthenticated-principal>
      <enterprise-beans>

      <ejb-name>*</ejb-name>
      <jndi-name>*</jndi-name>
      true
      <cluster-config>
      <partition-name>DefaultPartition</partition-name>
      <bean-load-balance-policy>
      org.jboss.ha.framework.interfaces.RandomRobin
      </bean-load-balance-policy>
      </cluster-config>

      </enterprise-beans>


      or do I have to add all my EJBs explicitly which is not what I want?

      How can I know if an EJB is deployed as clustered? I checked the JMX console but could not find anything. The logs don't say anything. I also removed all the Clustered annotations apart from one EJB to see if there was some extra log info on that EJB differing from the rest which supposingly use the jboss.xml.

      The <security-domain>myRealm</security-domain>
      added each EJB to the security realm without any annotations which was very convinient since I use the same EJBs in different applications with different realms.

      Thanks in advance

        • 1. Re: Question about clustering
          thoism

          Sorry...here 's the XML

          <?xml version="1.0" encoding="utf-8"?>
          <!DOCTYPE jboss PUBLIC "-//JBoss//DTD JBOSS 4.0//EN" "http://www.jboss.org/j2ee/dtd/jboss_4_0.dtd">
          <jboss>
           <security-domain>nettellerRealm</security-domain>
           <unauthenticated-principal>guest</unauthenticated-principal>
           <enterprise-beans>
           <session>
           <ejb-name>*</ejb-name>
           <jndi-name>*</jndi-name>
           <clustered>true</clustered>
           <cluster-config>
           <partition-name>DefaultPartition</partition-name>
           <bean-load-balance-policy>
           org.jboss.ha.framework.interfaces.RandomRobin
           </bean-load-balance-policy>
           </cluster-config>
           </session>
           </enterprise-beans>
          </jboss>