Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make Orders able to be cancelled #102

Open
4 tasks
fredo opened this issue May 24, 2019 · 0 comments
Open
4 tasks

Make Orders able to be cancelled #102

fredo opened this issue May 24, 2019 · 0 comments
Labels
architecture raidex node architecture cs commitment service webui
Milestone

Comments

@fredo
Copy link
Contributor

fredo commented May 24, 2019

Orders cannot be cancelled by the user. A way needs to be defined when a particular offer corresponded to an order is able to be cancelled or not. Then the user should automatically be able to cancel an order. Offers get cancelled or stay open.

Race condition is as followed:

An offer is committed to a CS and published. When is the offer officially cancelled? In the meanwhile any taker could try to take the offer. This is currently decided by the CS approving a commitment to a specific taker. Therefore it should be up to the commitment service to "approve" a cancellation. This exposes the risk of front running to the CS or even worse the power of leave the offer open until it times out.

Simple Scheme for now would be:

  • User cancels the order
  • Every offer with the state "initiated", "unproved", "proved" or "published" (this means no taker was approved) can be cancelled by the user
  • Raidex sends Cancellation message to CS
  • CS answers with a cancellation proof and the refund of the commitment
  • Upon receiving the offer can be seen as cancelled

Tasklist

  • Make the button cancel active again in the web ui
  • introduce a new message type cancellation and cancellation proof
  • raidex node must handle cancelation state change
  • CS can handle cancellation message
@fredo fredo added architecture raidex node architecture cs commitment service webui labels May 24, 2019
@fredo fredo added this to the Backlog milestone May 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
architecture raidex node architecture cs commitment service webui
Projects
None yet
Development

No branches or pull requests

1 participant