Examples of Clustered


Examples of org.jboss.ejb3.annotation.Clustered

      return null;
   }
  
   protected void findPartitionName()
   {
      Clustered clustered = (Clustered) getAnnotation(Clustered.class);
      if (clustered == null)
      {
         partitionName = null;
         return;
      }
     
      String value = clustered.partition();
      try
      {
         String replacedValue = StringPropertyReplacer.replaceProperties(value);
         if (value != replacedValue)
         {           
View Full Code Here

Examples of org.jboss.ejb3.annotation.Clustered

      return null;
   }
  
   protected void findPartitionName()
   {
      Clustered clustered = (Clustered) getAnnotation(Clustered.class);
      if (clustered == null)
      {
         partitionName = null;
         return;
      }
     
      String value = clustered.partition();
      try
      {
         String replacedValue = StringPropertyReplacer.replaceProperties(value);
         if (value != replacedValue)
         {           
View Full Code Here

Examples of org.jboss.ejb3.annotation.Clustered

      return null;
   }
  
   protected void findPartitionName()
   {
      Clustered clustered = (Clustered) getAnnotation(Clustered.class);
      if (clustered == null)
      {
         partitionName = null;
         return;
      }
     
      String value = clustered.partition();
      try
      {
         String replacedValue = StringPropertyReplacer.replaceProperties(value);
         if (value != replacedValue)
         {           
View Full Code Here

Examples of org.jboss.ejb3.annotation.Clustered

      return null;
   }
  
   protected void findPartitionName()
   {
      Clustered clustered = (Clustered) getAnnotation(Clustered.class);
      if (clustered == null)
      {
         partitionName = null;
         return;
      }
     
      String value = clustered.partition();
      try
      {
         String replacedValue = StringPropertyReplacer.replaceProperties(value);
         if (value != replacedValue)
         {           
View Full Code Here

Examples of org.jboss.ejb3.annotation.Clustered

      BaseStatelessRemoteProxyFactory factory = (BaseStatelessRemoteProxyFactory) this.proxyDeployer
            .getProxyFactory(binding);

      if (factory == null)
      {
         Clustered clustered = getAnnotation(Clustered.class);
         if (clustered != null)
            factory = new StatelessClusterProxyFactory(this, binding, clustered);
         else
            factory = new StatelessRemoteProxyFactory(this, binding);
        
View Full Code Here

Examples of org.jboss.ejb3.annotation.Clustered

            .getProxyFactory(binding);

      if (factory == null)
      {

         Clustered clustered = getAnnotation(Clustered.class);
         if (clustered != null)
         {
            factory = new StatefulClusterProxyFactory(this, binding, clustered);
         }
         else
View Full Code Here

Examples of org.jboss.ejb3.annotation.Clustered

      return null;
   }
  
   protected void findPartitionName()
   {
      Clustered clustered = (Clustered) getAnnotation(Clustered.class);
      if (clustered == null)
      {
         partitionName = null;
         return;
      }
     
      String value = clustered.partition();
      try
      {
         String replacedValue = StringPropertyReplacer.replaceProperties(value);
         if (value != replacedValue)
         {           
View Full Code Here

Examples of org.jboss.ejb3.annotation.Clustered

            .getProxyFactory(binding);

      if (factory == null)
      {

         Clustered clustered = getAnnotation(Clustered.class);
         if (clustered != null)
         {
            factory = new StatefulClusterProxyFactory(this, binding, clustered);
         }
         else
View Full Code Here

Examples of org.jboss.ejb3.annotation.Clustered

      BaseStatelessRemoteProxyFactory factory = (BaseStatelessRemoteProxyFactory) this.proxyDeployer
            .getProxyFactory(binding);

      if (factory == null)
      {
         Clustered clustered = getAnnotation(Clustered.class);
         if (clustered != null)
            factory = new StatelessClusterProxyFactory(this, binding, clustered);
         else
            factory = new StatelessRemoteProxyFactory(this, binding);
        
View Full Code Here

Examples of org.radargun.traits.Clustered

    * @param reachable
    */
   public static void start(SlaveState slaveState, boolean validate, Integer expectedSlaves, long clusterFormationTimeout,
                            Set<Integer> reachable) {
      Lifecycle lifecycle = slaveState.getTrait(Lifecycle.class);
      Clustered clustered = slaveState.getTrait(Clustered.class);
      Partitionable partitionable = slaveState.getTrait(Partitionable.class);
      try {
         if (partitionable != null) {
            partitionable.setStartWithReachable(slaveState.getSlaveIndex(), reachable);
         }
         for (ServiceListener listener : slaveState.getServiceListeners()) {
            listener.beforeServiceStart();
         }
         long startingTime = System.currentTimeMillis();
         lifecycle.start();
         long startedTime = System.currentTimeMillis();
         slaveState.getTimeline().addEvent(LifecycleHelper.LIFECYCLE, new Timeline.IntervalEvent(startingTime, "Start", startedTime - startingTime));
         if (validate && clustered != null) {

            int expectedNumberOfSlaves = expectedSlaves != null ? expectedSlaves : slaveState.getGroupSize();

            long clusterFormationDeadline = System.currentTimeMillis() + clusterFormationTimeout;
            for (;;) {
               int numMembers = clustered.getClusteredNodes();
               if (numMembers != expectedNumberOfSlaves) {
                  String msg = "Number of members=" + numMembers + " is not the one expected: " + expectedNumberOfSlaves;
                  log.info(msg);
                  try {
                     Thread.sleep(1000);
                  } catch (InterruptedException ie) {
                     Thread.currentThread().interrupt();
                  }
                  if (System.currentTimeMillis() > clusterFormationDeadline) {
                     throw new ClusterFormationTimeoutException(msg);
                  }
               } else {
                  log.info("Number of members is the one expected: " + clustered.getClusteredNodes());
                  break;
               }
            }
         }
         for (ServiceListener listener : slaveState.getServiceListeners()) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.