nim-codex/codex/sales
Eric 3e80de3454
Cancel and wait for asyncstatemachine futures when stopping (#493)
* Simplify `.then` (promise api) and tests

* Remove tracked future when cancelled. Add tracked future tests

* Track and cancel statemachine futures

The futures created in each asyncstatemachine instance are tracked, and each future is cancelled and waited in `stop`.

Change `asyncstatemachine.stop` to be async so `machine.trackedFutures.cancelAndWait` could be called.
Add a constructor for `asyncstatemachine` that initialises the `trackedFutures` instance, and call the constructor from derived class constructors.
2023-07-31 15:09:34 +10:00
..
states Slot queue (#455) 2023-07-25 12:50:30 +10:00
reservations.nim Slot queue (#455) 2023-07-25 12:50:30 +10:00
salesagent.nim Cancel and wait for asyncstatemachine futures when stopping (#493) 2023-07-31 15:09:34 +10:00
salescontext.nim Slot queue (#455) 2023-07-25 12:50:30 +10:00
salesdata.nim Slot queue (#455) 2023-07-25 12:50:30 +10:00
slotqueue.nim Cancel and wait for asyncstatemachine futures when stopping (#493) 2023-07-31 15:09:34 +10:00
statemachine.nim [marketplace] Add Reservations Module (#340) 2023-04-04 17:05:16 +10:00