Author

Topic: How to solve the trade collision? (Read 508 times)

legendary
Activity: 3024
Merit: 1132
Leading Crypto Sports Betting & Casino Platform
June 08, 2020, 10:17:38 AM
#11
A trade collision occurs when multiple takers attempt to take the same make order at the same time.

If there any way to help on solving this problem?
I just wonder is this really a problem needs to be addressed?

Usually I do see a catchy price to trade with (and I am not sure how many other people are competing with me for the same order), still I go for placing order and if I am first then I will get my order executed otherwise my order will go "pending". Then I do assume that some other trader took that order and I am not lucky enough. I guess this is how usually all traders do assume and move-on to next best available prices. I mean there is no need to complex things rather than just going with what we have in practice for years.

One probable solution if you still look for addressing it:
It could be solved by being milli-second level of accuracy. Orders are being matched based on first-in, first-served. So, being more accurate in terms of time this could be easily solved. After milli-seconds, you may go for accuracy seeking in nano-second levels.
legendary
Activity: 2338
Merit: 1084
zknodes.org
June 08, 2020, 12:35:06 AM
#10
A very rare occurrence for today's exchange platforms that already have good technology and servers. Who is fast and first takes the order even though it is only a few seconds apart, the winner will get the order.
But it will be different if we use Decentralized Exchange like Forkdelta or Etherdelta. I once sold a number of orders placed by someone, but someone took the order first and I couldn't take it. But the order still appears. This might be the problem of the server not responding directly to incoming and outgoing orders or there is a delay of the order.
hero member
Activity: 2660
Merit: 630
Vave.com - Crypto Casino
June 05, 2020, 04:52:25 PM
#9
Trade collision I think this case is very rare specially if there is a good trade volume in that particular exchanger. And if that gonna happen then i think the both parties will not yet get there token orders until there is one another order to fill the empty part of there order to make it enough and they can both get there orders at the same time.

I don't think is rare but I think it does not bother me because I just understand that someone else has seen what I have seen, or want what I want.... Maybe in also trying to win the lady to your side too lol.
But it also happens on the forum here when you sending message too and someone also is trying to send too at same time on same thread plus signature campaign thread for application  Shocked. It is rush or maybe collision as op called it.
sr. member
Activity: 516
Merit: 250
kingcasino.io
June 05, 2020, 08:26:17 AM
#8
Trade collision I think this case is very rare specially if there is a good trade volume in that particular exchanger. And if that gonna happen then i think the both parties will not yet get there token orders until there is one another order to fill the empty part of there order to make it enough and they can both get there orders at the same time.
mk4
legendary
Activity: 2870
Merit: 3873
📟 t3rminal.xyz
June 05, 2020, 05:18:37 AM
#7
@Piston LMAO. This is actually the first time I've actually laughed at a plagiarized reply. Did you seriously reply with copy-pasted content from a freakin physics website LOL. At least try staying on topic!

Archived: https://archive.is/7N5ba
Plagiarized from:

member
Activity: 102
Merit: 10
June 05, 2020, 04:30:42 AM
#6
There are two general types of collisions in physics: elastic and inelastic. An inelastic collisions occurs when two objects collide and do not bounce away from each other. Momentum is conserved, because the total momentum of both objects before and after the collision is the same. Any macroscopic collision between objects will convert some of the kinetic energy into internal energy and other forms of energy, so no large scale impacts are perfectly elastic.
legendary
Activity: 3668
Merit: 6382
Looking for campaign manager? Contact icopress!
June 04, 2020, 05:10:45 AM
#5
A trade collision occurs when multiple takers attempt to take the same make order at the same time.

If there any way to help on solving this problem?

From what I see, it could be done either with lock on the table / records, either by keeping in memory a synchronized time-ordered list of operations "to be made".
mk4
legendary
Activity: 2870
Merit: 3873
📟 t3rminal.xyz
June 04, 2020, 12:17:29 AM
#4
I'm not an expert concerning exchange software, but I'm going to assume it comes down to better, well-optimized software and faster servers. It's very very unlikely for two takers to execute the same orders at the same exact time down to the microsecond anyway, and the exchange should be giving the order to the first one who executed the order.

Of course there are other factors like latency, but that's mostly on the end-user side.
hero member
Activity: 2702
Merit: 716
Nothing lasts forever
June 03, 2020, 11:45:37 PM
#3
Even though you say 'at the same time' there might be a difference of a few seconds or milliseconds in the take orders placed by the takers.
So the exchange might be approving the take orders on first come first serve basis.
So the one who placed the take order first would receive the tokens first followed by the laterals.

If we talk about the rarest possibility of multiple take orders getting placed at the exact same milli second then the exchange can fill all those take orders in the same ratio as the amount given by those takers.
copper member
Activity: 2856
Merit: 3071
https://bit.ly/387FXHi lightning theory
June 03, 2020, 11:19:18 PM
#2
As an assumtion and how exchanges look to do it from my perspective is that you have a server that handles trades and holds the database, the user obtains a lock on the database when they submit a market order and the lock is removed from the db after.

Either that, or orders take a while to complete so they might batch orders each second and compute them all at once with the average price credited to all of them. As in a snapshot gets taken of what the user wants the server to do and then the action is performed across all the user interactions for that amount of time.
newbie
Activity: 28
Merit: 1
June 03, 2020, 11:12:27 PM
#1
Within an exchange, there are two parties: makers and takers.

Makers submit make orders which specify an offer to a specified amount of one token for another amount of another token.

Takers view the exchange orderbook (which is solely comprised of make orders) and exchange tokens by filling make orders.

A trade collision occurs when multiple takers attempt to take the same make order at the same time.

If there any way to help on solving this problem?
Jump to: