![](https://img-blog.csdnimg.cn/20201014180756738.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Java
Tayl0r_
这个作者很懒,什么都没留下…
展开
-
java笔记(1)
/** * Create a new {@link ApplicationHome} instance. */ public ApplicationHome() { this(null); } /** * Create a new {@link ApplicationHome} instance for the specified原创 2016-09-12 14:09:08 · 332 阅读 · 0 评论 -
java嵌套类(Nested Classes)总结
A nested class is any class whose declaration occurs within the body of another class or interface. A top level class is a class that is not a neste转载 2016-09-12 14:17:30 · 342 阅读 · 0 评论 -
深度剖析ConcurrentHashMap
ConcurrentHashMap的目的 多线程环境下,使用Hashmap进行put操作会引起死循环,导致CPU利用率接近100%,所以在并发情况下不能使用HashMap。虽然已经有一个线程安全的HashTable,但是HashTable容器使用synchronized(他的get和put方法的实现代码如下)来保证线程安全,在线程竞争激烈的情况下HashTable的效率非常低下。因为当一个线转载 2016-09-06 23:38:21 · 254 阅读 · 0 评论 -
mysql异常:Communications link failure
**1.问题发生原因 在Docker上运行的程序,突然之间报这个错误,但在本地测试正常。故先考虑的是否是容器问题,经检测,其他程序运行正常 最后发现是自己程序优化问题导致:程序与MySQL通讯失败了,即连接失败了。此为程序打开数据库连接后,等到做数据库操作时,发现连接被MySQL关闭掉了。而在MySQL这一层,MySQL5配置上默认将连接的等待时间(wait_ti原创 2016-09-22 10:30:58 · 1267 阅读 · 0 评论