摘要:
1.安装7z打包工具并添加到环境变量 将项目下载到目录 2.执行下面脚本 @echo off SETLOCAL EnableDelayedExpansion :: 检查 edata-dataops-ui 目录是否存在 if not exist edata-dataops-ui ( echo Dire
阅读全文
posted @ 2024-11-05 09:11
张释文
阅读(17)
推荐(0)
摘要:
java8使用时间计算 public static void main(String[] args) { LocalDate localDate = LocalDate.now(); //1.获取周日 LocalDate with = localDate.with(DayOfWeek.SUNDAY)
阅读全文
posted @ 2024-02-01 14:27
张释文
阅读(46)
推荐(0)
摘要:
session可以用于请求后端数据共享 private static void flushSession(HttpServletRequest request, UserInfoDO userInfoDO) { String shortName = userInfo.getShortName();
阅读全文
posted @ 2023-07-05 17:26
张释文
阅读(196)
推荐(0)
摘要:
1. 概述Spring Data MongoDB模块提高了在 Spring 项目中与 MongoDB 数据库交互时的可读性和可用性。 在本教程中,我们将重点介绍在读取和写入 MongoDB 数据库时如何处理Java的ZonedDateTime对象。 2. 设置要使用 Spring Data Mong
阅读全文
posted @ 2023-06-29 10:43
张释文
阅读(154)
推荐(0)
摘要:
redis shake 开源的工具,地址:tair-opensource/RedisShake: redis-shake is a tool for Redis data migration and data filtering. redis-shake 是一个用于 Redis 数据迁移与过滤的工具
阅读全文
posted @ 2023-06-28 14:41
张释文
阅读(46)
推荐(0)
摘要:
命令 #列出所有命令 tasklist #删除进程命令 taskkill /pid 8468 -t -f #查找文字命令 findstr netstat -an|findstr 1521 #显示文件 filename.txt 的最后几行,其中 + q 参数将文件内容输出到屏幕上,并立即退出 type
阅读全文
posted @ 2023-06-20 14:22
张释文
阅读(17)
推荐(0)
摘要:
循环插入 DO $$ DECLARE tmp RECORD; BEGIN FOR tmp IN select distinct id from test LOOP INSERT INTO test1 (id,role_code,privilege_code,space_id) VALUES (FLO
阅读全文
posted @ 2023-06-14 22:24
张释文
阅读(342)
推荐(0)
摘要:
分组使用 HashMap<Boolean, Set<String>> collect = currentUserRoles.stream().collect(Collectors.groupingBy(this::isSupperAdminRoleCode, HashMap::new, Collec
阅读全文
posted @ 2023-06-13 22:21
张释文
阅读(38)
推荐(0)
摘要:
分页工具类 import cn.hutool.core.lang.Assert; import com.github.pagehelper.PageInfo; import com.google.common.collect.Lists; import org.springframework.uti
阅读全文
posted @ 2023-06-12 20:52
张释文
阅读(330)
推荐(0)
摘要:
代码示例: 注意Service中的返回值必须要和mapper中的返回值类型的 @Override public PageInfo<UserDO> test(ReqQueryDTO req) { PageHelper.startPage(req.getPageNumber(), req.getPage
阅读全文
posted @ 2023-06-12 20:30
张释文
阅读(16)
推荐(0)
摘要:
postgresql中根据条件创建一个虚拟字段。 条件是:如果id = 786168753672753152 就将marked字段设置为true否则设置为false,最后按照marked进行排序。 select name, id, case when id = 786168753672753152
阅读全文
posted @ 2023-06-12 17:30
张释文
阅读(107)
推荐(0)
摘要:
代码示例如下: @InterceptorIgnore(tenantLine = "1")public interface UserMapper extends BaseMapper<User> { @Select("SELECT * FROM user ${ew.customSqlSegment}"
阅读全文
posted @ 2023-06-12 15:05
张释文
阅读(293)
推荐(0)
摘要:
说明原因:使用的java8的parallelparrStream是并行的,但是.collect(Collectors.toList()) 使用了非线程安全的集合。 修改办法: 修改办法1:把parallelparrStream改为普通的stream ; 修改办法2: Collectors.toLis
阅读全文
posted @ 2023-05-31 14:31
张释文
阅读(588)
推荐(0)
摘要:
1. 查看本地所有分支git branch -a使用 git branch -a 命令可以查看所有本地分支和远程分支,发现远程的remote分支已经删除了,但本地还显示。 2. 查看远程分支git remote show origin使用命令 git remote show origin,可以查看r
阅读全文
posted @ 2023-05-25 16:07
张释文
阅读(535)
推荐(0)
摘要:
用“[ ]” 把key包装起来。示例: test: "[test1:test2:test3]"
阅读全文
posted @ 2023-05-11 21:26
张释文
阅读(691)
推荐(0)
摘要:
package test.config; import com.fasterxml.jackson.annotation.JsonAutoDetect; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxm
阅读全文
posted @ 2023-05-11 19:42
张释文
阅读(564)
推荐(0)
摘要:
核心代码 spring: cache: type: REDIS redis: time-to-live: 28800000 custom-ttl: { "xxx" : "1000000", "yyy": "6000000"} @Data @Component @Configuration @Conf
阅读全文
posted @ 2023-05-11 19:37
张释文
阅读(498)
推荐(0)
摘要:
@Value("${spring.cache.redis.time-to-live:43200000}") private Long redisKeyTtl;
阅读全文
posted @ 2023-05-10 18:33
张释文
阅读(158)
推荐(0)
摘要:
Redis现如今使用的场景越来越多?如何批量删除key呢? 参考 有人说用KEYS命令,刚开始学Redis的时候就是用这个命令列出库中键。 KEYS命令要谨慎使用。 为何?客观别急,我们先一步步来看。 KEYS 命令 Warning: consider KEYS as a command that
阅读全文
posted @ 2023-05-09 10:35
张释文
阅读(3437)
推荐(0)
摘要:
1.现在错误的用法: RLock lock = redisson.getLock(String.format(LOCK_KEY, 2));try { if (lock.tryLock()) { //处理 logger.info("aaaaaaaaaaaaaaaaaa");} catch(Except
阅读全文
posted @ 2023-04-20 18:39
张释文
阅读(206)
推荐(0)
摘要:
const { defineConfig } = require('@vue/cli-service') const CompressionPlugin = require('compression-webpack-plugin') const path = require('path') cons
阅读全文
posted @ 2023-04-17 11:43
张释文
阅读(2435)
推荐(0)
摘要:
header设置透传 @Configuration public class FeignRequestInterceptor implements RequestInterceptor { private static final String CONTENT_LENGTH_KEY = "conte
阅读全文
posted @ 2023-04-03 16:58
张释文
阅读(227)
推荐(0)
摘要:
编译指定命令 npm run build:tst 有时会便宜报错,因为缺少依赖使用 npm i 来安装依赖后然后再执行编译命令: npm i
阅读全文
posted @ 2023-03-31 12:33
张释文
阅读(163)
推荐(0)
摘要:
生产证书步骤 参考地址1:https://www.cnblogs.com/luxiaoyao/p/10034009.html#:~:text=windows%E4%B8%8B%E7%94%A8nginx%E9%85%8D%E7%BD%AEhttps%E6%9C%8D%E5%8A%A1%E5%99%A
阅读全文
posted @ 2023-03-30 18:35
张释文
阅读(299)
推荐(0)
摘要:
特别注意: maven会根据pom文件声明的顺序加载,如果先声明了B,后声明了C那么B的优先级高于C的优先级 MAVEN依赖的优先原则 maven依赖的优先原则1.依赖最短路径优先原则一个项目Demo依赖了两个jar包,其中A-B-C-X(1.0) , A-D-X(2.0)。由于X(2.0)路径最短
阅读全文
posted @ 2023-03-23 15:24
张释文
阅读(193)
推荐(0)
摘要:
使用ThreadLocal中的变量 @Cacheable(value = "hiteam:search", key = "(T(com.tst.TenantContextHandler).getCurrentTenantId()) + ':requirement:' + #req.getField(
阅读全文
posted @ 2023-03-23 14:16
张释文
阅读(24)
推荐(0)
摘要:
//上代码public static void main(String[] args) { int count = 10000000; test1(count); test2(count); } private static void test1(int count) { long l = Syst
阅读全文
posted @ 2023-03-09 11:17
张释文
阅读(1432)
推荐(0)
摘要:
Mybatis-plus的多租户接口insert插入值失败,报错。 org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.exceptions.PersistenceException: ##
阅读全文
posted @ 2023-03-06 19:48
张释文
阅读(1647)
推荐(0)
摘要:
【项目实践】一文带你搞定页面权限、按钮权限以及数据权限 - RudeCrab - 博客园 (cnblogs.com) 手把手教你搞定菜单权限设计,精确到按钮级别 - 知乎 (zhihu.com)
阅读全文
posted @ 2023-02-23 14:21
张释文
阅读(38)
推荐(0)
摘要:
package com.company.app.controller; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RestCont
阅读全文
posted @ 2023-01-28 14:44
张释文
阅读(48)
推荐(0)