Techiio-author
Started by Bell GrantNov 5, 2021

Open
Does Redis persist data?

1 VIEWES 0 LIKES 0 DISLIKES SHARE
0 LIKES 0 DISLIKES 1 VIEWES SHARE

I keep in mind that Redis serves all records from reminiscence, but does it persist as nicely across server reboot so that once the server reboots it reads into reminiscence all the information from disk. Or is it continually a clean keep which is most effective to save records at the same time as apps are running without endurance?

1 Replies

Techiio-commentatorHarry Lian replied 4 months ago0 likes0 dislikes

I suggest you read about this on http://redis.io/topics/persistence . you lose the guaranteed persistence when you increase performance by using only in-memory storing. Imagine a scenario where you INSERT into memory, but before it gets persisted to disk lose power. There will be data loss.

Redis supports so-called "snapshots". This means that it will do a complete copy of what's in memory at some point in time (e.g. every full hour). When you lose power between two snapshots, you will lose the data from the time between the last snapshot and the crash (doesn't have to be a power outage..). Redis trades data safety versus performance almost NoSQL-DBs do.

Most NoSQL databases follow a concept of replication among multiple nodes to minimize this risk. Redis is considered more a speedy cache instead of a database that guarantees data consistency. Therefore its use cases typically differ from those of real databases: You can, for example, store sessions, performance counters, or whatever in it with unmatched performance and no real loss in case of a crash. But processing orders/purchase histories and so on is considered a job for traditional databases.

You must be Logged in to reply
Techiio-logo

Techiio is on the journey to build an ocean of technical knowledge, scouring the emerging stars in process and proffering them to the corporate world.

Follow us on:

Subscribe to get latest updates

You can unsubscribe anytime from getting updates from us
Developed and maintained by Wikiance
Developed and maintained by Wikiance