I set up a set of projects, using springboot version 2.3.0. When I started, I repeatedly reported errors, so I started a long journey of error finding. At first, I thought it was because the framework was not well configured. Finally, I found that it was the problem of redis.
Error one
org.springframework.data . redis.connection.RedisConnectionFactory ’ that could not be found
Error two
Error creating bean with name ‘redisTemplate’ defined in class path resource
reason
I report an error because I didn’t introduce the jedis dependency. Another reason is that the Maven dependent versions of jedis and spring boot starter data redis are incompatible, which is a common problem. The same is true when the jedisconnectionfactory cannot be created.
solve
Just introduce the jedis dependency to solve the problem
<!--redis cache-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-redis</artifactId>
</dependency>
<!--spring boot2.x The above version needs to be introduced, otherwise the startup will report an error!-->
<dependency>
<groupId>redis.clients</groupId>
<artifactId>jedis</artifactId>
</dependency>
Launch again
perfect solution~
Read More:
- [Solved] Redis Error: Error creating bean with name stringRedisTemplate defined in class path resource
- [Solved] Springboot Error creating bean with name ‘dataSource’ defined in class path resource
- [Solved] Error creating bean with name ‘sqlSessionFactory‘ defined in class path resource
- SpringBoot Access Clickhouse Error: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘jdbcConverter’ defined in class path resource [***.class]
- [Solved] nacos Startup Error: Error creating bean with name ‘authFilterRegistration‘ defined in class path resource
- [Solved] Error creating bean with name ‘enableRedisKeyspaceNotificationsInitializer‘ defined in class path re
- [Solved] Error creating bean with name ‘enableRedisKeyspaceNotificationsInitializer‘ defined in class path
- [Solved] Error creating bean with name ‘braveHttpServerHandler‘ defined in class path
- When integrating redis with SSM framework, error creating bean with name ‘rediscontentserviceimpl’ defined in file
- Error creating bean with name ‘studentMapper‘ defined in file
- Eclipse Tomcat Error creating bean with name ‘sqlSessionFactory’ defined in URL…
- Tk.mapper Common mapper Error: Error creating bean with name ‘commonMapper‘ defined in file xxx
- Spring cloud Eureka error creating bean with name
- How to Solve creating bean with name ‘mappingjackson2httpmessageconverter’ error when elasticsearch advanced client starts‘
- Error creating bean with name ‘captchaController‘: Unsatisfied dependency expressed through field ‘c
- [Solved] UnsatisfiedDependencyException: Error creating bean with name
- [Solved] Maven log jar package conflict error: Class path contains multiple SLF4J bindings
- Eureka unit test error creating bean with name ‘Eureka autoservice registration’: Singleton bean
- [Solved] springmvc:Error creating bean with name ‘org.springframework.cache.interceptor.CacheInterceptor
- How to Solve Error creating bean with name ‘log’loginController’