1.Thymeleaf的问题
就是静态资源的访问中的问题
spring.mvc.view.prefix=classpath:/templates/
spring.mvc.view.suffix=.html
配置上面的不够的,如果你想要访问Thymeleaf的莫办才可以。
启动springboot项目中的问题Failed to start bean ‘webServerStartStop’; nested exception is org.springframework.boot.web.server.WebServerException: Unable to start embedded Tomcat server
就是未加入sang.12文件
2.关于在数据库中创建表的问题
出现这个报错:org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘flywayInitializer’ defined in class path resource [org/springframework/boot/autoconfigure/flyway/FlywayAutoConfiguration$FlywayConfiguration.class]: Invocation of init method failed; nested exception is org.flywaydb.core.api.FlywayException: Found non-empty schema(s) vhr
but no schema history table. Use baseline() or set baselineOnMigrate to true to initialize the schema history table.
这个报错好呕心啊,我特么几天没有搞我导入的项目,都是因为被这个原因搞着,带我的人又一直没有时间,总算解决了
原因:flywaydb会帮我们创建表和表的数据,如果用了flyaway在项目的Service层都会引入引入下面的依赖
org.flywaydb
flyway-core
但是项目是导入的,这个会给我自动建表和和表的数据,所有千万在自己键对应的数据库之后不要建表。
3.报错This application has no explicit mapping for /error, so you are seeing this as a fallback.
Mon May 17 15:05:35 GMT+08:00 2021
There was an unexpected error (type=Not Found, status=404).
具体原因我踩过的坑是因为我在这暴露的接口中是用的@Controller和@RequestMapping的组合形式。
是他找不到了所以会报错
报错:Note: further occurrences of HTTP request parsing errors will be logged at DEBUG level.
原因是配置文件未引入秘钥的相关部分Note:
server.ssl.key-store-type=JKS
server.ssl.key-store=sang.p12
server.ssl.key-alias=tomcathttps
server.ssl.key-store-password=123456
server.ssl.enabled=true