摘要: pipeline { agent any stages { stage('拉取代码') { agent none steps { checkout([$class: 'GitSCM', branches: [[name: '*/master']], doGenerateSubmoduleConfig 阅读全文
posted @ 2022-02-15 16:17 紫川先生 阅读(185) 评论(0) 推荐(0)
摘要: rpm 包下载地址 https://mirrors.tuna.tsinghua.edu.cn/jenkins/ rpm安装 rpm -ivh jenkins-2.183-1.1.noarch.rpm 修改配置文件 vi /etc/sysconfig/jenkins #修改:JENKINS_USER 阅读全文
posted @ 2022-02-09 17:29 紫川先生 阅读(284) 评论(0) 推荐(0)
摘要: #防火墙关闭 service firewalld stop #防火墙开启 service firewalld start #查看防火墙状态 systemctl status firewalld #设置开机禁用防火墙 systemctl disable firewalld #设置开机启用防火墙 sys 阅读全文
posted @ 2022-01-28 10:00 紫川先生 阅读(84) 评论(0) 推荐(0)
摘要: 一、安装依赖 yum -y install policycoreutils openssh-server openssh-clients postfix #启动ssh服务&设置为开机启动 systemctl enable sshd && sudo systemctl start sshd 查看ssh 阅读全文
posted @ 2021-12-27 16:30 紫川先生 阅读(58) 评论(0) 推荐(0)
摘要: import java.util.concurrent.ArrayBlockingQueue; import java.util.concurrent.BlockingQueue; import java.util.concurrent.atomic.AtomicInteger; import st 阅读全文
posted @ 2021-12-05 17:58 紫川先生 阅读(34) 评论(0) 推荐(0)
摘要: spring4正常执行流程: 环绕通知之前 前置通知 业务代码 环绕通知之后 后置通知 返回通知 spring4异常执行流程: 环绕通知之前 前置通知 后置通知 异常通知 spring5正常执行流程: 环绕通知之前 前置通知 业务代码 返回通知 后置通知 环绕通知之后 spring5异常执行流程: 阅读全文
posted @ 2021-11-20 09:48 紫川先生 阅读(32) 评论(0) 推荐(0)
摘要: 事件的生产者 import com.alibaba.fastjson.JSON; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; import org.s 阅读全文
posted @ 2021-11-10 09:21 紫川先生 阅读(44) 评论(0) 推荐(0)
摘要: pom 文件 <dependency> <!--导出到excel--> <groupId>net.sf.jxls</groupId> <artifactId>jxls-core</artifactId> <version>1.0.6</version> </dependency> <!--4.1.2 阅读全文
posted @ 2021-10-09 10:48 紫川先生 阅读(3328) 评论(0) 推荐(0)
摘要: 公平锁和非公平锁 //默认是非公平锁,可以设置为公平锁 Lock lock = new ReentrantLock(); public ReentrantLock() { sync = new NonfairSync(); } 公平锁:多个线程按照申请的顺序获取锁 非公平锁:多个线程获取锁的顺序并不 阅读全文
posted @ 2021-09-30 16:15 紫川先生 阅读(45) 评论(0) 推荐(0)
摘要: 集合类不安全的问题 List<String> list = new ArrayList<>(); for (int i = 0; i < 10; i++) { new Thread(()->{ //多个线程修改同一个资源list list.add(UUID.randomUUID().toString 阅读全文
posted @ 2021-09-30 10:09 紫川先生 阅读(35) 评论(0) 推荐(0)