Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
RadimBaca committed Aug 5, 2024
2 parents 4055374 + e85b94e commit 435b4b3
Show file tree
Hide file tree
Showing 9 changed files with 19 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/main/java/vsb/baca/sql/benchmark/benchmark.java
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

public abstract class benchmark {
public static final int BEGIN_ORDER_ORDER_OF_MAGNITUDE_FOR_BDISTINCT = 1;
public static final int END_ORDER_OF_MAGNITUDE_FOR_BDISTINCT = 5;
public static final int END_ORDER_OF_MAGNITUDE_FOR_BDISTINCT = 4;
public static final int REPEAT_QUERY_N_TIMES = 3;

bench_config bconfig;
Expand Down
4 changes: 3 additions & 1 deletion src/main/java/vsb/baca/sql/benchmark/benchmark_hyper.java
Original file line number Diff line number Diff line change
Expand Up @@ -97,10 +97,12 @@ public benchmark_hyper(bench_config_hyper bench_config_hyper) {
@Override
public ArrayList<Pair<String, Integer>> generateBDistinctTableNames(String tab_prefix) {
ArrayList<Pair<String, Integer>> tableNames = new ArrayList<Pair<String, Integer>>();
for (int i = 2; i <= 5; i++) {
for (int i = BEGIN_ORDER_ORDER_OF_MAGNITUDE_FOR_BDISTINCT; i <= END_ORDER_OF_MAGNITUDE_FOR_BDISTINCT; i++) {
tableNames.add(new Pair(tab_prefix + (int) pow(10, i), (int) pow(10, i)));
tableNames.add(new Pair(tab_prefix + 3 * (int) pow(10, i), 3 * (int) pow(10, i)));
}
// tableNames.add(new Pair(tab_prefix + (int) pow(10, BEGIN_ORDER_ORDER_OF_MAGNITUDE_FOR_BDISTINCT), (int) pow(10, BEGIN_ORDER_ORDER_OF_MAGNITUDE_FOR_BDISTINCT)));
// tableNames.add(new Pair(tab_prefix + 3 * (int) pow(10, END_ORDER_OF_MAGNITUDE_FOR_BDISTINCT), 3 * (int) pow(10, END_ORDER_OF_MAGNITUDE_FOR_BDISTINCT)));
return tableNames;
}

Expand Down
1 change: 1 addition & 0 deletions src/main/java/vsb/baca/sql/hyper_agg_test.java
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ public static void run(String connection_string) throws Exception {
////////////////////////////////////////////
ArrayList<Integer> selectivity = new ArrayList<Integer>();
int init_sel = 1;
// for (int i = 0; i < 12; i++) {
for (int i = 0; i < 6; i++) {
selectivity.add(init_sel);
init_sel *= 2;
Expand Down
6 changes: 5 additions & 1 deletion src/main/java/vsb/baca/sql/mssql_agg_test.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ public static void run(String connection_string, String username, String passwor
////////////////////////////////////////////
ArrayList<Integer> selectivity = new ArrayList<Integer>();
int init_sel = 1;
for (int i = 0; i < 10; i++) {
// for (int i = 0; i < 12; i++) {
for (int i = 0; i < 6; i++) {
selectivity.add(init_sel);
init_sel *= 2;
}
Expand Down Expand Up @@ -103,6 +104,9 @@ private static void min_bp_test(ArrayList<Integer> selectivity) throws Exception

private static ArrayList<run_setup> generate_run_setups(ArrayList<Pair<String, String>> queriesNoPadding, ArrayList<Pair<String, String>> queriesPadding) {
ArrayList<run_setup> run_setups = new ArrayList<run_setup>();

// run_setups.add(new run_setup("R_row_", queriesNoPadding, "", bench_config.Padding.OFF, bench_config.Storage.ROW, bench_config.Parallelism.ON, config, mssql_agg_test.connection_string, mssql_agg_test.username, mssql_agg_test.password));

if (mssql_agg_test.storage.contains("row")) {
run_setups.add(new run_setup("R_row_", queriesNoPadding, "", bench_config.Padding.OFF, bench_config.Storage.ROW, bench_config.Parallelism.OFF, config, mssql_agg_test.connection_string, mssql_agg_test.username, mssql_agg_test.password));
run_setups.add(new run_setup("P_row_", queriesPadding, "", bench_config.Padding.ON, bench_config.Storage.ROW, bench_config.Parallelism.OFF, config, mssql_agg_test.connection_string, mssql_agg_test.username, mssql_agg_test.password));
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/vsb/baca/sql/mssql_rank_algorithm_test.java
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ public static void run(String connection_string, String username, String passwor
configs.add(new Config(Config.dbms.MSSQL, false, Config.rank_algorithm.LateralLimit));

for (Config config : configs) {
// run_setups.add(new run_setup("R_row_", queryFileNamesNoPadding, "", bench_config.Padding.OFF, bench_config.Storage.ROW, bench_config.Parallelism.ON, config, mssql_rank_algorithm_test.connection_string, mssql_rank_algorithm_test.username, mssql_rank_algorithm_test.password));

if (mssql_rank_algorithm_test.storage.contains("row")) {
run_setups.add(new run_setup("R_row_", queryFileNamesNoPadding, "", bench_config.Padding.OFF, bench_config.Storage.ROW, bench_config.Parallelism.OFF, config, mssql_rank_algorithm_test.connection_string, mssql_rank_algorithm_test.username, mssql_rank_algorithm_test.password));
run_setups.add(new run_setup("P_row_", queryFileNamesPadding, "", bench_config.Padding.ON, bench_config.Storage.ROW, bench_config.Parallelism.OFF, config, mssql_rank_algorithm_test.connection_string, mssql_rank_algorithm_test.username, mssql_rank_algorithm_test.password));
Expand Down
3 changes: 2 additions & 1 deletion src/main/java/vsb/baca/sql/oracle_agg_test.java
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ public static void run(String connection_string, String username, String passwor
////////////////////////////////////////////
ArrayList<Integer> selectivity = new ArrayList<Integer>();
int init_sel = 1;
for (int i = 0; i < 10; i++) {
// for (int i = 0; i < 12; i++) {
for (int i = 0; i < 6; i++) {
selectivity.add(init_sel);
init_sel *= 2;
}
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/vsb/baca/sql/oracle_rank_algorithm_test.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@ public static void run(String connection_string, String username, String passwor
run_setups.add(new run_setup("R_column_", queryFileNamesNoPadding, "", bench_config.Padding.OFF, bench_config.Storage.COLUMN, bench_config.Parallelism.ON, config, oracle_rank_algorithm_test.connection_string, oracle_rank_algorithm_test.username, oracle_rank_algorithm_test.password));
run_setups.add(new run_setup("P_column_", queryFileNamesPadding, "", bench_config.Padding.ON, bench_config.Storage.COLUMN, bench_config.Parallelism.ON, config, oracle_rank_algorithm_test.connection_string, oracle_rank_algorithm_test.username, oracle_rank_algorithm_test.password));
}

// run_setups.add(new run_setup("R_row_", queryFileNamesNoPadding, "", bench_config.Padding.OFF, bench_config.Storage.ROW, bench_config.Parallelism.ON, config, oracle_rank_algorithm_test.connection_string, oracle_rank_algorithm_test.username, oracle_rank_algorithm_test.password));
}

oracle_runner.prepare_run(run_setups, DROPINDEXES_FILENAME, CREATEINDEXES_FILENAME);
Expand Down
3 changes: 2 additions & 1 deletion src/main/java/vsb/baca/sql/postgre_agg_test.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ public static void run(String connection_string, String username, String passwor
////////////////////////////////////////////
ArrayList<Integer> selectivity = new ArrayList<Integer>();
int init_sel = 1;
for (int i = 0; i < 10; i++) {
// for (int i = 0; i < 12; i++) {
for (int i = 0; i < 6; i++) {
selectivity.add(init_sel);
init_sel *= 2;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ public static void run(String connection_string, String username, String passwor
run_setups.add(new run_setup("P_ROW_", queryFileNamesPadding, "", bench_config.Padding.ON, bench_config.Storage.ROW, bench_config.Parallelism.OFF, config, postgre_rank_algorithm_test.connection_string, postgre_rank_algorithm_test.username, postgre_rank_algorithm_test.password));
run_setups.add(new run_setup("R_ROW_", queryFileNamesNoPadding, "", bench_config.Padding.OFF, bench_config.Storage.ROW, bench_config.Parallelism.ON, config, postgre_rank_algorithm_test.connection_string, postgre_rank_algorithm_test.username, postgre_rank_algorithm_test.password));
run_setups.add(new run_setup("P_ROW_", queryFileNamesPadding, "", bench_config.Padding.ON, bench_config.Storage.ROW, bench_config.Parallelism.ON, config, postgre_rank_algorithm_test.connection_string, postgre_rank_algorithm_test.username, postgre_rank_algorithm_test.password));

}

postgre_runner.prepare_run(run_setups, DROPINDEXES_FILENAME, CREATEINDEXES_FILENAME);
Expand Down

0 comments on commit 435b4b3

Please sign in to comment.