<div id="_htmlarea_default_style_" style="font:10pt arial,helvetica,sans-serif">Hello everyone, <br>
<br>
I have configured a mysql datasource on wesip's server.xml, <br>
copied the file mysql-connector-java-5.1.7-bin.jar under ${WESIP_HOME}/lib, <br>
restarted wesip but I always obtain the following exception running the Apache example for testing the connection
pool <br>
<br>
EXCEPTION: <br>
----------------------------------------------------------------------------------------------------------- <br>
<br>
org.apache.commons.dbcp.SQLNestedException: Cannot load JDBC driver class 'com.mysql.jdbc.Driver' <br>
at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:766) <br>
at org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:540) <br>
at foo.DBTest.init(DBTest.java:23) <br>
at org.apache.jsp.index$jsp._jspService(index$jsp.java:60) <br>
at org.apache.jasper.runtime.HttpJspBase.service(Unknown Source) <br>
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) <br>
at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(Unknown Source) <br>
at org.apache.jasper.servlet.JspServlet.serviceJspFile(Unknown Source) <br>
at org.apache.jasper.servlet.JspServlet.service(Unknown Source) <br>
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) <br>
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:200) <br>
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:146) <br>
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:206) <br>
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596) <br>
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433) <br>
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:946) <br>
at com.voztele.sipservlet.valves.ConvergedContextValve.invokeHTTP(ConvergedContextValve.java:144) <br>
at com.voztele.sipservlet.valves.ConvergedContextValve.invoke(ConvergedContextValve.java:64) <br>
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596) <br>
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433) <br>
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:946) <br>
at org.apache.catalina.core.StandardHttpContext.invoke(StandardHttpContext.java:2377) <br>
at com.voztele.sipservlet.core.ConvergedContext.invoke(ConvergedContext.java:98) <br>
at com.voztele.sipservlet.valves.ConvergedHostValve.invokeHTTP(ConvergedHostValve.java:337) <br>
at com.voztele.sipservlet.valves.ConvergedHostValve.invoke(ConvergedHostValve.java:98) <br>
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596) <br>
at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:124) <br>
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594) <br>
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118) <br>
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594) <br>
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433) <br>
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:946) <br>
at com.voztele.sipservlet.valves.ConvergedEngineValve.invoke(ConvergedEngineValve.java:98) <br>
at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596) <br>
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433) <br>
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:946) <br>
at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:994) <br>
at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:1105) <br>
at java.lang.Thread.run(Thread.java:595) <br>
Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver <br>
at java.net.URLClassLoader$1.run(URLClassLoader.java:200) <br>
at java.security.AccessController.doPrivileged(Native Method) <br>
at java.net.URLClassLoader.findClass(URLClassLoader.java:188) <br>
at java.lang.ClassLoader.loadClass(ClassLoader.java:306) <br>
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268) <br>
at java.lang.ClassLoader.loadClass(ClassLoader.java:251) <br>
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319) <br>
at java.lang.Class.forName0(Native Method) <br>
at java.lang.Class.forName(Class.java:164) <br>
at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:760) <br>
... 38 more <br>
<br>
----------------------------------------------------------------------------------------------------------- <br>
<br>
Follows the server.xml: <br>
----------------------------------------------------------------------------------------------------------- <br>
- <Server port="5005" shutdown="SHUTDOWN" debug="1"> <br>
- <Service name="WeSIP-Standalone"> <br>
<Connector
className="org.apache.catalina.connector.http.HttpConnector"
port="5075" minProcessors="5" maxProcessors="75" enableLookups="true"
acceptCount="10" debug="1" /> <br>
- <Connector
className="com.voztele.sipservlet.connector.SipConnector"
minProcessors="5" maxProcessors="75" enableLookups="true"
acceptCount="10" debug="1" addresses="10.107.109.108:5060"
pathName="com.voztele" protocol="udp"> <br>
- <ExtraProperties> <br>
<Property key="com.voztele.javax.sip.SER_ADDRESS" value="10.107.109.108" /> <br>
<Property key="com.voztele.javax.sip.SER_PORT" value="5080" /> <br>
<Property key="com.voztele.STATISTICS" value="false" /> <br>
<Property key="javax.sip.STACK_NAME" value="shootist" /> <br>
<Property key="javax.sip.THREAD_POOL_SIZE" value="100" /> <br>
<Property key="com.voztele.javax.sip.THREAD_POOL_SIZE" value="100" /> <br>
<Property key="com.voztele.javax.sip.REENTRANT_LISTENER" value="true" /> <br>
<Property key="javax.sip.AUTOMATIC_DIALOG_SUPPORT" value="false" /> <br>
<Property key="com.voztele.javax.sip.TRACE_LEVEL" value="0" /> <br>
</ExtraProperties> <br>
</Connector> <br>
- <Engine name="Standalone" defaultHost="10.107.109.108" debug="1"
className="com.voztele.sipservlet.core.ConvergedEngine"> <br>
<Mapper className="org.apache.catalina.core.StandardEngineMapper" protocol="HTTP/1.1" />
<br>
<Mapper className="org.apache.catalina.core.StandardEngineMapper" protocol="HTTP/1.0" />
<br>
<Mapper className="com.voztele.sipservlet.core.EngineSipMapper" protocol="SIP/2.0" />
<br>
<Logger className="org.apache.catalina.logger.FileLogger" timestamp="true" /> <br>
<Realm className="org.apache.catalina.realm.MemoryRealm" /> <br>
- <Host name="10.107.109.108" nameSip="10.107.109.108_5060"
debug="1" appBase="wesipapps" unpackWARs="true" autoDeploy="true"
className="com.voztele.sipservlet.core.ConvergedHost" port="5060"> <br>
<Logger className="org.apache.catalina.logger.FileLogger" timestamp="true" /> <br>
<Mapper className="com.voztele.sipservlet.core.SipHostMapper" protocol="SIP/2.0" />
<br>
<Mapper className="org.apache.catalina.core.HttpHostMapper" protocol="HTTP/1.1" />
<br>
<Mapper className="org.apache.catalina.core.HttpHostMapper" protocol="HTTP/1.0" />
<br>
- <DefaultContext useNaming="true" reloadable="true"> <br>
<Resource name="jdbc/TestDB" auth="Container" type="javax.sql.DataSource" /> <br>
- <ResourceParams name="jdbc/TestDB"> <br>
- <parameter> <br>
<name>username</name> <br>
<value>javauser</value> <br>
</parameter> <br>
- <parameter> <br>
<name>password</name> <br>
<value>javauser</value> <br>
</parameter> <br>
- <parameter> <br>
<name>driverClassName</name> <br>
<value>com.mysql.jdbc.Driver</value> <br>
</parameter> <br>
- <parameter> <br>
<name>url</name> <br>
<value>jdbc:mysql://opensips.server:3306/test</value> <br>
</parameter> <br>
- <parameter> <br>
<name>maxActive</name> <br>
<value>8</value> <br>
</parameter> <br>
- <parameter> <br>
<name>maxIdle</name> <br>
<value>4</value> <br>
</parameter> <br>
</ResourceParams> <br>
</DefaultContext> <br>
</Host> <br>
</Engine> <br>
</Service> <br>
</Server> <br>
<br>
----------------------------------------------------------------------------------------------------------- <br>
<br>
<br>
Thans in advance <br></div>