应该是springboot版本问题
- springboot版本为 2.1.3.RELEASE 可以用 jedis版本2.9.0
- springboot版本为2.2.0.RELEASE 可以用jedis版本3.1.0
- springboot版本为2.3.3.RELEASE 可以用jedis版本3.1.0
<!-- redis--> <dependency> <groupId>org.springframework.data</groupId> <artifactId>spring-data-redis</artifactId> <version>2.3.2.RELEASE</version> </dependency> <!-- redis --> <dependency> <groupId>redis.clients</groupId> <artifactId>jedis</artifactId> <!--<version>2.9.0</version>--> <version>3.1.0</version> </dependency>