koinos / koinos-mempool

The mempool microservice stores pending transactions for inclusion in blocks by the block producer.
MIT License
0 stars 1 forks source link

Upgrades `mempool` to become fork aware #86

Closed sgerbino closed 1 year ago

sgerbino commented 1 year ago

Resolves #79. Resolves #81. Resolves #82. Resolves #83. Resolves #85.

Brief description

Upgrades mempool to be fork aware such transactions that find themselves on orphaned forks do not get lost.

Checklist

Demonstration

❯ ctest -j9
Test project /Users/sgerbino/Projects/koinos-mempool/build/tests
    Start 1: koinos_mempool_tests-mempool_tests/mempool_basic_test
    Start 2: koinos_mempool_tests-mempool_tests/pending_transaction_pagination
    Start 3: koinos_mempool_tests-mempool_tests/pending_transaction_pruning
    Start 4: koinos_mempool_tests-mempool_tests/pending_transaction_dynamic_max_resources
    Start 5: koinos_mempool_tests-mempool_tests/fork_test
1/5 Test #1: koinos_mempool_tests-mempool_tests/mempool_basic_test ..........................   Passed    0.06 sec
2/5 Test #4: koinos_mempool_tests-mempool_tests/pending_transaction_dynamic_max_resources ...   Passed    0.06 sec
3/5 Test #3: koinos_mempool_tests-mempool_tests/pending_transaction_pruning .................   Passed    0.06 sec
4/5 Test #5: koinos_mempool_tests-mempool_tests/fork_test ...................................   Passed    0.09 sec
5/5 Test #2: koinos_mempool_tests-mempool_tests/pending_transaction_pagination ..............   Passed    0.85 sec

100% tests passed, 0 tests failed out of 5

Total Test time (real) =   0.87 sec