摘要: 当你有 一个类A,B两个成员方法同时加锁,而A调用B时就会加两次锁,如果是不可重入锁就会死锁。 阅读全文
posted @ 2020-02-10 22:07 佐仓双叶 阅读(879) 评论(0) 推荐(0) 编辑
摘要: 完整项目见 demo_ssm https://gitee.com/anti-murphy/demo_ssm 第一步:配置web.xml <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" 阅读全文
posted @ 2020-02-07 20:26 佐仓双叶 阅读(181) 评论(0) 推荐(0) 编辑
摘要: 完整项目见 https://gitee.com/anti-murphy/demo_ssm 第一步: 在spring文件夹下新建如图三个文件 <?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework. 阅读全文
posted @ 2020-02-07 20:20 佐仓双叶 阅读(201) 评论(0) 推荐(0) 编辑
摘要: 完整项目见 https://gitee.com/anti-murphy/demo_ssm 第一步:在resources目录下新建jdbc.properties文件 jdbc.driver=com.mysql.cj.jdbc.Driver jdbc.url=jdbc:mysql://localhost 阅读全文
posted @ 2020-02-07 20:13 佐仓双叶 阅读(129) 评论(0) 推荐(0) 编辑
摘要: 完整项目见 https://gitee.com/anti-murphy/demo_ssm 第一步:确保 idea,maven, tomcat, JDK 已安装 第二部:创建项目 用如图所示的模板创建 修改项目目录结构如图 第三步:pom.xml <properties> <project.build 阅读全文
posted @ 2020-02-07 20:01 佐仓双叶 阅读(216) 评论(0) 推荐(0) 编辑
摘要: git rm -r --cached . git add . git commit -m 阅读全文
posted @ 2020-02-07 16:01 佐仓双叶 阅读(199) 评论(0) 推荐(0) 编辑
摘要: html 提交 “你好”,后台显示 “ä½ å¥½” 。 经检验是将 URL编码为 UTF-8,而URL使用 ISO-8859-1。 解决办法一: 在 Controller 进行转码。 username=new String(username.getBytes("ISO-8859-1"), "UTF 阅读全文
posted @ 2020-02-02 17:06 佐仓双叶 阅读(905) 评论(0) 推荐(0) 编辑
摘要: 打开 Help/Edit Custom VM Options 添加 -Dfile.encoding=UTF-8 再在项目 的 run configuration 中的 VM Options 添加 -Dfile.encoding=UTF-8 问题解决 阅读全文
posted @ 2020-02-02 16:56 佐仓双叶 阅读(133) 评论(0) 推荐(0) 编辑
摘要: pom.xml <!-- https://mvnrepository.com/artifact/com.mchange/c3p0 --> <dependency> <groupId>com.mchange</groupId> <artifactId>c3p0</artifactId> <versio 阅读全文
posted @ 2019-12-03 00:32 佐仓双叶 阅读(470) 评论(0) 推荐(0) 编辑
摘要: pom <dependency> <groupId>log4j</groupId> <artifactId>log4j</artifactId> <version>1.2.17</version> </dependency> 配置 ### 设置### log4j.rootLogger = debug 阅读全文
posted @ 2019-12-02 23:26 佐仓双叶 阅读(116) 评论(0) 推荐(0) 编辑