Hey, I answered this and some other questions in this thread on reddit: Reddit - Dive into anything
Copying it over here:
Please provide some links on the competition and explanation what’s the experience there vs. what would be on Algorand, how much is the competition used, etc.
- GitHub - AthanorLabs/atomic-swap: 💫 ETH-XMR atomic swap implementation
- GitHub - comit-network/xmr-btc-swap: Bitcoin–Monero Cross-chain Atomic Swap
- https://www.youtube.com/watch?v=ZQG50hJTgBA
I’ll be honest and say that I haven’t used these services myself, I’ve only read about them, watched that video or followed the discussion on r/Monero.
But fundamentally the problem is that doing an atomic swap requires several transactions on both sides and waiting for confirmation. Monero has 10 blocks as a standard to wait before accepting that a transaction is “final”, which at a blocktime of 2 min means you need to wait 20 mins.
Let’s consider the “happy path”, i.e. when both parties act non-maliciously -i.e. no refund attempt, no attempt to waste the other’s time, no one disconnects from the Internet but remains responsive. Time in parenthesis is time for the other party to observe and confirm the action happened.
- The parties - Algo Alice and XMR Xavier - exchange info, agree on a deal, etc.
- Algorand smart contract gets published. (3.5 secs).
- Alice funds the account with her Algo. (3.5 secs).
- Xavier funds the lock up address with his XMR (20 mins).
- Alice flags to the smart contract that Xavier did indeed fund the XMR. (3.5 secs), putting it into “ready” mode.
- Xavier, on Algorand, provides his Monero secret key to the smart contract (and the entire world), which empties the Algo into his Algorand account. (3.5 secs).
- Alice, with Xavier’s leaked secret key, combines it with her secret key and gains spend control over the lock up address. She moves the XMR into a different address. (20 mins).
Strictly speaking, I believe 2 & 3 might be able to be done as one group transaction. And 7 isn’t quite necessary actually since Alice has spend control and can continue using the lock up address as her own address.
If 2/3 and 6 had to be done on, say, Bitcoin, this whole exchange would take at least 2+ hours extra. Algorand’s instant finality and very fast blocktime makes the user experience uniquely suitable.