Package org.makersoft.shards.strategy.reduce

Examples of org.makersoft.shards.strategy.reduce.ShardReduceStrategy


  @Override
  public ShardStrategy newShardStrategy(List<ShardId> shardIds) {
    ShardSelectionStrategy pss = this.getShardSelectionStrategy(shardIds);
    ShardResolutionStrategy prs = this.getShardResolutionStrategy(shardIds);
    ShardAccessStrategy pas = this.getShardAccessStrategy();
    ShardReduceStrategy srs = this.getShardReduceStrategy();
    return new ShardStrategyImpl(pss, prs, pas, srs);
  }
View Full Code Here


   
//    return new SequentialShardAccessStrategy();
  }
 
  private ShardReduceStrategy getShardReduceStrategy() {
    return new ShardReduceStrategy() {
     
      @Override
      public List<Object> reduce(String statement, Object parameter, RowBounds rowBounds,
          List<Object> values) {
        if(statement.endsWith("getAllCount")){
View Full Code Here

            };

            ShardResolutionStrategy prs = new AllShardsShardResolutionStrategy(shardIds);
            ShardAccessStrategy pas = new SequentialShardAccessStrategy();

            ShardReduceStrategy srs = new ShardReduceStrategy() {

              @Override
              public List<Object> reduce(String statement, Object parameter,
                  RowBounds rowBounds, List<Object> values) {
                return values;
View Full Code Here

  @Override
  public ShardStrategy newShardStrategy(List<ShardId> shardIds) {
    ShardSelectionStrategy pss = this.getShardSelectionStrategy(shardIds);
    ShardResolutionStrategy prs = this.getShardResolutionStrategy(shardIds);
    ShardAccessStrategy pas = this.getShardAccessStrategy();
    ShardReduceStrategy srs = this.getShardReduceStrategy();
    return new ShardStrategyImpl(pss, prs, pas, srs);
  }
View Full Code Here

   
//    return new SequentialShardAccessStrategy();
  }
 
  private ShardReduceStrategy getShardReduceStrategy() {
    return new ShardReduceStrategy() {
     
      @Override
      public List<Object> reduce(String statement, Object parameter, RowBounds rowBounds,
          List<Object> values) {
        if(statement.endsWith("getAllCount")){
View Full Code Here

  @Override
  public ShardStrategy newShardStrategy(List<ShardId> shardIds) {
    ShardSelectionStrategy pss = this.getShardSelectionStrategy(shardIds);
    ShardResolutionStrategy prs = this.getShardResolutionStrategy(shardIds);
    ShardAccessStrategy pas = this.getShardAccessStrategy();
    ShardReduceStrategy srs = this.getShardReduceStrategy();
    return new ShardStrategyImpl(pss, prs, pas, srs);
  }
View Full Code Here

    return new ParallelShardAccessStrategy(exec);
  }
 
  private ShardReduceStrategy getShardReduceStrategy() {
    return new ShardReduceStrategy() {
     
      @Override
      public List<Object> reduce(String statement, Object parameter, RowBounds rowBounds,
          List<Object> values) {
        if(statement.endsWith("getAllCount")){
View Full Code Here

TOP

Related Classes of org.makersoft.shards.strategy.reduce.ShardReduceStrategy

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.