summaryrefslogtreecommitdiffstats
path: root/tests/storagebenchmark.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/storagebenchmark.cpp')
-rw-r--r--tests/storagebenchmark.cpp11
1 files changed, 3 insertions, 8 deletions
diff --git a/tests/storagebenchmark.cpp b/tests/storagebenchmark.cpp
index 130753f..33898d3 100644
--- a/tests/storagebenchmark.cpp
+++ b/tests/storagebenchmark.cpp
@@ -93,16 +93,11 @@ private Q_SLOTS:
93 93
94 time.start(); 94 time.start();
95 { 95 {
96 auto event = createEvent(); 96 auto event = std::string(500, '1');//createEvent();
97
98 if (store) store->startTransaction();
97 for (int i = 0; i < count; i++) { 99 for (int i = 0; i < count; i++) {
98 if (store) { 100 if (store) {
99 if (i % 10000 == 0) {
100 if (i > 0) {
101 store->commitTransaction();
102 }
103 store->startTransaction();
104 }
105
106 store->write(keyPrefix + std::to_string(i), event); 101 store->write(keyPrefix + std::to_string(i), event);
107 } else { 102 } else {
108 myfile << event; 103 myfile << event;