
SpringBoot
SpringBoot
keli_Jun
在到达胜利之前,无法回头
展开
-
开放平台商户回调与接口重试机制
Cancel原创 2023-01-28 16:39:58 · 1687 阅读 · 0 评论 -
SpringBoot日志配置
一、日志文件的作用日志,通常不会在需求阶段作为一个功能单独提出来,也不会在产品方案中看到它的细节。但是,这丝毫不影响它在任何一个系统中的重要的地位。 为了保证服务的高可用,发现问题一定要即使,解决问题一定要迅速,所以生产环境一旦出现问题,预警系统就会通过邮件、短信甚至电话的方式实施多维轰炸模式,确保相关负责人不错过每一个可能的bug。 预警系统判断疑似bug大部分源于日志。比如某个微服务接口由于各种原因导致频繁调用出错,此时调用端会捕获这样的异常并打印ERROR级别的日志,当该错误日志达到一定次数出原创 2020-06-12 18:04:39 · 2068 阅读 · 0 评论 -
Spring Boot使用@Scheduled定时器任务
1.启动定时任务在Application中设置启用定时任务功能@EnableScheduling。import org.springframework.boot.SpringApplication;import org.springframework.boot.autoconfigure.SpringBootApplication;import org.springframework.scheduling.annotation.EnableScheduling;@SpringBootApp原创 2020-06-10 15:34:20 · 1195 阅读 · 0 评论 -
idea更新后无法识别SprintBoot启动文件
新建项目后:估计问题原因出现在pom.xml打开你idea配置的maven仓库下的spring-boot-autoconfigure我的路径为E:\repository\org\springframework\boot\spring-boot-autoconfigure发现没有2.3.0解决办法:1.用2.2.6版本(亲测可用)2.更新为2.3.0(待测)?好啦,又可以和Springboot愉快的玩耍啦...原创 2020-05-28 20:46:36 · 703 阅读 · 0 评论 -
SpringBoot错误页面配置
@Componentpublic class ErrorConfig implements ErrorPageRegistrar { @Override public void registerErrorPages(ErrorPageRegistry registry) { ErrorPage error404Page = new ErrorPage(HttpS...原创 2020-04-29 14:27:37 · 198 阅读 · 0 评论 -
Springboot访问静态资源js,css,jpg图片等
Springboot有默认的静态资源访问映射:classpath:/static classpath:/public classpath:/resources classpath:/META-INF/resources在没有修改静态资源访问映射路径的情况下,只需这样:http://localhost:8080/a.jpg就能访问a.jpg,这张图片可以在static 下,也可以...翻译 2019-07-29 22:29:07 · 2009 阅读 · 3 评论 -
Springboot配置.properties文件在控制台输出乱码
在.properties文件默认编码是utf-8,在控制台输出乱码解决办法:原创 2019-08-19 17:38:42 · 867 阅读 · 0 评论 -
前端报500,后端报org.thymeleaf.exceptions.TemplateInputException解决方法
org.thymeleaf.exceptions.TemplateInputException: Error resolving template "01", template might not exist or might not be accessible by any of the configured Template Resolvers at org.thymeleaf.en...原创 2019-05-29 11:53:26 · 2839 阅读 · 1 评论