摘要: 1、pom.xml中添加 <dependency> <groupId>cn.hutool</groupId> <artifactId>hutool-all</artifactId> <version>5.2.3</version> </dependency> <dependency> <groupI 阅读全文
posted @ 2020-07-03 14:58 蛋挞小子 阅读(1709) 评论(0) 推荐(0) 编辑
摘要: 1、pom.xml文件引入 <dependency> <groupId>cn.hutool</groupId> <artifactId>hutool-all</artifactId> <version>5.2.3</version> </dependency> <dependency> <group 阅读全文
posted @ 2020-07-02 11:32 蛋挞小子 阅读(1717) 评论(0) 推荐(0) 编辑
摘要: 1、连接mysql,输入密码进入 mysql -u root -p 2、查看当前连接超时时间,一般默认是28800秒及8小时 SHOW GLOBAL VARIABLES LIKE '%timeout%'; 3、先在服务器管理器中停止Mysql服务,然后修改默认配置文件my.ini,最后重启Mysql 阅读全文
posted @ 2020-06-29 15:57 蛋挞小子 阅读(1484) 评论(0) 推荐(0) 编辑
摘要: String filePath = "指定文件写入路径"; // 例如:D:\\files\\test.txt BufferedWriter bw= new BufferedWriter (new OutputStreamWriter (new FileOutputStream (filePath, 阅读全文
posted @ 2020-06-28 18:16 蛋挞小子 阅读(569) 评论(0) 推荐(0) 编辑
摘要: public class Singleton { // volatile防止指令重排序 private volatile static Singleton instance = null; public static Singleton getInstance() { // 多线程竞争情况下,其他线 阅读全文
posted @ 2020-06-09 09:41 蛋挞小子 阅读(427) 评论(0) 推荐(0) 编辑
摘要: 第一种方式: import java.util.concurrent.CountDownLatch; public class ConcurrentTest { private static CountDownLatch latch= new CountDownLatch(1); public st 阅读全文
posted @ 2020-06-08 11:32 蛋挞小子 阅读(615) 评论(0) 推荐(0) 编辑
摘要: // 需要导入包 import net.sf.json.JSONObject; // json形式的字符串 String str = "{'company':'Trump','userInfo':[{'id':1000,'name':'唐纳德·特朗普','age':'78','hobby':'发推特 阅读全文
posted @ 2020-06-03 16:56 蛋挞小子 阅读(194) 评论(0) 推荐(0) 编辑
摘要: 签名工具类: package app.action.signUtil; import app.action.wx.Sign; import com.alibaba.druid.util.StringUtils; import okhttp3.HttpUrl; import org.apache.co 阅读全文
posted @ 2020-04-14 12:18 蛋挞小子 阅读(2384) 评论(7) 推荐(1) 编辑
摘要: 1、查看linux版本(我的系统CentOS 7) 命令:uname -r 2、更新yum 命令:yum update 3、安装docker 命令:yum install docker 4、测试docker是否安装成功 命令:docker version 5、启动docker 命令:systemct 阅读全文
posted @ 2019-12-31 11:32 蛋挞小子 阅读(553) 评论(0) 推荐(0) 编辑
摘要: windows版nginx安装及配置 一、准备工作 1、Nginx安装包 下载地址:http://nginx.org/en/download.html 2.Tomcat安装包 下载地址:https://tomcat.apache.org/ 3、准备完成 二、Tomcat配置部署及启动 1、配置tom 阅读全文
posted @ 2019-12-13 11:34 蛋挞小子 阅读(2532) 评论(0) 推荐(2) 编辑