3 ms·
Coming from a perspective of competitive multiplayer game networking, that seems insane. You can't trust the client. An ideal stock exchange, I'd think, would i
by derefr 11y ago
Coming from a perspective of competitive multiplayer game networking, that seems insane. You can't trust the client. An ideal stock exchange, I'd think, would include the same sort of logic as a payment processor: blocking any orders that seem to be "not the sort of order this client would make", to prevent e.g. orders being executed by people who have illegitimately gained access to the account.
Of course, these type of algorithms typically take far more than microseconds to run—but that's fine, as long as they take the same time for everyone.
- hueving 11y agoA stock exchange isn't responsible for tracking how much outstanding stock there is. The purpose of an exchange is just to match orders, not to determine if they are insane. Expecting otherwise would be like expecting eBay to determine that your buy it now price is too low or that you don't have enough inventory on hand to fulfill your listings.
- HappyTypist 11y agoNot at all. If your exchange takes five milliseconds, you're gonna lose the volume of high frequency trading algorithms because they cannot front run as effectively. For an exchange volume (hence fees) is key, so you really have to work for HFTers.
- fiatmoney 11y agoMultiplayer games are a completely different genre than a professional-level API like a stock exchange. You absolutely must trust that a client's business logic is sound; as long as their credentials validate it's simply out of scope for you to do anything other than explicitly execute their instructions, because that's how the traders make money. "Trust the client" doesn't mean state, it means actions - the equivalent reasoning in a game would be disallowing the player from "playing badly", which is nonsensical.
- pbhjpbhj 11y ago> the equivalent reasoning in a game would be disallowing the player from "playing badly", which is nonsensical // Self and team damage is often turned off (on games I've played, I'm not really a big gamer). That would seem to correspond to blocking a sell order that represents more shares than you could possibly have?
- Nilzor 11y ago.. Or sending the action "deal 1000 damage" when the maximum damage any weapon can do is 5