2.连接池测试时出错:
Warning! Connectivity to backend database not verified. This is either because required connection pool attribute "TestConnectionsOnReserve" has not been enabled, or an invalid value has been specified for attribute "TestTableName". Please check the server log for more details..
配置连接缓冲池,在“高级”中选中“保留时测试连接”即可。此时需要先激活更改再进行测试。否则还会报错。
3.jdbc jndi错误:
javax.naming.NameNotFoundException: Unable to resolve 'jdbc_fbysss. Resolved ''; remaining name 'jdbc_fbysss'
首先要在控制台中点击左边的控制栏中的服务->JDBC新建一个数据源,数据源名称无所谓,jndi name一定要注意,比如取名叫jdbc_fbysss,而且,jdbc源必须依赖于一个server。否则无法启动。
对于Spring项目,修改applicationContext.xml的dataSource,(Tomcat的连接池在这里就不需要了)。
(2)struts-config.xml
正式部署时出现异常:
ERROR Digester []: Parse Error at line 2 column
15: Document root element "struts-config", must match DOCTYPE root "null".
org.xml.sax.SAXParseException: Document root element "struts-config", must match
DOCTYPE root "null".
需要在struts-config.xml中第二行加入
5.ServletApi实现不一致情况
发现一个奇怪的现象,tomcat中,一个servlet的子类,如果没有声明init方法,会自动执行父类的init方法,而weblogic不会。
解决办法是显式声明init,super.init();
6.莫名其妙空指针错误
完整错误信息:
java.io.FileNotFoundException: F:\bea\wlserver_10.0\samples\domains\workshop\servers\cgServer\tmp\_WL_user\prj_fbysss\mlh5uz\war(拒绝访问。)
at java.io.FileInputStream.open(Ljava.lang.String;)V(Native Method)
at java.io.FileInputStream.(FileInputStream.java:106)
at workshop.util.filesystem.file.WlFileSystem.getInputStream(WlFileSyste
m.java:148)
at workshop.util.filesystem.FS.getInputStream(FS.java:262)
at javelin.jsp.JspParser.readStaticInclude(JspParser.java:3261)
at javelin.jsp.JspParser.parseStaticInclude(JspParser.java:3198)
at javelin.jsp.JspParser.processImplicitIncludes(JspParser.java:3289)
at javelin.jsp.JspParser.jspParse(JspParser.java:703)
at javelin.jsp.JspParser._parse(JspParser.java:504)
at javelin.jsp.JspParser.parse(JspParser.java:497)
at javelin.jsp.JspAnalyzer.parseFile(JspAnalyzer.java:113)
at javelin.jsp.JspAnalyzer.parse(JspAnalyzer.java:101)
at javelin.ProxySourceFile.parse(ProxySourceFile.java:117)
at javelin.SourceFile.getAst(SourceFile.java:542)
at javelin.SourceFile.getAst(SourceFile.java:516)
at javelin.ProxySourceFile.codeGen(ProxySourceFile.java:215)
at javelin.SourceFile.codeGen(SourceFile.java:310)
at javelin.client.ClientUtilsImpl$CodeGenJob.run(ClientUtilsImpl.java:11
05)
at javelin.client.Job.performJob(Job.java:81)
at javelin.client.ThreadPool$WorkerThread.run(ThreadPool.java:215)