Redis



Redis is an in-memory data structure store, used as a distributed, in-memory key–value database, cache and message broker, with optional durability. Redis supports different kinds of abstract data structures, such as strings, lists, maps, sets, sorted sets, HyperLogLogs, bitmaps, streams, and spatial indexes.

Readings

 * 1)  Redis
 * 2)  Key–value database

Redis Environment
Establish a Redis environment using one of the following:
 * Docker Playground
 * Redis in Docker
 * Install Redis

Docker Playground
Docker Playground is a free online Docker environment. It requires no installation or configuration.
 * 1) Use Play with Docker. Create an account and/or log in.
 * 2) Start an interactive session and add a new instance.
 * 3) In the terminal window, enter the following commands:

Redis in Docker
You can use your own Docker environment to run MongoDB.
 * 1) Install Docker Desktop or the Docker Engine.
 * 2) In a terminal window, run the following commands:

Install Redis
Install Redis on your own system.
 * 1) Review Redis: Quick Start
 * 2) Download and install Redis.
 * 3) Use the following terminal command to start the Redis server:
 * 4) Use the following terminal command to access the Redis command interface:
 * 1) Use the following terminal command to access the Redis command interface:

Create a Database

 * 1) Use the following Redis commands to select a database and set initial keys and values:
 * 2) Use the following Redis command to show existing configuration information:

Query a Database

 * 1) Use the following Redis command to show existing keys in the current database:
 * 2) Use the following Redis command to show an existing key value in the current database:

Create a Key

 * 1) Use the following Redis command to add a database key:
 * 2) Use the following Redis command to display the inserted key:

Update a Key

 * 1) Use the following Redis command to update a database key:
 * 2) Use the following Redis command to display the updated key:

Delete a Key

 * 1) Use the following Redis command to update a database key:
 * 2) Use the following Redis command to display the remaining keys:

Remove All Keys

 * 1) Use the following Redis command to remove all keys:
 * 2) Use the following Redis command to verify there are no remaining keys: