|
| 1 | +import unittest |
| 2 | +import subprocess |
| 3 | + |
| 4 | +class perf_goleveldb(unittest.TestCase): |
| 5 | + |
| 6 | + def test_FAB_3790_VaryNumParallelTxPerChain(self): |
| 7 | + ''' |
| 8 | + In this Performance test, we observe the the performance (time to |
| 9 | + complete a set number of Ledger operations) of the Ledger component, |
| 10 | + with goleveldb as the state database. We vary the number of parallel |
| 11 | + transactions per chain and observe the performance. |
| 12 | +
|
| 13 | + Passing criteria: all subtests (8) completed successfully |
| 14 | + ''' |
| 15 | + result = subprocess.check_output( |
| 16 | + "./runbenchmarks.sh varyNumParallelTxPerChain", |
| 17 | + shell=True, stderr=subprocess.STDOUT, |
| 18 | + cwd='../../tools/LTE/scripts') |
| 19 | + completion_count = result.count("PASS") |
| 20 | + self.assertEqual(completion_count, 8) |
| 21 | + |
| 22 | + def test_FAB_3795_VaryNumChain(self): |
| 23 | + ''' |
| 24 | + In this Performance test, we observe the the performance (time to |
| 25 | + complete a set number of Ledger operations) of the Ledger component, |
| 26 | + with goleveldb as the state database. We vary the number of chains |
| 27 | + (ledgers). |
| 28 | +
|
| 29 | + Passing criteria: all subtests (8) completed successfully |
| 30 | + ''' |
| 31 | + result = subprocess.check_output( |
| 32 | + "./runbenchmarks.sh varyNumChain", |
| 33 | + shell=True, stderr=subprocess.STDOUT, |
| 34 | + cwd='../../tools/LTE/scripts') |
| 35 | + completion_count = result.count("PASS") |
| 36 | + self.assertEqual(completion_count, 8) |
| 37 | + |
| 38 | + def test_FAB_3798_VaryNumParallelTxWithSingleChain(self): |
| 39 | + ''' |
| 40 | + In this Performance test, we observe the the performance (time to |
| 41 | + complete a set number of Ledger operations) of the Ledger component, |
| 42 | + with goleveldb as the state database. We vary the number of parallel |
| 43 | + transactions on a single chain. |
| 44 | +
|
| 45 | + Passing criteria: all subtests (8) completed successfully |
| 46 | + ''' |
| 47 | + result = subprocess.check_output( |
| 48 | + "./runbenchmarks.sh varyNumParallelTxWithSingleChain", |
| 49 | + shell=True, stderr=subprocess.STDOUT, |
| 50 | + cwd='../../tools/LTE/scripts') |
| 51 | + completion_count = result.count("PASS") |
| 52 | + self.assertEqual(completion_count, 8) |
| 53 | + |
| 54 | + def test_FAB_3799_VaryNumChainWithNoParallelism(self): |
| 55 | + ''' |
| 56 | + In this Performance test, we observe the the performance (time to |
| 57 | + complete a set number of Ledger operations) of the Ledger component, |
| 58 | + with goleveldb as the state database. We vary the number of chains |
| 59 | + without any parallelism within a single chain. |
| 60 | +
|
| 61 | + Passing criteria: all subtests (8) completed successfully |
| 62 | + ''' |
| 63 | + result = subprocess.check_output( |
| 64 | + "./runbenchmarks.sh varyNumChainWithNoParallelism", |
| 65 | + shell=True, stderr=subprocess.STDOUT, |
| 66 | + cwd='../../tools/LTE/scripts') |
| 67 | + completion_count = result.count("PASS") |
| 68 | + self.assertEqual(completion_count, 8) |
| 69 | + |
| 70 | + def test_FAB_3801_VaryKVSize(self): |
| 71 | + ''' |
| 72 | + In this Performance test, we observe the the performance (time to |
| 73 | + complete a set number of Ledger operations) of the Ledger component, |
| 74 | + with goleveldb as the state database. We vary the size of key-value. |
| 75 | +
|
| 76 | + Passing criteria: all subtests (5) completed successfully |
| 77 | + ''' |
| 78 | + result = subprocess.check_output( |
| 79 | + "./runbenchmarks.sh varyKVSize", |
| 80 | + shell=True, stderr=subprocess.STDOUT, |
| 81 | + cwd='../../tools/LTE/scripts') |
| 82 | + completion_count = result.count("PASS") |
| 83 | + self.assertEqual(completion_count, 5) |
| 84 | + |
| 85 | + def test_FAB_3802_VaryBatchSize(self): |
| 86 | + ''' |
| 87 | + In this Performance test, we observe the the performance (time to |
| 88 | + complete a set number of Ledger operations) of the Ledger component, |
| 89 | + with goleveldb as the state database. We vary the value of the batch |
| 90 | + size |
| 91 | +
|
| 92 | + Passing criteria: all subtests (4) completed successfully |
| 93 | + ''' |
| 94 | + result = subprocess.check_output( |
| 95 | + "./runbenchmarks.sh varyBatchSize", |
| 96 | + shell=True, stderr=subprocess.STDOUT, |
| 97 | + cwd='../../tools/LTE/scripts') |
| 98 | + completion_count = result.count("PASS") |
| 99 | + self.assertEqual(completion_count, 4) |
| 100 | + |
| 101 | + def test_FAB_3800_VaryNumKeysInEachTX(self): |
| 102 | + ''' |
| 103 | + In this Performance test, we observe the the performance (time to |
| 104 | + complete a set number of Ledger operations) of the Ledger component, |
| 105 | + with goleveldb as the state database. We vary the number of keys in |
| 106 | + each transaction. |
| 107 | +
|
| 108 | + Passing criteria: all subtests (5) completed successfully |
| 109 | + ''' |
| 110 | + result = subprocess.check_output( |
| 111 | + "./runbenchmarks.sh varyNumKeysInEachTX", |
| 112 | + shell=True, stderr=subprocess.STDOUT, |
| 113 | + cwd='../../tools/LTE/scripts') |
| 114 | + completion_count = result.count("PASS") |
| 115 | + self.assertEqual(completion_count, 5) |
| 116 | + |
| 117 | + def test_FAB_3803_VaryNumTxs(self): |
| 118 | + ''' |
| 119 | + In this Performance test, we observe the the performance (time to |
| 120 | + complete a set number of Ledger operations) of the Ledger component, |
| 121 | + with goleveldb as the state database. We vary the number of |
| 122 | + transactions carried out. |
| 123 | +
|
| 124 | + Passing criteria: all subtests (4) completed successfully |
| 125 | + ''' |
| 126 | + result = subprocess.check_output( |
| 127 | + "./runbenchmarks.sh varyNumTxs", |
| 128 | + shell=True, stderr=subprocess.STDOUT, |
| 129 | + cwd='../../tools/LTE/scripts') |
| 130 | + completion_count = result.count("PASS") |
| 131 | + self.assertEqual(completion_count, 4) |
| 132 | + |
| 133 | + |
| 134 | +class perf_couchdb(unittest.TestCase): |
| 135 | + @unittest.skip("WIP, skipping") |
| 136 | + def test_FAB_3870_VaryNumParallelTxPerChain(self): |
| 137 | + ''' |
| 138 | + In this Performance test, we observe the the performance (operations |
| 139 | + per second) of the Ledger component, with CouchDB as the state |
| 140 | + database, as we vary the number of parallel transactions per chain. |
| 141 | + ''' |
| 142 | + self.assertTrue(True) |
| 143 | + |
| 144 | + @unittest.skip("WIP, skipping") |
| 145 | + def test_FAB_3871_VaryNumChain(self): |
| 146 | + ''' |
| 147 | + In this Performance test, we observe the the performance (operations |
| 148 | + per second) of the Ledger component, with CouchDB as the state |
| 149 | + database, as we vary the number of chains (ledgers). |
| 150 | + ''' |
| 151 | + self.assertTrue(True) |
| 152 | + |
| 153 | + @unittest.skip("WIP, skipping") |
| 154 | + def test_FAB_3872_VaryNumParallelTxWithSingleChain(self): |
| 155 | + ''' |
| 156 | + In this Performance test, we observe the the performance (operations |
| 157 | + per second) of the Ledger component, with CouchDB as the state |
| 158 | + database, vary the number of parallel transactions on a single chain. |
| 159 | + ''' |
| 160 | + self.assertTrue(True) |
| 161 | + |
| 162 | + @unittest.skip("WIP, skipping") |
| 163 | + def test_FAB_3873_VaryNumChainWithNoParallelism(self): |
| 164 | + ''' |
| 165 | + In this Performance test, we observe the the performance (operations |
| 166 | + per second) of the Ledger component, with CouchDB as the state |
| 167 | + database, as we vary the number of chains without any parallelism. |
| 168 | + within a single chain. |
| 169 | + ''' |
| 170 | + self.assertTrue(True) |
| 171 | + |
| 172 | + @unittest.skip("WIP, skipping") |
| 173 | + def test_FAB_3874_VaryKVSize(self): |
| 174 | + ''' |
| 175 | + In this Performance test, we observe the the performance (operations |
| 176 | + per second) of the Ledger component, with CouchDB as the state |
| 177 | + database, varying the size of key-value. |
| 178 | + ''' |
| 179 | + self.assertTrue(True) |
| 180 | + |
| 181 | + @unittest.skip("WIP, skipping") |
| 182 | + def test_FAB_3875_VaryBatchSize(self): |
| 183 | + ''' |
| 184 | + In this Performance test, we observe the the performance (operations |
| 185 | + per second) of the Ledger component, with CouchDB as the state |
| 186 | + database, as we vary the value of the batch size. |
| 187 | + ''' |
| 188 | + self.assertTrue(True) |
| 189 | + |
| 190 | + @unittest.skip("WIP, skipping") |
| 191 | + def test_FAB_3876_VaryNumKeysInEachTX(self): |
| 192 | + ''' |
| 193 | + In this Performance test, we observe the the performance (operations |
| 194 | + per second) of the Ledger component, with CouchDB as the state |
| 195 | + database, as we vary the number of keys in each transaction. |
| 196 | + ''' |
| 197 | + self.assertTrue(True) |
| 198 | + |
| 199 | + @unittest.skip("WIP, skipping") |
| 200 | + def test_FAB_3877_VaryNumTxs(self): |
| 201 | + ''' |
| 202 | + In this Performance test, we observe the the performance (operations |
| 203 | + per second) of the Ledger component, with CouchDB as the state |
| 204 | + database, as we vary the number of transactions carried out. |
| 205 | + ''' |
| 206 | + self.assertTrue(True) |
0 commit comments