springboot缓存之搭建redis环境

Redis是一个开源(BSD许可)的,内存中的数据结构存储系统,它可以用作数据库\缓存和消息中间件.

  • 安装redis,使用docker

docker pull registry.docker-cn.com/library/redis

  • 运行redis

docker run -d -p 6379:6379 --name myredis redis

  • 下载Redis Desktop Manager

springboot缓存之搭建redis环境

  • new Connection

springboot缓存之搭建redis环境

springboot缓存之搭建redis环境

springboot缓存之搭建redis环境

springboot缓存之搭建redis环境redis上右键打开controller

springboot缓存之搭建redis环境

输入

springboot缓存之搭建redis环境

springboot缓存之搭建redis环境

springboot缓存之搭建redis环境

此时

springboot缓存之搭建redis环境springboot缓存之搭建redis环境