Package com.yahoo.ycsb.generator

Examples of com.yahoo.ycsb.generator.CounterGenerator


    else
    {
      orderedinserts=true;
    }

    keysequence=new CounterGenerator(insertstart);
    operationchooser=new DiscreteGenerator();
    if (readproportion>0)
    {
      operationchooser.addValue(readproportion,"READ");
    }

    if (updateproportion>0)
    {
      operationchooser.addValue(updateproportion,"UPDATE");
    }

    if (insertproportion>0)
    {
      operationchooser.addValue(insertproportion,"INSERT");
    }
   
    if (scanproportion>0)
    {
      operationchooser.addValue(scanproportion,"SCAN");
    }
   
    if (readmodifywriteproportion>0)
    {
      operationchooser.addValue(readmodifywriteproportion,"READMODIFYWRITE");
    }

    transactioninsertkeysequence=new CounterGenerator(recordcount);
    if (requestdistrib.compareTo("uniform")==0)
    {
      keychooser=new UniformIntegerGenerator(0,recordcount-1);
    }
    else if (requestdistrib.compareTo("zipfian")==0)
View Full Code Here


      orderedinserts = false;
    } else {
      orderedinserts = true;
    }

    keysequence = new CounterGenerator(insertstart);
    operationchooser = new DiscreteGenerator();
    if (Config.getConfig().read_proportion > 0) {
      operationchooser.addValue(Config.getConfig().read_proportion, "READ");
    }

    if (Config.getConfig().update_proportion > 0) {
      operationchooser.addValue(Config.getConfig().update_proportion, "UPDATE");
    }

    if (Config.getConfig().insert_proportion > 0) {
      operationchooser.addValue(Config.getConfig().insert_proportion, "INSERT");
    }

    if (Config.getConfig().scan_proportion > 0) {
      operationchooser.addValue(Config.getConfig().scan_proportion, "SCAN");
    }

    if (Config.getConfig().read_write_modify_proportion > 0) {
      operationchooser.addValue(Config.getConfig().read_write_modify_proportion, "READMODIFYWRITE");
    }

    transactioninsertkeysequence = new CounterGenerator(recordcount);
    if (Config.getConfig().request_distribution.compareTo("uniform") == 0) {
      keychooser = new UniformIntegerGenerator(0, recordcount - 1);
    } else if (Config.getConfig().request_distribution.compareTo("zipfian") == 0) {
      // it does this by generating a random "next key" in part by taking
      // the modulus over the number of keys
View Full Code Here

      orderedinserts = false;
    } else {
      orderedinserts = true;
    }

    keysequence = new CounterGenerator(insertstart);
    operationchooser = new DiscreteGenerator();
   
    if (Config.getConfig().memadd_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memadd_proportion, "ADD");
    }
    if (Config.getConfig().memappend_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memappend_proportion, "APPEND");
    }
    if (Config.getConfig().memcas_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memcas_proportion, "CAS");
    }
    if (Config.getConfig().memdecr_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memdecr_proportion, "DECR");
    }
    if (Config.getConfig().memdelete_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memdelete_proportion, "DELETE");
    }
    if (Config.getConfig().memget_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memget_proportion, "GET");
    }
    if (Config.getConfig().memgets_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memgets_proportion, "GETS");
    }
    if (Config.getConfig().memincr_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memincr_proportion, "INCR");
    }
    if (Config.getConfig().memprepend_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memprepend_proportion, "PREPEND");
    }
    if (Config.getConfig().memreplace_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memreplace_proportion, "REPLACE");
    }
    if (Config.getConfig().memset_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memset_proportion, "SET");
    }
    if (Config.getConfig().memupdate_proportion > 0) {
      operationchooser.addValue(Config.getConfig().memupdate_proportion, "UPDATE");
    }
   
    transactioninsertkeysequence = new CounterGenerator(recordcount);
    if (Config.getConfig().request_distribution.compareTo("uniform") == 0) {
      keychooser = new UniformIntegerGenerator(0, recordcount - 1);
    } else if (Config.getConfig().request_distribution.compareTo("zipfian") == 0) {
      // it does this by generating a random "next key" in part by taking
      // the modulus over the number of keys
View Full Code Here

TOP

Related Classes of com.yahoo.ycsb.generator.CounterGenerator

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.