当前位置:网站首页>解决问题:Unable to connect to Redis
解决问题:Unable to connect to Redis
2022-07-07 04:16:00 【Charter1】
错因:无法连接到redis
最近在使用springboot整合redis时,出现的错误:
Unable to connect to Redis; nested exception is io.lettuce.core.RedisConnectionException: Unable to connect to localhost:6379
解决:需要到springboot配置文件中配置一些相关参数去连接Redis
spring:
redis:
host: 192.168.1.1 #服务器地址 你服务器或本机地址
port: 6379 #连接端口
database: 0 #数据库索引,默认0
password: 123456 #密码
jedis:
pool:
max-active: 8 #连接池最大连接数(使用负值表示没有限制)
max-wait: -1 #最大阻塞等待时间(使用负值表示没有限制)
max-idle: 8 #最大空闲连接数
min-idle: 0 #最小空闲连接数
timeout: 5000 #连接超时时间(毫秒)
配置完这些参数即可使用
边栏推荐
- Solution: could not find kf5 (missing: coreaddons dbusaddons doctools xmlgui)
- 【Liunx】进程控制和父子进程
- Rxjs - observable doesn't complete when an error occurs - rxjs - observable doesn't complete when an error occurs
- 1140_ SiCp learning notes_ Use Newton's method to solve the square root
- @component(““)
- How to reduce inventory with high concurrency on the Internet
- Jenkins远程构建项目超时的问题
- How to * * labelimg
- L'externalisation a duré trois ans.
- 242. Bipartite graph determination
猜你喜欢
[GUET-CTF2019]虚假的压缩包
通信设备商,到底有哪些岗位?
How to * * labelimg
Talk about seven ways to realize asynchronous programming
95后CV工程师晒出工资单,狠补了这个,真香...
The metauniverse of the platofarm farm continues to expand, with Dao governance as the core
ROS2规划系统plansys2简单的例子
Robot technology innovation and practice old version outline
Iterable、Collection、List 的常见方法签名以及含义
Summary of customer value model (RFM) technology for data analysis
随机推荐
四、高性能 Go 语言发行版优化与落地实践 青训营笔记
KBU1510-ASEMI电源专用15A整流桥KBU1510
[semantic segmentation] - multi-scale attention
Deep learning Flower Book + machine learning watermelon book electronic version I found
Implementing data dictionary with JSP custom tag
Iterable、Collection、List 的常见方法签名以及含义
1、 Go knowledge check and remedy + practical course notes youth training camp notes
[GUET-CTF2019]虚假的压缩包
Jenkins远程构建项目超时的问题
gslx680触摸屏驱动源码码分析(gslX680.c)
MobaXterm
【云原生】内存数据库如何发挥内存优势
微博发布案例
Dynamics CRM server deployment - restore database prompt: the database is in use
科技云报道:从Robot到Cobot,人机共融正在开创一个时代
知识点滴 - 关于苹果认证MFI
今日现货白银操作建议
Jenkins remote build project timeout problem
Live online system source code, using valueanimator to achieve view zoom in and out animation effect
解决:Could NOT find KF5 (missing: CoreAddons DBusAddons DocTools XmlGui)