|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.yahoo.ycsb.Workload
com.yahoo.ycsb.workloads.CoreWorkload
public class CoreWorkload
The core benchmark scenario. Represents a set of clients doing simple CRUD operations. The relative proportion of different kinds of operations, and other properties of the workload, are controlled by parameters specified at runtime. Properties to control the client:
Field Summary | |
---|---|
static java.lang.String |
FIELD_COUNT_PROPERTY
The name of the property for the number of fields in a record. |
static java.lang.String |
FIELD_COUNT_PROPERTY_DEFAULT
Default number of fields in a record. |
static java.lang.String |
FIELD_LENGTH_PROPERTY
The name of the property for the length of a field in bytes. |
static java.lang.String |
FIELD_LENGTH_PROPERTY_DEFAULT
The default length of a field in bytes. |
static java.lang.String |
INSERT_ORDER_PROPERTY
The name of the property for the order to insert records. |
static java.lang.String |
INSERT_ORDER_PROPERTY_DEFAULT
Default insert order. |
static java.lang.String |
INSERT_PROPORTION_PROPERTY
The name of the property for the proportion of transactions that are inserts. |
static java.lang.String |
INSERT_PROPORTION_PROPERTY_DEFAULT
The default proportion of transactions that are inserts. |
static java.lang.String |
MAX_SCAN_LENGTH_PROPERTY
The name of the property for the max scan length (number of records) |
static java.lang.String |
MAX_SCAN_LENGTH_PROPERTY_DEFAULT
The default max scan length. |
static java.lang.String |
READ_ALL_FIELDS_PROPERTY
The name of the property for deciding whether to read one field (false) or all fields (true) of a record. |
static java.lang.String |
READ_ALL_FIELDS_PROPERTY_DEFAULT
The default value for the readallfields property. |
static java.lang.String |
READ_PROPORTION_PROPERTY
The name of the property for the proportion of transactions that are reads. |
static java.lang.String |
READ_PROPORTION_PROPERTY_DEFAULT
The default proportion of transactions that are reads. |
static java.lang.String |
READMODIFYWRITE_PROPORTION_PROPERTY
The name of the property for the proportion of transactions that are read-modify-write. |
static java.lang.String |
READMODIFYWRITE_PROPORTION_PROPERTY_DEFAULT
The default proportion of transactions that are scans. |
static java.lang.String |
REQUEST_DISTRIBUTION_PROPERTY
The name of the property for the the distribution of requests across the keyspace. |
static java.lang.String |
REQUEST_DISTRIBUTION_PROPERTY_DEFAULT
The default distribution of requests across the keyspace |
static java.lang.String |
SCAN_LENGTH_DISTRIBUTION_PROPERTY
The name of the property for the scan length distribution. |
static java.lang.String |
SCAN_LENGTH_DISTRIBUTION_PROPERTY_DEFAULT
The default max scan length. |
static java.lang.String |
SCAN_PROPORTION_PROPERTY
The name of the property for the proportion of transactions that are scans. |
static java.lang.String |
SCAN_PROPORTION_PROPERTY_DEFAULT
The default proportion of transactions that are scans. |
static java.lang.String |
TABLENAME
The name of the database table to run queries against. |
static java.lang.String |
UPDATE_PROPORTION_PROPERTY
The name of the property for the proportion of transactions that are updates. |
static java.lang.String |
UPDATE_PROPORTION_PROPERTY_DEFAULT
The default proportion of transactions that are updates. |
Fields inherited from class com.yahoo.ycsb.Workload |
---|
INSERT_START_PROPERTY, INSERT_START_PROPERTY_DEFAULT |
Constructor Summary | |
---|---|
CoreWorkload()
|
Method Summary | |
---|---|
boolean |
doInsert(DB db,
java.lang.Object threadstate)
Do one insert operation. |
boolean |
doTransaction(DB db,
java.lang.Object threadstate)
Do one transaction operation. |
void |
doTransactionInsert(DB db)
|
void |
doTransactionRead(DB db)
|
void |
doTransactionReadModifyWrite(DB db)
|
void |
doTransactionScan(DB db)
|
void |
doTransactionUpdate(DB db)
|
void |
init(java.util.Properties p)
Initialize the scenario. |
Methods inherited from class com.yahoo.ycsb.Workload |
---|
cleanup, initThread |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String TABLENAME
public static final java.lang.String FIELD_COUNT_PROPERTY
public static final java.lang.String FIELD_COUNT_PROPERTY_DEFAULT
public static final java.lang.String FIELD_LENGTH_PROPERTY
public static final java.lang.String FIELD_LENGTH_PROPERTY_DEFAULT
public static final java.lang.String READ_ALL_FIELDS_PROPERTY
public static final java.lang.String READ_ALL_FIELDS_PROPERTY_DEFAULT
public static final java.lang.String READ_PROPORTION_PROPERTY
public static final java.lang.String READ_PROPORTION_PROPERTY_DEFAULT
public static final java.lang.String UPDATE_PROPORTION_PROPERTY
public static final java.lang.String UPDATE_PROPORTION_PROPERTY_DEFAULT
public static final java.lang.String INSERT_PROPORTION_PROPERTY
public static final java.lang.String INSERT_PROPORTION_PROPERTY_DEFAULT
public static final java.lang.String SCAN_PROPORTION_PROPERTY
public static final java.lang.String SCAN_PROPORTION_PROPERTY_DEFAULT
public static final java.lang.String READMODIFYWRITE_PROPORTION_PROPERTY
public static final java.lang.String READMODIFYWRITE_PROPORTION_PROPERTY_DEFAULT
public static final java.lang.String REQUEST_DISTRIBUTION_PROPERTY
public static final java.lang.String REQUEST_DISTRIBUTION_PROPERTY_DEFAULT
public static final java.lang.String MAX_SCAN_LENGTH_PROPERTY
public static final java.lang.String MAX_SCAN_LENGTH_PROPERTY_DEFAULT
public static final java.lang.String SCAN_LENGTH_DISTRIBUTION_PROPERTY
public static final java.lang.String SCAN_LENGTH_DISTRIBUTION_PROPERTY_DEFAULT
public static final java.lang.String INSERT_ORDER_PROPERTY
public static final java.lang.String INSERT_ORDER_PROPERTY_DEFAULT
Constructor Detail |
---|
public CoreWorkload()
Method Detail |
---|
public void init(java.util.Properties p) throws WorkloadException
init
in class Workload
WorkloadException
public boolean doInsert(DB db, java.lang.Object threadstate)
doInsert
in class Workload
public boolean doTransaction(DB db, java.lang.Object threadstate)
doTransaction
in class Workload
public void doTransactionRead(DB db)
public void doTransactionReadModifyWrite(DB db)
public void doTransactionScan(DB db)
public void doTransactionUpdate(DB db)
public void doTransactionInsert(DB db)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |