2022-08-28 17:42:43 -07:00
|
|
|
# MemDB
|
|
|
|
|
|
|
|
## Bidding Flow
|
|
|
|
|
|
|
|
```mermaid
|
|
|
|
flowchart
|
|
|
|
|
2022-09-06 16:11:43 -07:00
|
|
|
s[Submit Bid] --> rstake{{Read Staked Amount}}
|
|
|
|
|
|
|
|
rstake --> st{Has min amount staked?}
|
|
|
|
|
|
|
|
st -- No --> re0[[Error]]
|
|
|
|
st -- Yes --> rdb{{Read MemBids}}
|
|
|
|
|
|
|
|
rdb --> h{Is Highest Bid?}
|
2022-08-28 17:42:43 -07:00
|
|
|
|
|
|
|
h -- Yes --> m{{Add to MemBids}}
|
|
|
|
h -- No --> re1[[Error]]
|
|
|
|
|
|
|
|
m -- Every Block --> ae{Auction expired?}
|
|
|
|
ae -- Yes --> fh{{Find Highest Bid}}
|
|
|
|
ae -- No --> ca{{Check again}} -- Next block --> ae
|
|
|
|
|
|
|
|
fh -- Settle --> scs[(Chain State)]
|
|
|
|
```
|