mirror of
https://github.com/nosqlbench/nosqlbench.git
synced 2025-02-25 18:55:28 -06:00
passthru for correct vector types, op updates, runner update
This commit is contained in:
@@ -1,12 +1,12 @@
|
|||||||
<component name="ProjectRunConfigurationManager">
|
<component name="ProjectRunConfigurationManager">
|
||||||
<configuration default="false" name="astra DAPI schema collection=baselines" type="JarApplication" folderName="Astra DAPI">
|
<configuration default="false" name="SCENARIO astra DAPI dapi_novector" type="JarApplication" folderName="Astra DAPI">
|
||||||
<extension name="software.aws.toolkits.jetbrains.core.execution.JavaAwsConnectionExtension">
|
<extension name="software.aws.toolkits.jetbrains.core.execution.JavaAwsConnectionExtension">
|
||||||
<option name="credential" />
|
<option name="credential" />
|
||||||
<option name="region" />
|
<option name="region" />
|
||||||
<option name="useCurrentConnection" value="false" />
|
<option name="useCurrentConnection" value="false" />
|
||||||
</extension>
|
</extension>
|
||||||
<option name="JAR_PATH" value="$PROJECT_DIR$/nb5/target/nb5.jar" />
|
<option name="JAR_PATH" value="$PROJECT_DIR$/nb5/target/nb5.jar" />
|
||||||
<option name="PROGRAM_PARAMETERS" value="astra_kv_dapi default.schema collection=baselines astraTokenFile=target/token astraApiEndpointFile=target/endpoint -v" />
|
<option name="PROGRAM_PARAMETERS" value="astra_kv_dapi dapi_novector collection=baselines astraTokenFile=target/token astraApiEndpointFile=target/endpoint -v" />
|
||||||
<option name="WORKING_DIRECTORY" value="$ProjectFileDir$/local/dataapi" />
|
<option name="WORKING_DIRECTORY" value="$ProjectFileDir$/local/dataapi" />
|
||||||
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="true" />
|
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="true" />
|
||||||
<option name="ALTERNATIVE_JRE_PATH" value="21" />
|
<option name="ALTERNATIVE_JRE_PATH" value="21" />
|
||||||
@@ -137,6 +137,9 @@ public abstract class DataApiOpDispenser extends BaseOpDispenser<DataApiBaseOp,
|
|||||||
|
|
||||||
protected float[] getVectorValues(Object rawVectorValues) {
|
protected float[] getVectorValues(Object rawVectorValues) {
|
||||||
float[] floatValues;
|
float[] floatValues;
|
||||||
|
if (rawVectorValues instanceof float[] f) {
|
||||||
|
return f;
|
||||||
|
}
|
||||||
if (rawVectorValues instanceof String) {
|
if (rawVectorValues instanceof String) {
|
||||||
String[] rawValues = (((String) rawVectorValues).split(","));
|
String[] rawValues = (((String) rawVectorValues).split(","));
|
||||||
floatValues = new float[rawValues.length];
|
floatValues = new float[rawValues.length];
|
||||||
|
|||||||
@@ -11,11 +11,29 @@ description: |
|
|||||||
TEMPLATE(valuecount,TEMPLATE(cardinality))
|
TEMPLATE(valuecount,TEMPLATE(cardinality))
|
||||||
|
|
||||||
scenarios:
|
scenarios:
|
||||||
default:
|
dapi_novector:
|
||||||
schema: run driver=dataapi tags==block:schema threads==1 cycles==UNDEF
|
schema: run driver=dataapi tags==block:schema threads==1 cycles==UNDEF
|
||||||
rampup: run driver=dataapi tags==block:rampup cycles===TEMPLATE(rampup-cycles,1000) threads=auto
|
rampup: >-
|
||||||
rampup_vector: run driver=dataapi tags==block:rampup_vector cycles===TEMPLATE(rampup-cycles,TEMPLATE(cardinality)) threads=auto
|
run driver=dataapi tags==block:rampup
|
||||||
find_key: run driver=dataapi tags==block:find_key cycles===TEMPLATE(main-cycles,1000) threads=auto
|
cycles===TEMPLATE(rampup-cycles,TEMPLATE(cardinality))
|
||||||
|
threads=auto errors=count
|
||||||
|
find_key: >-
|
||||||
|
run driver=dataapi tags==block:find_key
|
||||||
|
cycles===TEMPLATE(main-cycles,1000)
|
||||||
|
threads=auto errors=count
|
||||||
|
|
||||||
|
dapi_vector_d1536:
|
||||||
|
schema_vector: run driver=dataapi tags==block:schema_vector threads==1 cycles==UNDEF
|
||||||
|
rampup_vector: >-
|
||||||
|
run driver=dataapi tags==block:rampup_vector
|
||||||
|
cycles===TEMPLATE(rampup-cycles,TEMPLATE(cardinality))
|
||||||
|
threads=auto errors=count
|
||||||
|
find_key_vector: >-
|
||||||
|
run driver=dataapi tags==block:find_key_vector
|
||||||
|
cycles===TEMPLATE(main-cycles,TEMPLATE(cardinality))
|
||||||
|
threads=auto errors=count
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# kv_dapi:
|
# kv_dapi:
|
||||||
# kv_dapi_schema: run driver=http tags==block:schema threads==1 cycles==UNDEF
|
# kv_dapi_schema: run driver=http tags==block:schema threads==1 cycles==UNDEF
|
||||||
@@ -35,17 +53,16 @@ bindings:
|
|||||||
# multiple weighted hosts: jsonapi_host=host1:3,host2:7
|
# multiple weighted hosts: jsonapi_host=host1:3,host2:7
|
||||||
weighted_hosts: WeightedStrings('TEMPLATE(jsonapi_host,TEMPLATE(stargate_host,localhost))')
|
weighted_hosts: WeightedStrings('TEMPLATE(jsonapi_host,TEMPLATE(stargate_host,localhost))')
|
||||||
|
|
||||||
seq_key: Mod(TEMPLATE(keycount); ToString() -> String
|
seq_key: Mod(TEMPLATE(keycount)); ToString() -> String
|
||||||
# seq_key: Mod(TEMPLATE(keycount,50000000000L));
|
# seq_key: Mod(TEMPLATE(keycount,50000000000L));
|
||||||
seq_value: Hash(); Mod(TEMPLATE(valuecount); ToString() -> String
|
seq_value: Hash(); Mod(TEMPLATE(valuecount)); ToString() -> String
|
||||||
# rw_key: TEMPLATE(keydist,Uniform(0,50000000000L));
|
# rw_key: TEMPLATE(keydist,Uniform(0,50000000000L));
|
||||||
rw_key: TEMPLATE(keydist,Uniform(0,TEMPLATE(keycount))); ToString() -> String
|
rw_key: TEMPLATE(keydist,Uniform(0,TEMPLATE(keycount))); ToString() -> String
|
||||||
rw_key_num: TEMPLATE(keydist,Uniform(0,TEMPLATE(keycount)));
|
rw_key_num: TEMPLATE(keydist,Uniform(0,TEMPLATE(keycount)));
|
||||||
rw_value: Hash(); TEMPLATE(valdist,Uniform(0,TEMPLATE(valuecount)); ToString() -> String
|
rw_value: Hash(); TEMPLATE(valdist,Uniform(0,TEMPLATE(valuecount))); ToString() -> String
|
||||||
vector_value: HashedFloatVectors(TEMPLATE(dimensions,1536));
|
vector_value: HashedFloatVectors(TEMPLATE(dimensions,1536));
|
||||||
|
|
||||||
request_id: ToHashedUUID(); ToString();
|
request_id: ToHashedUUID(); ToString();
|
||||||
token: Discard(); Token('TEMPLATE(auth_token)','TEMPLATE(uri,http://localhost:8081/v1/auth)', 'TEMPLATE(uid,cassandra)', 'TEMPLATE(pswd,cassandra)');
|
|
||||||
|
|
||||||
params:
|
params:
|
||||||
cl: TEMPLATE(cl,LOCAL_QUORUM)
|
cl: TEMPLATE(cl,LOCAL_QUORUM)
|
||||||
@@ -66,18 +83,16 @@ blocks:
|
|||||||
delete_collection: "TEMPLATE(collection)"
|
delete_collection: "TEMPLATE(collection)"
|
||||||
create_collection_op:
|
create_collection_op:
|
||||||
create_collection: "TEMPLATE(collection)"
|
create_collection: "TEMPLATE(collection)"
|
||||||
dimensions: TEMPLATE(dimensions)
|
|
||||||
similarity: TEMPLATE(similarity)
|
|
||||||
|
|
||||||
# separate these cases later, when you can recreate the same collection name with/without vector support
|
# separate these cases later, when you can recreate the same collection name with/without vector support
|
||||||
# schema_vector:
|
schema_vector:
|
||||||
# ops:
|
ops:
|
||||||
# delete_collection_op:
|
delete_collection_op_v:
|
||||||
# delete_collection: "TEMPLATE(collection)"
|
delete_collection: "TEMPLATE(collection)_v"
|
||||||
# create_collection_op:
|
create_collection_op_v:
|
||||||
# create_collection: "TEMPLATE(collection)"
|
create_collection: "TEMPLATE(collection)_v"
|
||||||
# dimensions: TEMPLATE(dimensions)
|
dimensions: TEMPLATE(dimensions)
|
||||||
# similarity: TEMPLATE(similarity)
|
similarity: TEMPLATE(similarity)
|
||||||
|
|
||||||
rampup:
|
rampup:
|
||||||
ops:
|
ops:
|
||||||
@@ -86,6 +101,16 @@ blocks:
|
|||||||
document:
|
document:
|
||||||
_id: "{seq_key}"
|
_id: "{seq_key}"
|
||||||
value: "{seq_value}"
|
value: "{seq_value}"
|
||||||
|
|
||||||
|
rampup_vector:
|
||||||
|
ops:
|
||||||
|
insert_one_op_v:
|
||||||
|
insert_one_vector: "TEMPLATE(collection)_v"
|
||||||
|
document:
|
||||||
|
_id: "{seq_key}"
|
||||||
|
value: "{seq_value}"
|
||||||
|
vector: "{vector_value}"
|
||||||
|
|
||||||
# rampup-uuid:
|
# rampup-uuid:
|
||||||
# ops:
|
# ops:
|
||||||
# insert_one_op:
|
# insert_one_op:
|
||||||
@@ -103,23 +128,22 @@ blocks:
|
|||||||
operator: "lt"
|
operator: "lt"
|
||||||
field: "_id"
|
field: "_id"
|
||||||
value: "{rw_key_num}"
|
value: "{rw_key_num}"
|
||||||
# schema_with_vector:
|
|
||||||
# ops:
|
|
||||||
# delete_collection_op:
|
|
||||||
# delete_collection: "TEMPLATE(collection)"
|
|
||||||
# create_collection_op:
|
|
||||||
# create_collection: "TEMPLATE(collection)"
|
|
||||||
# options:
|
|
||||||
# vector:
|
|
||||||
# size: 1536
|
|
||||||
rampup_vector:
|
|
||||||
ops:
|
|
||||||
insert_one_op:
|
|
||||||
insert_one_vector: "TEMPLATE(collection)"
|
|
||||||
vector: "{vector_value}"
|
vector: "{vector_value}"
|
||||||
document:
|
|
||||||
_id: "{seq_key}"
|
find_key_vector:
|
||||||
value: "{seq_value}"
|
params:
|
||||||
|
ratio: 5
|
||||||
|
ops:
|
||||||
|
find_op_v:
|
||||||
|
find_vector_filter: "TEMPLATE(collection)"
|
||||||
|
filters:
|
||||||
|
- conjunction: "and"
|
||||||
|
operator: "lt"
|
||||||
|
field: "_id"
|
||||||
|
value: "{rw_key_num}"
|
||||||
|
vector: "{vector_value}"
|
||||||
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# rampup_with_vector_uuid:
|
# rampup_with_vector_uuid:
|
||||||
# ops:
|
# ops:
|
||||||
|
|||||||
Reference in New Issue
Block a user