Redis - An in-memory database
What is Redis?
Redis (Remote Dictionary Server) is an open source, in-memory data structure store, used as a database, cache, and message broker.
Let's Break it down to understand better.
Redis is a KEY-VALUE store i.e. a store/server that stores data as key-value pairs.
Example:
This key-value store can be used as a database to read and write data.
To Write data in Redis use SET command, like below
To Read data from Redis use GET command, like below
Other Features:
- Redis is a NoSQL Database, i.e. doesn’t have tables, columns, rows, functions, procedures, etc and doesn’t use SELECT, UPDATE, INSERT, DELETE operations.
- Redis uses String, Lists, Sets, Sorted Sets, Hashes, Bitmaps, Hyperloglogs, Geospatial indexes Data Structures to store data.
- Interaction with data is command based. Go through commands on Redis official Documentation Page :https://redis.io/commands
- Its an in-memory database with persistence options, hence keeps the whole dataset in RAM, hence you only access the main memory and it makes it very fast to write and read data.
Why to use Redis?
Redis has below features/advantages:
Redis is very fast and can perform about 110000 SETs per second, about 81000 GETs per second.
To know more, visit https://redis.io/
Thanks for reading!!