rework logic for adding demand orders for finalization
periodic store syncing is implemented by currently disabled
apart from listening to finalization events, added logic to periodically check for mature finalized orders
entire flow of the eibc-client covered with unit tests with minimal abstractions
add unit tests for the order tracker
cleanup and refactor
various abstractions
various bug fixes
General new behaviour:
in sequencer mode, the first batch is sent to the output channel, and the rest of the orders are added to the pool
in p2p and settlement mode, all orders are added to the pool. Then, the orders are periodically popped (fetched and deleted) from the pool and checked for validity.
If the order is valid, it is sent to the output channel.
If the order is not valid, it is added back to the pool.
After the order validity deadline is expired, the order is removed permanently.
Once an order is fulfilled, it is removed from the store
areas for improvement:
orders added to the pool for validating and fulfilling are not added to the store, the order is only added to the store once fulfilled. If the bot shuts down, the cached orders are lost, so the pool needs to be populated from the indexer again upon startup
Changes:
General new behaviour:
areas for improvement: