Cancelling a DEX order must cost a fee


#1

In a post by @Piers in the one of the economic threads, he mentioned that there is no cost to placing an order on the DEX, but there may be a cost to cancel an order.

I think that it must be a requirement that there be a fee to cancel an order. The node runners are doing work when an order is placed, and cancelled. Without a fee to cancel, it opens up the Radix network to a denial of service attack. Botnets with tiny amounts of Radix could place and cancel orders continually for no fee.

This also implies that the network probably needs to charge a fee for orders which expire after a day too, since the network is performing work to handle them. But a DOS attack with expiring orders is harder to achieve since it would require enough Radix to have all of the expiring orders open at once.

Obviously, the network also must charge a fee for orders that do complete successfully. Do both the buyer and seller pay half of the fee?


#2

Any interaction with the platform should cost fees.
Not only does it cause nodes to perform work, it also directly changes the state of the ledger. It means ALL nodes on the shard are affected by this action.

So any interaction with the DEX causes 2 fee payments.
(1) You place order and then cancel - you perform 2 operations they both cost fees.
(2) You place order and someone else matches it - you pay fee and so does he.


#3

You’re right. In fact, the payment for both the order and the cancellation/match/expiration must be made up front when the order is placed. Otherwise, they could spend all of their Radix after placing the order and have nothing left to pay for the cancellation/match/expiration.

One advantage to this approach is that it will discourage placing and then cancelling orders over and over. This may help discourage lots of very small orders to try to game the system.