本地springboot启动出错

来源:4-13 分布式会话实现(上)

qq_208_1

2021-03-16

Hello World!

. ____ _ __ _ _
/\ / __ _ () __ __ _ \ \ \
( ( )_
_ | '_ | '| | ’ / ` | \ \ \
\/ )| |)| | | | | || (| | ) ) ) )
’ |
| .__|| ||| |__, | / / / /
=|_|======|/=////
:: Spring Boot :: (v2.4.2)

2021-03-16 17:26:16.486 INFO 16288 — [ main] com.miaoshaproject.App : Starting App using Java 1.8.0_231 on DESKTOP-7OTN8UB with PID 16288 (C:\Users\SunDongHai\Desktop\miaosha\target\classes started by SunDongHai in C:\Users\SunDongHai\Desktop\miaosha)
2021-03-16 17:26:16.496 INFO 16288 — [ main] com.miaoshaproject.App : No active profile set, falling back to default profiles: default
2021-03-16 17:26:24.890 INFO 16288 — [ main] o.s.b.w.embedded.tomcat.TomcatWebServer : Tomcat initialized with port(s): 8090 (http)
2021-03-16 17:26:24.915 INFO 16288 — [ main] o.apache.catalina.core.StandardService : Starting service [Tomcat]
2021-03-16 17:26:24.916 INFO 16288 — [ main] org.apache.catalina.core.StandardEngine : Starting Servlet engine: [Apache Tomcat/9.0.41]
2021-03-16 17:26:24.922 INFO 16288 — [ main] o.a.catalina.core.AprLifecycleListener : Loaded Apache Tomcat Native library [1.2.23] using APR version [1.7.0].
2021-03-16 17:26:24.922 INFO 16288 — [ main] o.a.catalina.core.AprLifecycleListener : APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true].
2021-03-16 17:26:24.922 INFO 16288 — [ main] o.a.catalina.core.AprLifecycleListener : APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
2021-03-16 17:26:24.927 INFO 16288 — [ main] o.a.catalina.core.AprLifecycleListener : OpenSSL successfully initialized [OpenSSL 1.1.1c 28 May 2019]
2021-03-16 17:26:25.203 INFO 16288 — [ main] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring embedded WebApplicationContext
2021-03-16 17:26:25.204 INFO 16288 — [ main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 8375 ms
2021-03-16 17:26:25.290 ERROR 16288 — [ main] o.s.b.web.embedded.tomcat.TomcatStarter : Error starting Tomcat context. Exception: org.springframework.beans.factory.UnsatisfiedDependencyException. Message: Error creating bean with name ‘sessionRepositoryFilterRegistration’ defined in class path resource [org/springframework/boot/autoconfigure/session/SessionRepositoryFilterConfiguration.class]: Unsatisfied dependency expressed through method ‘sessionRepositoryFilterRegistration’ parameter 1; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘org.springframework.session.data.redis.config.annotation.web.http.RedisHttpSessionConfiguration’: Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type ‘org.springframework.data.redis.connection.RedisConnectionFactory’ available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {}
2021-03-16 17:26:25.356 INFO 16288 — [ main] o.apache.catalina.core.StandardService : Stopping service [Tomcat]
2021-03-16 17:26:25.495 WARN 16288 — [ main] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.context.ApplicationContextException: Unable to start web server; nested exception is org.springframework.boot.web.server.WebServerException: Unable to start embedded Tomcat
2021-03-16 17:26:25.514 INFO 16288 — [ main] ConditionEvaluationReportLoggingListener :

Error starting ApplicationContext. To display the conditions report re-run your application with ‘debug’ enabled.
2021-03-16 17:26:25.564 ERROR 16288 — [ main] o.s.b.d.LoggingFailureAnalysisReporter :


APPLICATION FAILED TO START


Description:

Parameter 1 of method sessionRepositoryFilterRegistration in org.springframework.boot.autoconfigure.session.SessionRepositoryFilterConfiguration required a bean of type ‘org.springframework.data.redis.connection.RedisConnectionFactory’ that could not be found.

Action:

Consider defining a bean of type ‘org.springframework.data.redis.connection.RedisConnectionFactory’ in your configuration.

Process finished with exit code 1

图片描述
图片描述
图片描述
图片描述

写回答

1回答

龙虾三少

2021-03-17

对比下我的代码和依赖的包版本及配置

0
0

聚焦Java性能优化 打造亿级流量秒杀系统(赠秒杀项目)

理解高流量电商网站性能构建思路 用高逼格技术解决性能提升问题

2176 学习 · 1009 问题

查看课程