Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Вивчайте Challenge: Basic Commands | The Essential Redis Commands
Introduction to Redis
course content

Зміст курсу

Introduction to Redis

Introduction to Redis

1. Redis Fundamentals
2. The Essential Redis Commands
3. Data Types in Redis
4. Advanced Features and Security
5. Caching with Redis and Spring Boot

book
Challenge: Basic Commands

You will work with user data using Redis as the storage system. The task includes the following steps:

  1. You will store the user's name in Redis under a unique key (user:1) with the name John Doe.
  2. Ensure that the user with the given key exists before working with their data. Retrieve the value associated with the key.
  3. Update the user's name to a new value: Jane Smith.
  4. Ensure that the changes were applied correctly.

Requirements

  • Use only the SET, GET, and EXISTS commands to complete the task;
  • All actions will be performed in Redis CLI;
  • You are working with a single user, using their unique identifier as the key.

Create a new user by storing their name in Redis under a unique key:

Check if the user exists using the command:

Retrieve the user's data with the command:

Update the user's name with the new value:

Retrieve the data again to ensure the name was updated to Jane Smith:

Все було зрозуміло?

Як ми можемо покращити це?

Дякуємо за ваш відгук!

Секція 2. Розділ 4
We're sorry to hear that something went wrong. What happened?
some-alt