• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Data Source in TOMCAT 5.5.4

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Does anyone know how to create data source in TOMCAT 5.5.4? I successfully created data sources in earlier versions of TOMCAT. So if anyone has become able to do this, pls do post a response.
 
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm not sure how you are trying to create the datasource.But you can use org.apache.commons.dbcp and org.apache.commons.pool package classes to create the DataSource in Tomcat(5.5.12) and I myself used them for DataSource creation.Hope you too can implement the same and try it out
-----
Class.forName(jdbcDriverClassName);
connectionPool = new GenericObjectPool(null);
connectionFactory = new DriverManagerConnectionFactory(jdbcConnectionURL,UserID,Password);
poolableConnectionFactory = new PoolableConnectionFactory(connectionFactory,connectionPool,null,null,false,true);
dataSource = new PoolingDataSource(connectionPool);
--------

Regards,
Sujith
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic