Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Marketplace V2 Expiring Orders
This PR implements Expiring Orders on Stargaze Marketplace V2. The implemented features are outlined below.
Features
details.expiry
attribute.When an Order is created or updated, the user may set a timestamp and supply funds that match the
expiry.reward
. This data signifies that whomever removes the Order after the timestamp has elapsed will be owed the expiry reward.There is an admin managed
MIN_EXPIRY_REWARDS
map that sets the minimum viable expiry reward for specified denoms.An index has been added on
expiry.timestamp
that allows traversing all Asks / Bids / Collection Bids by their expiration timestamp.A
Sudo::EndBlock
message has been added that traverses the Order expiration timestamps, removes some number of expired Orders, and sends the rewards to thefee_manager
address. The number of Orders removed each block is capped at the correspondingConfig
values:max_asks_removed_per_block
,max_bids_removed_per_block
,max_collection_bids_removed_per_block
.