ssbc / ssb-db2

A new database for secure-scuttlebutt
47 stars 8 forks source link

Update ssb-box2 #398

Closed mixmix closed 1 year ago

mixmix commented 2 years ago

noticed the bundled dependency was outdated, so updated Also updated other deps (minor versions)

mixmix commented 2 years ago

failing test, not sure why, don't have time today

github-actions[bot] commented 2 years ago

Benchmark results

Part Duration
Create 5000 new messages 345.77ms
Validate 5000 messages 412.56ms
Native to db format 5000 messages 109.19ms
Db to native format 5000 messages 77.89ms
Add 1000 elements 352.53ms
Add 1000 box1 msgs 841.08ms
Unbox 1000 box1 msgs first run 200.09ms
Unbox 1000 box1 msgs second run 98.44ms
Add 1000 box1 msgs 823.98ms
Query 1000 msgs first run 37.62ms
Query 1000 msgs second run 12.40ms
Add 1000 box2 msgs 1235.48ms
Unbox 1000 box2 msgs first run 297.76ms
Unbox 1000 box2 msgs second run 168.97ms
Migrate (+db1) 11662.72ms
Migrate (alone) 4160.46ms
Migrate (+db1 +db2) 7707.27ms
Migrate (+db2) 6027.98ms
Migrate continuation (+db2) 847.96ms
Memory usage without indexes 749.81 MB = 43.33 MB + etc
Initial indexing 1518.57ms
Initial indexing maxcpu=86 5852.50ms
Initial indexing compat 569.12ms
Two indexes updating concurrently 2592.75ms
Key one initial 45.97ms
Key two 1.27ms
Key one again 0.83ms
Reboot and key one again 45.85ms
Latest root posts 1656.77ms
Latest posts 10.83ms
Votes one initial 1330.56ms
Votes again 0.69ms
HasRoot 1193.83ms
HasRoot again 0.32ms
Author one posts 1266.08ms
Author two posts 16.97ms
Dedicated author one posts 1379.93ms
Dedicated author one posts again 0.87ms
DeleteFeed 2809.73ms
Maximum memory usage 1005.57 MB = 63.11 MB + etc
Indexes folder size 10.01mb
github-actions[bot] commented 2 years ago

Benchmark results

Part Duration
Create 5000 new messages 366.63ms
Validate 5000 messages 464.12ms
Native to db format 5000 messages 120.35ms
Db to native format 5000 messages 91.79ms
Add 1000 elements 367.48ms
Add 1000 box1 msgs 937.87ms
Unbox 1000 box1 msgs first run 219.38ms
Unbox 1000 box1 msgs second run 110.49ms
Add 1000 box1 msgs 903.89ms
Query 1000 msgs first run 48.55ms
Query 1000 msgs second run 12.84ms
Add 1000 box2 msgs 1290.31ms
Unbox 1000 box2 msgs first run 315.02ms
Unbox 1000 box2 msgs second run 143.67ms
Migrate (+db1) 11794.92ms
Migrate (alone) 4083.13ms
Migrate (+db1 +db2) 8644.17ms
Migrate (+db2) 6296.65ms
Migrate continuation (+db2) 1036.51ms
Memory usage without indexes 766.60 MB = 43.23 MB + etc
Initial indexing 1791.56ms
Initial indexing maxcpu=86 5093.73ms
Initial indexing compat 738.26ms
Two indexes updating concurrently 2953.88ms
Key one initial 48.61ms
Key two 0.54ms
Key one again 1.92ms
Reboot and key one again 45.93ms
Latest root posts 1774.83ms
Latest posts 11.07ms
Votes one initial 1496.28ms
Votes again 0.58ms
HasRoot 1338.52ms
HasRoot again 0.33ms
Author one posts 1421.79ms
Author two posts 20.16ms
Dedicated author one posts 1458.00ms
Dedicated author one posts again 0.54ms
DeleteFeed 3042.38ms
Maximum memory usage 985.44 MB = 58.28 MB + etc
Indexes folder size 10.01mb
mixmix commented 2 years ago

