摘要: http://www.cubrid.org/blog/dev-platform/how-to-analyze-java-thread-dumps/When there is an obstacle, or when a Java based Web application is running much slower than expected,we need to usethread dumps. If thread dumps feel like very complicated to you,this article may help you very much. Here I will 阅读全文
posted @ 2012-05-18 15:33 balaamwe 阅读(748) 评论(0) 推荐(0) 编辑
摘要: http://blog.csdn.net/dlite/article/details/4218105 在历史上,Java试图提供过抢占式限制中断,但问题多多,例如前文介绍的已被废弃的Thread.stop、Thread.suspend和 Thread.resume等。另一方面,出于Java应用代码的健壮性的考虑,降低了编程门槛,减少不清楚底层机制的程序员无意破坏系统的概率。 如今,Java的线程调度不提供抢占式中断,而采用协作式的中断。其实,协作式的中断,原理很简单,就是轮询某个表示中断的标记,我们在任何普通代码的中都可以实现。 例如下面的代码: volatile bool isInterru 阅读全文
posted @ 2012-05-18 00:18 balaamwe 阅读(307) 评论(0) 推荐(0) 编辑