Spring WebFlux and Spring Data Redis Reactive

Eric Anicet
3 min readApr 18, 2022

In this story, we’ll implement a sample REST API that uses Spring WebFlux with Spring Data Redis Reactive.

Redis is an open-source (BSD licensed), in-memory data structure store used as a database, cache, message broker, and streaming engine. Redis provides data structures such as strings, hashes, lists, sets, sorted sets with range queries, bitmaps, hyperloglogs, geospatial indexes, and streams.

Prerequisites

  • Spring Boot 2.6.5
  • Maven 3.6.+
  • Java 11 or later
  • Redis 3.2 or later

Getting Started

We will start by creating a simple Spring Boot project from start.spring.io, with the following dependencies: Spring Reactive Web, Spring Data Reactive Redis, Lombok, and Validation.

Project Structure

Here is our project structure:

Configuration

--

--