000025525 - Tomcat 5.5 datasource format

Document created by RSA Customer Support Employee on Jun 16, 2016Last modified by RSA Customer Support Employee on Apr 22, 2017
Version 2Show Document
  • View in full screen mode

Article Content

Article Number000025525
Applies Totomcat 5.5
IssueTomcat server.xml datasource configuration
Notes

Tomcat 5.5+ defines dB connection in server.xml in a different way than that in Tomcat 5.0. Here is how to define the dB connection in the server.xml. 

 
   <Resource name="jdbc/QEMsSql" 
  type="javax.sql.DataSource"
  url="jdbc:microsoft:sqlserver://10.104.100.65:1433;database=PMDB575"
  SelectMethod="Cursor"
  password="575user"
  maxActive="200"
  maxWait="5000"
  driverClassName="com.microsoft.jdbc.sqlserver.SQLServerDriver"
  username="575user"
  maxIdle="10"
  validationQuery="Select 1"
  pathname="conf/Catalina/localhost/pmws_server.xml" />
 
Otherwise, you would get
2007-05-03 14:12:08,211 ERROR [main] [] [] [com.passmarksecurity.dao.util.DBConnectionFactory] - <Unable to get DB connection>
org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create JDBC driver of class '' for connect URL 'null'.

Legacy Article IDa34804

Attachments

    Outcomes