Package org.apache.helix.model.builder

Examples of org.apache.helix.model.builder.AutoModeISBuilder.assignInstanceAndState()


      break;
    }
    case CUSTOMIZED: {
      CustomModeISBuilder builder = new CustomModeISBuilder(resourceName);
      builder.setStateModel("MasterSlave").setNumPartitions(2).setNumReplica(2);
      builder
          .assignInstanceAndState(buildPartitionName(resourceName, 0), "localhost_12918", "MASTER")
          .assignInstanceAndState(buildPartitionName(resourceName, 0), "localhost_12919", "SLAVE")
          .assignInstanceAndState(buildPartitionName(resourceName, 1), "localhost_12918", "SLAVE")
          .assignInstanceAndState(buildPartitionName(resourceName, 1), "localhost_12919", "MASTER");
      idealState = builder.build();
View Full Code Here


    case CUSTOMIZED: {
      CustomModeISBuilder builder = new CustomModeISBuilder(resourceName);
      builder.setStateModel("MasterSlave")
              .setNumPartitions(2)
              .setNumReplica(2);
      builder.assignInstanceAndState(buildPartitionName(resourceName, 0), "localhost_12918", "MASTER")
              .assignInstanceAndState(buildPartitionName(resourceName, 0), "localhost_12919", "SLAVE")
              .assignInstanceAndState(buildPartitionName(resourceName, 1), "localhost_12918", "SLAVE")
              .assignInstanceAndState(buildPartitionName(resourceName, 1), "localhost_12919", "MASTER");
      idealState = builder.build();
      break;
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.