-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
47 lines (40 loc) · 1.44 KB
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
import indexBuilder
from benchmark import benchmark
from displayResults import displayResults
from displayUseCases import displayUseCases
def configIndexAutoIncrement():
indexBuilder.dropIndex()
benchmark('Config1')
def configIndexUrl():
indexBuilder.indexUrl()
benchmark('Config2')
def configIndexPosts():
indexBuilder.dropUrlIndex()
indexBuilder.indexTagQuery("tag_query1")
indexBuilder.indexTagQuery("tag_query2")
indexBuilder.indexTagQuery("tag_query3")
benchmark('Config3')
def configIndexPost2Tag():
indexBuilder.dropTagQueryIndex("tag_query1")
indexBuilder.dropTagQueryIndex("tag_query2")
indexBuilder.dropTagQueryIndex("tag_query3")
indexBuilder.indexPost2Tag()
benchmark('Config4')
def configIndexAll():
indexBuilder.indexUrl()
indexBuilder.indexTagQuery("tag_query1")
indexBuilder.indexTagQuery("tag_query2")
indexBuilder.indexTagQuery("tag_query3")
benchmark('Config5')
def process():
print("=============================== BENCHMARK SUITE COMMENCING ===============================")
configIndexAutoIncrement()
configIndexUrl()
configIndexPosts()
configIndexPost2Tag()
configIndexAll()
print("================================= BENCHMARKING COMPLETED =================================\n\n\n\n\n")
print("================================== BENCHMARKING RESULTS ==================================")
displayResults()
displayUseCases()
process()