这几天被集群并发问题快折腾死了,望哪位高人看下到底是哪里出现了问题。 Apache Server是正常的,各服务器的Tomcat 也是正常的,但当Apache的连接数达到 300左右的时候,JK就会出现如下的异常信息,然后整个系统...
分类:
Web程序 时间:
2015-04-30 16:22:51
阅读次数:
2861
struts2 采用声明式的方法管理异常处理,因此,我们无需在 execute方法中编写 大量的 try...catch语句来捕获异常;只需要在 struts.xml文件中配置异常的映射机制,struts2 便能够处理并转入响应的视图资源.eg:页面输出 异常信息:例如internal_Error....
分类:
其他好文 时间:
2015-04-30 12:20:40
阅读次数:
125
当程序运行异常时,e.printStackTrace()会打印出异常。但是很多时候我们希望将这些异常输出到日志中,以便日后可以随时查看到,可以通过这些异常快速的找到程序发生异常的代码。
那么有办法可以将异常的详细信息输出到文件吗?答案是肯定的。
程序:
public static String getTrace(Throwable t) {
StringWriter stringWr...
分类:
编程语言 时间:
2015-04-29 11:45:47
阅读次数:
136
现象:删除某行的时候,出现如下异常信息‘NSInternalInconsistencyException‘,reason:‘Invalidupdate:invalidnumberofrowsinsection0.Thenumberofrowscontainedinanexistingsectionaftertheupdate(5)mustbeequaltothenumberofrowscontainedinthatsectionbeforetheupdate(5),plu..
分类:
其他好文 时间:
2015-04-29 07:24:24
阅读次数:
195
?##sys.exc_info()
返回 (type, value, traceback). type为异常类型, value为异常的参数(通常为异常错误的信息), traceback为跟踪回溯的对象. exc_type, exc_value, exc_traceback = sys.exc_info()
print "*** print sys.exc_info:"
pri...
分类:
编程语言 时间:
2015-04-28 11:55:29
阅读次数:
289
ConcurrentHashMap的一个NullPointerException异常引起,结合ConcurrentHashMap源码分析为什么ConcurrentHashMap不允许空key和value以及如何改造进行支持。1、异常分析今天碰到一个异常,信息如下:Java12345678910111...
分类:
编程语言 时间:
2015-04-23 15:05:19
阅读次数:
164
Eclipse中设置JVM内存今天在eclipse中测试把文档转换为图片的时候,报出了下面的错误:java.lang.OutOfMemoryError: Java heap space从上边的异常信息可以看到,JVM需要使用的内存已经超过了我们分配给虚拟机可以使用的最大内存。所以问题就转化为如何设置...
分类:
系统相关 时间:
2015-04-17 17:47:47
阅读次数:
152
在启动WCF服务时,报错:
“net.tcp://localhost:8080/tcpTest”处带有协定“"ITestService"”的 ChannelDispatcher 无法打开其 IchannelListener。
在查看详细异常信息时:找到InnerException异常信息中,发现:
{"未提供服务证书。请在 ServiceCredentials 中指定服务证书。"}
...
分类:
其他好文 时间:
2015-04-14 16:41:03
阅读次数:
302
异常信息:java.lang.IndexOutOfBoundsException: index=3 count=2在instantiateItem各个条目View的时候。会有container.addView(view, 0);这样一行代码。如果写成container.addView(view, p...
分类:
其他好文 时间:
2015-04-14 12:49:42
阅读次数:
433
今天在jetty下配置一个jsp模版的报表页面,报如下异常信息:
org.apache.jasper.JasperException: PWC6345: There is an error in invoking javac. A full JDK (not just JRE) is required
at org.apache.jasper.compiler.DefaultError...
分类:
Web程序 时间:
2015-04-13 09:37:36
阅读次数:
228