Package org.infinispan.commands.control

Examples of org.infinispan.commands.control.RehashControlCommand


   public LockControlCommand buildLockControlCommand(Collection keys, boolean implicit, Set<Flag> flags) {
      return new LockControlCommand(keys, cacheName, flags, implicit);
   }

   public RehashControlCommand buildRehashControlCommand(RehashControlCommand.Type type, Address sender, int viewId) {
      return new RehashControlCommand(cacheName, type, sender, viewId);
   }
View Full Code Here


      return new RehashControlCommand(cacheName, type, sender, viewId);
   }

   public RehashControlCommand buildRehashControlCommand(RehashControlCommand.Type type, Address sender,
         int viewId, Map<Object, InternalCacheValue> state, ConsistentHash oldCH, ConsistentHash newCH) {
      return new RehashControlCommand(cacheName, type, sender, viewId, state, oldCH, newCH);
   }
View Full Code Here

                  }
               }
            }
            break;
         case RehashControlCommand.COMMAND_ID:
            RehashControlCommand rcc = (RehashControlCommand) c;
            rcc.init(distributionManager, configuration, dataContainer, this);
            break;
         default:
            if (trace)
               log.trace("Nothing to initialize for command: " + c);
      }
View Full Code Here

   public RehashControlCommand buildRehashControlCommand(Address sender, Map<Object, InternalCacheValue> state) {
      return buildRehashControlCommand(PUSH_STATE, sender, state, null, null,  null);
   }

   public RehashControlCommand buildRehashControlCommandTxLog(Address sender, List<WriteCommand> commands) {
      return new RehashControlCommand(cacheName, DRAIN_TX, sender, commands, null, this);
   }
View Full Code Here

   public RehashControlCommand buildRehashControlCommandTxLog(Address sender, List<WriteCommand> commands) {
      return new RehashControlCommand(cacheName, DRAIN_TX, sender, commands, null, this);
   }

   public RehashControlCommand buildRehashControlCommandTxLogPendingPrepares(Address sender, List<PrepareCommand> commands) {
      return new RehashControlCommand(cacheName, DRAIN_TX_PREPARES, sender, null, commands, this);
  
View Full Code Here

  
  
   public RehashControlCommand buildRehashControlCommand(RehashControlCommand.Type type,
            Address sender, Map<Object, InternalCacheValue> state, ConsistentHash oldCH,
            ConsistentHash newCH, List<Address> leavers) {
      return new RehashControlCommand(cacheName, type, sender, state, oldCH, newCH, leavers, this);
   }
View Full Code Here

            break;
         case ClusteredGetCommand.COMMAND_ID:
            command = new ClusteredGetCommand();
            break;
         case RehashControlCommand.COMMAND_ID:
            command = new RehashControlCommand(transport);
            break;
         default:
            throw new CacheException("Unknown command id " + id + "!");
      }
      command.setParameters(id, parameters);
View Full Code Here

            break;
         case ClusteredGetCommand.COMMAND_ID:
            command = new ClusteredGetCommand();
            break;
         case RehashControlCommand.COMMAND_ID:
            command = new RehashControlCommand(transport);
            break;
         default:
            throw new CacheException("Unknown command id " + id + "!");
      }
      command.setParameters(id, parameters);
View Full Code Here

               // 5.  txLogger being enabled will cause ClusteredGetCommands to return uncertain responses.
  
               // 6.  pull state from everyone.
               Address myAddress = rpcManager.getTransport().getAddress();
              
               RehashControlCommand cmd = cf.buildRehashControlCommand(PULL_STATE_JOIN, myAddress, null, chOld, chNew,null);
               // TODO I should be able to process state chunks from different nodes simultaneously!!
               List<Address> addressesWhoMaySendStuff = getAddressesWhoMaySendStuff(chNew, configuration.getNumOwners());
               List<Response> resps = rpcManager.invokeRemotely(addressesWhoMaySendStuff, cmd, SYNCHRONOUS, configuration.getRehashRpcTimeout(), true);
  
               // 7.  Apply state
View Full Code Here

            }
         }
         if (configuration.isRehashEnabled()) {
            if (isReceiver) {
               Address myAddress = rpcManager.getTransport().getAddress();
               RehashControlCommand cmd = cf.buildRehashControlCommand(PULL_STATE_LEAVE, myAddress,
                        null, oldCH, newCH,leaversHandled);

               List<Address> addressesWhoMaySendStuff = getStateProviderTargets();
               log.debug("I {0} am pulling state from {1}", self, addressesWhoMaySendStuff);
               List<Response> resps = rpcManager.invokeRemotely(addressesWhoMaySendStuff, cmd,
View Full Code Here

TOP

Related Classes of org.infinispan.commands.control.RehashControlCommand

Copyright © 2018 www.massapicom. 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.