It was the fixtures! booo

github-actions[bot] commented 2 years ago

Benchmark results

Part Duration
Create 5000 new messages 450.41ms
Validate 5000 messages 539.49ms
Native to db format 5000 messages 136.87ms
Db to native format 5000 messages 107.96ms
Add 1000 elements 522.96ms
Add 1000 box1 msgs 1140.16ms
Unbox 1000 box1 msgs first run 250.03ms
Unbox 1000 box1 msgs second run 118.71ms
Add 1000 box1 msgs 1069.44ms
Query 1000 msgs first run 48.18ms
Query 1000 msgs second run 24.39ms
Add 1000 box2 msgs 1542.36ms
Unbox 1000 box2 msgs first run 403.46ms
Unbox 1000 box2 msgs second run 178.09ms
Migrate (+db1) 13756.61ms
Migrate (alone) 5023.74ms
Migrate (+db1 +db2) 10330.97ms
Migrate (+db2) 7647.04ms
Migrate continuation (+db2) 1172.97ms
Memory usage without indexes 754.02 MB = 39.93 MB + etc
Initial indexing 1924.65ms
Initial indexing maxcpu=86 6343.01ms
Initial indexing compat 1034.87ms
Two indexes updating concurrently 3452.93ms
Key one initial 53.30ms
Key two 0.59ms
Key one again 1.08ms
Reboot and key one again 65.33ms
Latest root posts 2078.10ms
Latest posts 22.24ms
Votes one initial 1770.68ms
Votes again 0.70ms
HasRoot 1564.46ms
HasRoot again 0.37ms
Author one posts 1717.52ms
Author two posts 19.71ms
Dedicated author one posts 1724.18ms
Dedicated author one posts again 0.68ms
DeleteFeed 3660.62ms
Maximum memory usage 1011.76 MB = 60.97 MB + etc
Indexes folder size 10.01mb
arj03 commented 1 year ago

@mixmix

staltz commented 1 year ago

I suppose we can just merge, because Mix has sick family at the moment.

mixmix commented 1 year ago

yeah you should feel free to merge stuff like this

github-actions[bot] commented 1 year ago

Benchmark results

Part Duration
Create 5000 new messages 493.89ms
Validate 5000 messages 459.81ms
Native to db format 5000 messages 141.14ms
Db to native format 5000 messages 82.16ms
Add 1000 elements 487.62ms
Add 1000 box1 msgs 1263.62ms
Unbox 1000 box1 msgs first run 243.24ms
Unbox 1000 box1 msgs second run 105.45ms
Add 1000 box1 msgs 1200.38ms
Query 1000 msgs first run 48.58ms
Query 1000 msgs second run 22.38ms
Add 1000 box2 msgs 1783.01ms
Unbox 1000 box2 msgs first run 387.76ms
Unbox 1000 box2 msgs second run 164.25ms
Migrate (+db1) 14049.90ms
Migrate (alone) 5033.33ms
Migrate (+db1 +db2) 10434.19ms
Migrate (+db2) 7340.95ms
Migrate continuation (+db2) 1156.88ms
Memory usage without indexes 759.35 MB = 40.18 MB + etc
Initial indexing 1873.60ms
Initial indexing maxcpu=86 5837.08ms
Initial indexing compat 939.62ms
Two indexes updating concurrently 3360.37ms
Key one initial 52.50ms
Key two 0.95ms
Key one again 1.18ms
Reboot and key one again 62.13ms
Latest root posts 2092.00ms
Latest posts 10.36ms
Votes one initial 1646.17ms
Votes again 0.54ms
HasRoot 1467.21ms
HasRoot again 0.42ms
Author one posts 1740.42ms
Author two posts 18.81ms
Dedicated author one posts 1682.83ms
Dedicated author one posts again 0.48ms
DeleteFeed 5987.94ms
Maximum memory usage 1010.21 MB = 59.44 MB + etc
Indexes folder size 10.01mb