Skip to content

Commit

Permalink
Merge branch 'dev' into docs
Browse files Browse the repository at this point in the history
  • Loading branch information
perdelt committed Aug 6, 2024
2 parents 2418d61 + ebaa198 commit 9a7c1a1
Show file tree
Hide file tree
Showing 19 changed files with 28,502 additions and 8,727 deletions.
18 changes: 11 additions & 7 deletions benchbase.py
Original file line number Diff line number Diff line change
Expand Up @@ -176,13 +176,6 @@
'gpu': '',
#'kubernetes.io/hostname': 'cl-worker13'
})
if request_node_name is not None:
experiment.set_resources(
nodeSelector = {
'cpu': cpu_type,
'gpu': '',
'kubernetes.io/hostname': request_node_name
})
# persistent storage
#print(request_storage_type)
#if not request_storage_type is None:# and (request_storage_type == 'shared' or request_storage_type == 'local-hdd'):
Expand Down Expand Up @@ -232,6 +225,15 @@
kubernetes.io/hostname: {node}
""".format(node=request_node_benchmarking))
experiment.workload['info'] = experiment.workload['info']+" Benchmarking is fixed to {}.".format(request_node_benchmarking)
# fix SUT
if not request_node_name is None:
experiment.set_resources(
nodeSelector = {
'cpu': cpu_type,
'gpu': '',
'kubernetes.io/hostname': request_node_name
})
experiment.workload['info'] = experiment.workload['info']+" SUT is fixed to {}.".format(request_node_name)
# add labels about the use case
experiment.set_additional_labels(
usecase="benchbase_tpcc",
Expand Down Expand Up @@ -459,6 +461,8 @@
end = default_timer()
end_datetime = str(datetime.datetime.now())
duration_experiment = end - start
elif args.mode == 'summary':
experiment.show_summary()
else:
# configure number of clients per config
#list_clients = args.num_query_executors.split(",")
Expand Down
302 changes: 302 additions & 0 deletions docs/Example-Benchbase.md

Large diffs are not rendered by default.

301 changes: 301 additions & 0 deletions docs/Example-HammerDB.md

Large diffs are not rendered by default.

316 changes: 153 additions & 163 deletions docs/Example-TPC-H.md

Large diffs are not rendered by default.

935 changes: 769 additions & 166 deletions docs/TestCases.md

Large diffs are not rendered by default.

43 changes: 35 additions & 8 deletions hammerdb.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"""
# argparse
parser = argparse.ArgumentParser(description=description)
parser.add_argument('mode', help='start sut, also load data or also run the TPC-C queries', choices=['run', 'start', 'load'])
parser.add_argument('mode', help='start sut, also load data or also run the TPC-C queries', choices=['run', 'start', 'load', 'summary'])
parser.add_argument('-aws', '--aws', help='fix components to node groups at AWS', action='store_true', default=False)
parser.add_argument('-dbms', help='DBMS to load the data', choices=['PostgreSQL', 'MonetDB', 'SingleStore', 'CockroachDB', 'MySQL', 'MariaDB', 'YugabyteDB', 'Kinetica'])
parser.add_argument('-db', '--debug', help='dump debug informations', action='store_true')
Expand Down Expand Up @@ -59,6 +59,8 @@
parser.add_argument('-rst', '--request-storage-type', help='request persistent storage of certain type', default=None, choices=[None, '', 'local-hdd', 'shared'])
parser.add_argument('-rss', '--request-storage-size', help='request persistent storage of certain size', default='10Gi')
parser.add_argument('-rnn', '--request-node-name', help='request a specific node', default=None)
parser.add_argument('-rnl', '--request-node-loading', help='request a specific node', default=None)
parser.add_argument('-rnb', '--request-node-benchmarking', help='request a specific node', default=None)
parser.add_argument('-tr', '--test-result', help='test if result fulfills some basic requirements', action='store_true', default=False)
# evaluate args
args = parser.parse_args()
Expand Down Expand Up @@ -102,6 +104,8 @@
request_storage_type = args.request_storage_type
request_storage_size = args.request_storage_size
request_node_name = args.request_node_name
request_node_loading = args.request_node_loading
request_node_benchmarking = args.request_node_benchmarking
datatransfer = args.datatransfer
test_result = args.test_result
code = args.experiment
Expand Down Expand Up @@ -163,13 +167,6 @@
'gpu': '',
#'kubernetes.io/hostname': 'cl-worker13'
})
if request_node_name is not None:
experiment.set_resources(
nodeSelector = {
'cpu': cpu_type,
'gpu': '',
'kubernetes.io/hostname': request_node_name
})
# persistent storage
#print(request_storage_type)
#if not request_storage_type is None:# and (request_storage_type == 'shared' or request_storage_type == 'local-hdd'):
Expand All @@ -193,6 +190,34 @@
if len(args.dbms):
# import is limited to single DBMS
experiment.workload['info'] = experiment.workload['info']+" Benchmark is limited to DBMS {}.".format(args.dbms)
if not request_node_loading is None:
experiment.patch_loading(patch="""
spec:
template:
spec:
nodeSelector:
kubernetes.io/hostname: {node}
""".format(node=request_node_loading))
experiment.workload['info'] = experiment.workload['info']+" Loading is fixed to {}.".format(request_node_loading)
# fix benchmarking
if not request_node_benchmarking is None:
experiment.patch_benchmarking(patch="""
spec:
template:
spec:
nodeSelector:
kubernetes.io/hostname: {node}
""".format(node=request_node_benchmarking))
experiment.workload['info'] = experiment.workload['info']+" Benchmarking is fixed to {}.".format(request_node_benchmarking)
# fix SUT
if not request_node_name is None:
experiment.set_resources(
nodeSelector = {
'cpu': cpu_type,
'gpu': '',
'kubernetes.io/hostname': request_node_name
})
experiment.workload['info'] = experiment.workload['info']+" SUT is fixed to {}.".format(request_node_name)
# add labels about the use case
experiment.set_additional_labels(
usecase="hammerdb_tpcc",
Expand Down Expand Up @@ -302,6 +327,8 @@
end = default_timer()
end_datetime = str(datetime.datetime.now())
duration_experiment = end - start
elif args.mode == 'summary':
experiment.show_summary()
else:
# configure number of clients per config
#list_clients = args.num_query_executors.split(",")
Expand Down
Loading

0 comments on commit 9a7c1a1

Please sign in to comment.