java - jdbc connection string with c3p0 -
i have jdbc configured c3p0. however, worried possible conflicts, since of parameters in jdbc string , c3p0 similar.
here jdbc string:
jdbc:mysql://1.1.1.1:3306/db?usessl=true&requiressl=true&connecttimeout=15000&sockettimeout=30000&autoreconnect=true
we decided include connecttimeout, sockettimeout, autoreconnect because otherwise took long switch replica if master crashes. ( using mysql rds multi-az ).
here c3p0 properties:
<property name="acquireincrement" value="3"/> <property name="minpoolsize" value="5"/> <property name="maxpoolsize" value="10"/> <property name="maxidletime" value="3600"/> <!-- 1 hour --> <property name="maxconnectionage" value="7200"/> <property name="maxidletimeexcessconnections" value="600"/> <property name="idleconnectiontestperiod" value="180"/> <property name="testconnectiononcheckin" value="true"/> <property name="testconnectiononcheckout" value="false"/>
any ideas / suggestions? maybe has production-ready configuration?
best regards, maksim
Comments
Post a Comment