tomcat问题..有高手懂吗?

04-10-15 winwu
我用的是tomcat5.0.28+postgresql7.43
错误:Cannot create PoolableConnectionFactory (Something unusual has occured to cause the driver to fail. Please report this exception: Exception: java.lang.NegativeArraySizeException Stack Trace


我的web.xml配置
: <resource-ref>
<description>postgreSQL Datasource example</description>
<res-ref-name>jdbc/postgres</res-ref-name>
<res-type>javax.sql.DataSource</res-type>
<res-auth>Container</res-auth>
</resource-ref>
我的server.xml配置:
<Context path="" docBase="/home/tools/jakarta-tomcat-5.0.28/webapps/airsoft"
debug="5" reloadable="true" crossContext="true">

<Logger className="org.apache.catalina.logger.FileLogger"
prefix="localhost_DBTest_log." suffix=".txt"
timestamp="true"/>
<Resource name="jdbc/postgres" auth="Container"
type="javax.sql.DataSource"/>

<ResourceParams name="jdbc/postgres">
<parameter>
<name>factory</name>
<value>org.apache.commons.dbcp.BasicDataSourceFactory</value>
</parameter>
<parameter>
<name>driverClassName</name>
<value>org.postgresql.Driver</value>
</parameter>
<parameter>
<name>url</name>
<value>jdbc:postgresql://192.168.1.128:5432/edn6</value>
</parameter>
<parameter>
<name>username</name>
<value>postgres</value>
</parameter>
<parameter>
<name>password</name>
<value></value>
</parameter>
<parameter>
<name>maxActive</name>
<value>20</value>
</parameter>
<parameter>
<name>maxIdle</name>
<value>10</value>
</parameter>
<parameter>
<name>maxWait</name>
<value>-1</value>
</parameter>
</ResourceParams>
</Context>


很急..请大家帮帮忙...

banq
2004-10-17 10:06
配置问题,可参考通用标准参数配置。

winwu
2004-10-18 17:30
问题我已经自己解决拉.....谢谢banq