摘要: @Mapper 作用:在接口类上添加了@Mapper,在编译之后会生成相应的接口实现类 添加位置:mapper接口类上面 @Mapper public interface UserMapper { //代码 } 如果想要每个接口都要变成实现类,那么需要在每个接口类上加上@Mapper注解,比较麻烦, 阅读全文
posted @ 2023-09-19 09:13 種瓜得豆 阅读(331) 评论(1) 推荐(0) 编辑
摘要: 使用@value获取yml参数值 @Value("${value}") // 多级使用 . 连接 例:${value.value} private String value; @value获取不到值的情况 // 错误1:使用了static或者final修饰value private static S 阅读全文
posted @ 2023-09-19 09:10 種瓜得豆 阅读(298) 评论(0) 推荐(0) 编辑
摘要: org.springframework.web.multipart.MultipartException: Failed to parse multipart servlet request; nested exception is java.lang.RuntimeException: java. 阅读全文
posted @ 2023-09-19 09:06 種瓜得豆 阅读(58) 评论(0) 推荐(0) 编辑
摘要: 【win】 java -Dfile.encoding=utf-8 -jar xxx.jar --spring.profiles.active=prod >log/xxx.log 2>&1 & 【说明】-Dfile.encoding=utf-8 解决运行时中文乱码问题 【linux】 nohup ja 阅读全文
posted @ 2023-09-19 09:02 種瓜得豆 阅读(2) 评论(0) 推荐(0) 编辑