09 2021 档案

摘要:参考: https://www.cnblogs.com/theRhyme/p/10110416.html (这种方式需要创建临时文件) https://blog.csdn.net/weixin_42615290/article/details/119558150 (这种方式不需要临时文件。但是包装太 阅读全文
posted @ 2021-09-26 14:48 super超人 阅读(1143) 评论(0) 推荐(0)
摘要:javax.validation注解校验:我们使用的实体,有时候需要全部校验它的字段,有时候其他地方使用只需要校验它的部分字段。 解决办法:使用分组校验。 public class Group { public interface AddGroup{} public interface Update 阅读全文
posted @ 2021-09-20 17:02 super超人 阅读(1653) 评论(4) 推荐(0)
摘要:为什么使用分组?场景:比如: package com.springbootvalidation.entity; import com.springbootvalidation.common.BaseModel; import com.springbootvalidation.common.Group 阅读全文
posted @ 2021-09-20 16:41 super超人 阅读(14664) 评论(4) 推荐(3)
摘要:参考: https://cloud.tencent.com/developer/article/1426233 https://blog.csdn.net/weixin_34195142/article/details/92401300 阅读全文
posted @ 2021-09-18 19:44 super超人 阅读(175) 评论(2) 推荐(0)
摘要:参考:https://www.cnblogs.com/xiaomaomao/p/13475670.html 阅读全文
posted @ 2021-09-15 09:43 super超人 阅读(51) 评论(0) 推荐(0)
摘要:参考:https://www.cnblogs.com/dsxie/p/13324489.html 阅读全文
posted @ 2021-09-14 07:46 super超人 阅读(149) 评论(0) 推荐(0)
摘要:参考: https://blog.csdn.net/datedateup/article/details/77163266 https://blog.csdn.net/ron03129596/article/details/87467741 (这个链接的文章中网盘地址:https://pan.bai 阅读全文
posted @ 2021-09-13 15:17 super超人 阅读(1207) 评论(0) 推荐(0)
摘要:参考:https://www.cnblogs.com/woods1815/p/9780683.html 阅读全文
posted @ 2021-09-13 09:29 super超人 阅读(48) 评论(0) 推荐(0)
摘要:参考:https://www.cnblogs.com/youzhibing/p/10024558.html 参考项目gitee地址:https://gitee.com/youzhibing/spring-boot-2.0.3/tree/master/spring-boot-quartz 阅读全文
posted @ 2021-09-12 23:31 super超人 阅读(73) 评论(0) 推荐(0)
摘要:tailLinux中用于查看文件尾部的内容,与head相对应。常用来查看日志文件,通过-f实时查看文件最新内容。 尤其是对于日志文件较大的时候,通过tail指定输出的行数来查看日志。 // 输出最后10行的内容 tail test.log // 输出最后10行的内容,同时监视文件的变化,一旦变化就显 阅读全文
posted @ 2021-09-12 23:26 super超人 阅读(10116) 评论(0) 推荐(0)
摘要:在关闭防火墙到时候,出现: Redirecting to /bin/systemctl stop iptables.service Failed to stop iptables.service: Unit iptables.service not loaded. 解决方法: yum install 阅读全文
posted @ 2021-09-12 22:09 super超人 阅读(757) 评论(0) 推荐(0)
摘要:参考:https://blog.csdn.net/qq_18846873/article/details/95940161 参考博客用的是NAT,我是选择的桥接模式,配置好后ip地址固定,能ping通和使用。 然后使用后面几步: 6、使用命令 cd /etc/sysconfig/network-sc 阅读全文
posted @ 2021-09-12 21:36 super超人 阅读(198) 评论(0) 推荐(0)
摘要:参考:https://blog.csdn.net/qq_18846873/article/details/95940161 阅读全文
posted @ 2021-09-12 14:34 super超人 阅读(45) 评论(0) 推荐(0)
摘要:SpringBoot启动报错Failed to determine a suitable driver class:检查配置中的url是否被正确引用到。 SpringBoot启动报错Failed to determine a suitable driver class 阅读全文
posted @ 2021-09-09 14:00 super超人 阅读(659) 评论(0) 推荐(0)
摘要:package com.xingyi.bos.utils; import com.xingyi.bos.ZjBosApplication; import org.jasypt.encryption.StringEncryptor; import org.junit.Test; import org. 阅读全文
posted @ 2021-09-08 11:21 super超人 阅读(332) 评论(0) 推荐(0)
摘要:转JsonObject: Object region = JSONObject.parse(regions.toString()); 转对象: BStationRegion stationRegion = JSONObject.parseObject(regions.toString(),BStat 阅读全文
posted @ 2021-09-08 10:09 super超人 阅读(1709) 评论(0) 推荐(0)
摘要:必须是相同类型比较才行,否则返回false。 源码: public boolean equals(Object obj) { if (obj instanceof Integer) { return value == ((Integer)obj).intValue(); } return false 阅读全文
posted @ 2021-09-08 10:04 super超人 阅读(193) 评论(0) 推荐(0)
摘要:多线程测试redisson实现分布式锁出现org.redisson.RedissonShutdownException: Redisson is shutdown。 原因:多线程还没跑完,主线程就跑完了。主线程走完,关闭了资源。redisson关闭,多线程操作redisson报错:Redisson 阅读全文
posted @ 2021-09-05 16:40 super超人 阅读(11263) 评论(0) 推荐(0)
摘要:springboot整合redis(单机),springboot整合redisCluster集群参考:https://www.cnblogs.com/super-chao/p/15143411.html 1.引入springboot和redis的相关jar包: <parent> <groupId>o 阅读全文
posted @ 2021-09-05 16:27 super超人 阅读(888) 评论(0) 推荐(0)
摘要:spring整合redis并实现redis分布式锁: 1.引入jar包 spring相关jar包。 redis相关jar包:jedis-2.9.0.jar。 spring整合redis的jar包:spring-data-redis-2.1.0.RELEASE.jar 注意版本对应,否则可能出现问题。 阅读全文
posted @ 2021-09-05 15:31 super超人 阅读(1100) 评论(0) 推荐(0)
摘要:参考:https://blog.csdn.net/G971005287W/article/details/107184350 阅读全文
posted @ 2021-09-05 13:25 super超人 阅读(82) 评论(0) 推荐(0)
摘要:由于redis实现分布式锁不完美: 加锁的代码: /** * 加锁 * @param locaName 锁的key * @param acquireTimeout 获取超时时间 * @param timeout 锁的超时时间 * @return 锁标识 */ public static String 阅读全文
posted @ 2021-09-05 00:17 super超人 阅读(2345) 评论(0) 推荐(0)
摘要:解决办法:缺少jar包,spring-data-commons-2.5.2.jar 阅读全文
posted @ 2021-09-04 15:19 super超人 阅读(513) 评论(0) 推荐(0)
摘要:解决办法:缺少jar包,spring-data-keyvalue-1.2.3.RELEASE.jar 阅读全文
posted @ 2021-09-04 15:13 super超人 阅读(407) 评论(0) 推荐(0)
摘要:解决办法:spring的版本问题,升到5就可以了。 阅读全文
posted @ 2021-09-04 15:12 super超人 阅读(4333) 评论(0) 推荐(0)
摘要:spring-data-redis 2的版本只支持spring5和spring boot2+,建议降低spring-data-redis版本或者升高spring版本到5. 参考:https://www.cnblogs.com/-wanglei/p/13527424.html 阅读全文
posted @ 2021-09-04 15:10 super超人 阅读(945) 评论(0) 推荐(0)
摘要:Caused by: java.lang.IllegalStateException: Failed to introspect Class [org.springframework.orm.hibernate5.LocalSessionFactoryBean] from ClassLoader [ 阅读全文
posted @ 2021-09-04 15:07 super超人 阅读(485) 评论(0) 推荐(0)
摘要:Caused by: java.lang.ClassNotFoundException: redis.clients.util.Pool 解决办法:jedis的jar包版本问题,改为jedis-2.9.1.jar就没问题。 参考:https://blog.csdn.net/datouniao1/ar 阅读全文
posted @ 2021-09-04 15:00 super超人 阅读(2786) 评论(0) 推荐(1)
摘要:jbpm4.4用的hibernate3的core包。 spring的spring-orm-5.0.2.RELEASE.jar中只有hibernate5包。 解决办法:因此spring5.x中只需要将引入的spring-orm-5.0.2.RELEASE.jar替换为spring-orm-4.2.6. 阅读全文
posted @ 2021-09-04 14:59 super超人 阅读(237) 评论(0) 推荐(0)
摘要:Caused by: java.lang.ClassNotFoundException: io.netty.resolver.AddressResolverGroup 解决办法:缺少netty-all-4.1.48.Final.jar。 注意:高版本没有此类。 阅读全文
posted @ 2021-09-04 14:50 super超人 阅读(1852) 评论(0) 推荐(0)
摘要:Caused by: java.lang.ClassNotFoundException: org.jboss.marshalling.ClassResolver 解决办法:缺少jboss-marshalling-2.0.3.Final.jar,引入jar包即可。 阅读全文
posted @ 2021-09-04 14:47 super超人 阅读(742) 评论(0) 推荐(0)
摘要:Caused by: java.lang.ClassNotFoundException: com.fasterxml.jackson.dataformat.yaml.YAMLFactory。 解决办法:缺少jackson-dataformat-yaml-2.9.9.jar 阅读全文
posted @ 2021-09-04 14:45 super超人 阅读(1537) 评论(0) 推荐(0)
摘要:spring整合redisson,启动项目报错:Caused by: java.lang.IllegalArgumentException: RIVER package com.user.base.utils.redis.redisson; import java.io.IOException; i 阅读全文
posted @ 2021-09-04 14:42 super超人 阅读(1327) 评论(0) 推荐(0)
摘要:spring-data-redis中的StringRedisTemplate从2.1及以上开始支持设置过期时间。之前版本只能设置值,不能设置过期时间。 阅读全文
posted @ 2021-09-04 13:01 super超人 阅读(4291) 评论(0) 推荐(1)
摘要:下载地址:https://www.netsarang.com/zh/xshell-download/ 阅读全文
posted @ 2021-09-03 12:31 super超人 阅读(70) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2021-09-02 21:27 super超人 阅读(23) 评论(0) 推荐(0)
摘要:mysql下载地址:https://downloads.mysql.com/archives/community/ 可以选择各个版本和对应系统版本下载。 安装步骤参考:https://blog.csdn.net/weixin_38239039/article/details/79629984 阅读全文
posted @ 2021-09-02 21:04 super超人 阅读(589) 评论(0) 推荐(0)
摘要:原文参考:https://blog.csdn.net/H900302/article/details/109726240 今天尝试使用easypoi做Excel导出,首先如它的名字一样,导出相比之前使用的poi确实简单了不少,但是它的官方文档是真的不详细,有待完善,拿我导出的文件来说吧(图如下),这 阅读全文
posted @ 2021-09-02 16:57 super超人 阅读(5678) 评论(0) 推荐(1)
摘要:idea查看内存使用情况: 勾选后,idea右下角出现内存占用情况,点击可清除内存。 阅读全文
posted @ 2021-09-02 10:04 super超人 阅读(6325) 评论(0) 推荐(0)
摘要:Idea中自定义注释模板后,生成的文档注释有红框: 解决办法: 效果:(再次生成文档注释,没有红框了) 阅读全文
posted @ 2021-09-01 22:09 super超人 阅读(927) 评论(1) 推荐(1)
摘要:Idea在方法和类上添加自定义注释模板: 1.类注释: 注释模板: /** * @className: $CLASSNAME$ * @author: liuyachao * @date: $date$ $time$ */ 编辑变量: 效果: 输入add提示addC,回车: 2.方法注释: 注释模板: 阅读全文
posted @ 2021-09-01 21:42 super超人 阅读(573) 评论(0) 推荐(0)
摘要:IDEA安装阿里巴巴编码规范插件的两种方式:在线安装和离线安装。 1.在线安装: 打开file-settings-Plugins.如图: 搜索到点击右边的install按钮,即可在线安装. 在线安装非常简单. 2.离线安装: 下载插件地址:https://plugins.jetbrains.com/ 阅读全文
posted @ 2021-09-01 18:50 super超人 阅读(2314) 评论(4) 推荐(0)