I’m trying with Algo-trading. so I have WebSocket which has market data, I’m trying to store in the database. other modules read this stored database and make the buy/sell decisions.
- what should be the best database option here considering it should be faster to insert the data and required concurrent reading.
- how do I handle the WebSocket data, it contains a lot of data to store, without losing the data.
?
2
Answers
To answer question 1:
Several people use Redis Timeseries to store market data for analysis/display. Insert and retreival are fast.
For question 2:
You could run several consumers and use Redis for de-duplication so you don’t update everything twice, but it will heavily depend on your stack
To answer question 1:
You can use a memory based database such as redis.
For question 2:
you can use rabbitMQ or kafka.