Using c3p0 and JIRA

Stephan Krull August 11, 2011

We are running JIRA 4.1.2 Standalone on Debian 2.6.26. The database is configured manually in "server.xml" of tomcat. Since we had trouble with the common-dbcp standard connection pooling of tomcat we would like to use the c3p0 jdbc connection pooling

-------------------------- SNIP "server.xml" with standard connection pooling ------------------------------------
<Resource
name="jdbc/JiraDS"
auth="Container"
type="javax.sql.DataSource"
username="****"
password="****"
driverClassName="oracle.jdbc.driver.OracleDriver"
url="jdbc:oracle:oci:@****"
validationQuery="select 'validationQuery' from dual"
connectionProperties="SetBigStringTryClob=true"/>
-------------------------- END --------------------------------------------------------

does anybody have experience with using c3p0 in tomcat resource configuration for jira? i could not find any adequate information in the jira docs or the net at all (analyzed about 40 related hits) and jira support will not supply guidelines since this use case has not been tested before.

kind regards

s.krull

1 answer

1 accepted

0 votes
Answer accepted
Andrey Larionov
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 5, 2011

Your should specify type and factory properties of Resource.

Factory should implement javax.naming.spi.ObjectFactory interface and produce object of specified type. In dbcp for example it could be org.apache.commons.dbcp.datasources.SharedPoolDataSourceFactory and org.apache.commons.dbcp.datasources.SharedPoolDataSource, for example. In case of c3po i think there should be already implemented classes.

Suggest an answer

Log in or Sign up to answer