D
D
Denis_13342021-05-30 13:09:13
Redis
Denis_1334, 2021-05-30 13:09:13

Should I store temporary data directly in Node.js?

I want to implement the game "Battleship" in the browser, and I will need to store temporary information about the battles on the server.
Should I store it in Redis, which stores the data in memory, or should I store the information directly in the program, for example using Object? Or it won't make a difference. I just think that when stored in Redis, it will take extra time to create a request to it, which can be avoided when stored directly in the program.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry Sviridov, 2021-05-30
@dimuska139

First, this solution is not scalable. Secondly, restarting/crashing the application will result in the loss of this data. In other cases it is possible.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question