spring-boot-starter-data-redis是否支持reactive响应式编程

开源项目SDK:https://github.com/mingyang66/spring-parent

个人文档:https://mingyang66.github.io/raccoon-docs/#/

spring-boot-starter-data-redis: 使用传统的基于阻塞的I/O编程模型,这意味着当你调用Redis操作时,线程将会被阻塞,知道操作完成,这在高并发场景下可能会导致线程资源的良费和响应时间的增加。

spring-boot-starter-data-redis-reactive: 使用响应式编程模型,在响应式编程中,你的操作是异步的,并且基于事件驱动;你可以继续处理其他的事情,而不必等待Redis操作完成;当Redis操作完成时,结果会被发送到一个回调函数或订阅者。

上述描述是spring-boot-starter-data-redis只支持阻塞模式,而不支持基于reactive的响应式编程,但是我通过研究源码及实际操作验证spring-boot-starter-data-redis是支持基于ractive的响应式编程的,并且spring-boot-starter-data-redis和spring-boot-starter-data-redis-reactive两个starter启动器依赖的jar包都是一样的,都依赖了ractor-core,所以个人认为这两个启动器支持的功能都是一样的,没有什么具体的区别。

  • spring-boot-starter-data-redis包依赖
sh 复制代码
|------spring-boot-starter-data-redis
|  |------lettuce-core
|  |  |------netty-common
|  |  |------netty-handler
|  |  |------netty-transport
|  |  |------reactor-core
|  |------spring-boot-starter
|  |------spring-data-redis
  • spring-boot-starter-data-redis-reactive包依赖
sh 复制代码
|------spring-boot-starter-data-redis-reactive
|  |------lettuce-core
|  |------reactor-core
|  |------spring-boot-starter
|  |------spring-data-redis
相关推荐
xqqxqxxq3 小时前
Redis 五大常用数据类型 + 通用命令笔记
数据库·redis·笔记
XiaoLeisj8 小时前
Kotlin Flow 常用操作符:数据变换 map、filter、onEach,时间控制 debounce、sample,终端聚合 reduce、fold
android·kotlin·android jetpack·协程·响应式编程·flow
LCG元9 小时前
ESP32-IDF 远程固件升级实战:HTTPS OTA + 双分区切换 + 自动回滚
数据库·redis·https
MC皮蛋侠客9 小时前
Redis 系列(十一):高可用(二)——Redis Cluster 集群
数据库·redis·bootstrap
祈禾19 小时前
Redis三大缓存问题与分布式锁
运维·数据库·redis·笔记·分布式·缓存
福大大架构师每日一题1 天前
Redis 8.10.0 正式发布:紧凑哈希、批量导入、备份恢复、流与时序能力全面升级
数据库·redis·哈希算法
祈禾1 天前
Redis三大特殊数据类型
运维·服务器·数据库·redis·笔记·缓存
y = xⁿ1 天前
一文掌握Redis常见八股
数据库·redis·缓存
MC皮蛋侠客1 天前
Redis 系列(五):持久化——RDB、AOF 与混合持久化
数据库·redis·bootstrap
xqqxqxxq1 天前
Redis五大常用数据类型技术笔记
数据库·redis·笔记