随笔分类 -  java

摘要://根据名字的key,如果key数量超过100,就进行一次删除public int clearRedis(@PathVariable("prefix") String prefix) throws IOException { ScanOptions options = ScanOptions.sca 阅读全文
posted @ 2024-09-10 10:29 翱翔的小鱼 阅读(363) 评论(0) 推荐(0)
摘要:java 代码: public List<Department> getAllChildrenDepartmentsFlat(Long parentId) { List<Department> allDepartments = departmentRepository.findAll(); // 假 阅读全文
posted @ 2024-04-19 11:18 翱翔的小鱼 阅读(43) 评论(0) 推荐(0)
摘要:参考文件:https://blog.csdn.net/shenmoren6/article/details/80337662?utm_source=blogxgwz1 详细信息:https://blog.csdn.net/zsq520520/article/details/50952830 阅读全文
posted @ 2018-10-25 14:00 翱翔的小鱼 阅读(2339) 评论(0) 推荐(0)
摘要:参考链接:https://blog.csdn.net/qq_15260315/article/details/80907056 经尝试,返回html界面没问题,但是返回jsp界面是有问题的,just like this: 经查询是启动的问题,直接启动没有在tomcat中生成jsp的相关文件,可以使用 阅读全文
posted @ 2018-10-19 11:26 翱翔的小鱼 阅读(4312) 评论(0) 推荐(0)
摘要:1.把Spring Boot打包成JAR的形式,需要在pom.xml文件对应以下代码 只要一次双击clean,compile(重新编译),deploy,就会在target中生成.jar文件,到这块项目打包成功。 3.找到.jar文件路径,在cmd中进入到该文件目录下,运行: java -jar ** 阅读全文
posted @ 2018-10-18 15:11 翱翔的小鱼 阅读(567) 评论(0) 推荐(0)
摘要:其中 在java doc中,并不提倡我们直接使用ThreadPoolExecutor,而是使用Executors类中提供的几个静态方法来创建线程池: Executors.newCachedThreadPool(); //创建一个缓冲池,缓冲池容量大小为Integer.MAX_VALUE Execut 阅读全文
posted @ 2018-09-03 14:01 翱翔的小鱼 阅读(4187) 评论(0) 推荐(1)