tietang / javamelody

Automatically exported from code.google.com/p/javamelody
0 stars 1 forks source link

Need to enable the monitoring of c3p0 combo pool resource for database connections #380

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Hi,

I have seen in JdbcWraper & JdbcWraperHelper classes that you support

1. org.apache.tomcat.dbcp.dbcp.BasicDataSource
2. org.apache.commons.dbcp.BasicDataSource
3. org.apache.tomcat.jdbc.pool.DataSource

Can you add support for c3p0 combo pooled datasource 
(com.mchange.v2.c3p0.ComboPooledDataSource) as well.

Thanks

Original issue reported on code.google.com by gsanathk...@gmail.com on 14 Feb 2014 at 8:39

GoogleCodeExporter commented 9 years ago
Changing priority from High to Low, because there are much higher priorities 
than this.

Original comment by evernat@free.fr on 14 Feb 2014 at 9:05

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
hi , could you please let me how to gather sql statistics ? i tried all the 
combinations 
(http://code.google.com/p/javamelody/wiki/UserGuideAdvanced#Alternative_for_moni
toring_of_sql_requests)

below is my config defintion.
<bean id="dataSource" class="com.mchange.v2.c3p0.ComboPooledDataSource"
        destroy-method="close">
        <property name="driverClass" value="${db.driver}" />
        <property name="jdbcUrl" value="${jdbc.url}" />
        <property name="user" value="${username}" />
        <property name="password" value="${password}" />
        <property name="unreturnedConnectionTimeout" value="300" />
        <property name="minPoolSize" value="30" />
        <property name="maxPoolSize" value="100" />
        <property name="idleConnectionTestPeriod" value="500" />
    </bean>

    <bean id="sessionFactory"
        class="org.springframework.orm.hibernate4.LocalSessionFactoryBean">
        <property name="dataSource" ref="dataSource"></property>
        <property name="mappingLocations">
            <value>classpath*:com/xxx/*.hbm.xml</value>
        </property>

        <property name="hibernateProperties">
            <props>
                <prop key="hibernate.connection.driver_class">net.bull.javamelody.JdbcDriver</prop>
                <prop key="hibernate.jdbc.factory_class">net.bull.javamelody.HibernateBatcherFactory</prop>
                <prop key="connection.pool_size">${db.connectionPoolSize}</prop>
                <prop key="hibernate.dialect">${db.driver.dialect}</prop>
            </props>
        </property>
    </bean>

Original comment by logins...@gmail.com on 7 Jun 2014 at 9:59