This is just one example, but at a small scale you might be placing buy orders with let’s say $1k or $10k. This is insignificant compared to the total amount of money being traded, and will not affect the stock price.
However if you start increasing scale to $1mm or $10mm, your buy or sell orders begin to actually move the stock price itself. You might not be able to successfully sell $10mm of stock without dropping the price, signaling others to sell, further dropping the price, cutting into your own profits.
Awesome write up. I have a similar project in Go myself, although I just use minute bar data instead of realtime ticks.
Can you share your approach for plugging in various strategies? I quickly learned that having a pluggable strategy system is tricky as it could span across multiple layers of the system.
Also, with backtesting, are you storing and replaying all the quote/tick data? or just using the historical aggregates?