<!--定義在從數據庫獲取新連接失敗后重復嘗試的次數。默認值: 30 ;小於等於0表示無限次--> <property name="acquireRetryAttempts" value="0"/> <!--重新嘗試的時間間隔,默認為:1000毫秒--> <property name="acquireRetryDelay" value="1000" /> <!--最大空閑時間,3600秒內未使用則連接被丟棄。若為0則永不丟棄。默認值: 0 --> <property name="maxIdleTime" value="3600"/> <!--c3p0全局的PreparedStatements緩存的大小。如果maxStatements與maxStatementsPerConnection均為0,則緩存不生效,只要有一個不為0,則語句的緩存就能生效。如果默認值: 0--> <property name="maxStatements" value="0"/> <!--maxStatementsPerConnection定義了連接池內單個連接所擁有的最大緩存statements數。默認值: 0 --> <property name="maxStatementsPerConnection" value="0"/> <!--定義所有連接測試都執行的測試語句。在使用連接測試的情況下這個一顯著提高測試速度。測試的表必須在初始數據源的時候就存在。Default: null--> <property name="preferredTestQuery" value="select 1"/> <!--每1800秒檢查所有連接池中的空閑連接。Default: 0 --> <property name="idleConnectionTestPeriod" value="1800"/> <!-- 獲取連接時測試有效性,每次都驗證連接是否可用 --> <property name="testConnectionOnCheckout" value="false"/>