when i use C3p0PoolingConnectionProvider it default use ComboPooledDataSource 。
at StdSchedulerFactory line 1392
private void populateProviderWithExtraProps(PoolingConnectionProvider cp, Properties props) throws Exception { Properties copyProps = new Properties(); copyProps.putAll(props); // Remove all the default properties first (they don't always match to setter name, and they are already // been set!) copyProps.remove(PoolingConnectionProvider.DB_DRIVER); copyProps.remove(PoolingConnectionProvider.DB_URL); copyProps.remove(PoolingConnectionProvider.DB_USER); copyProps.remove(PoolingConnectionProvider.DB_PASSWORD); copyProps.remove(PoolingConnectionProvider.DB_MAX_CONNECTIONS); copyProps.remove(PoolingConnectionProvider.DB_VALIDATION_QUERY); props.remove(PoolingConnectionProvider.POOLING_PROVIDER); setBeanProps(cp.getDataSource(), copyProps); }
"copyProps" not remove properties "validateOnCheckout",but ComboPooledDataSource don't have this properties ,lead to Exception
Caused by: java.lang.NoSuchMethodException: No setter for property 'validateOnCheckout' at org.quartz.impl.StdSchedulerFactory.setBeanProps(StdSchedulerFactory.java:1447) ~[quartz-2.3.0.jar:na] at org.quartz.impl.StdSchedulerFactory.populateProviderWithExtraProps(StdSchedulerFactory.java:1405) ~[quartz-2.3.0.jar:na] at org.quartz.impl.StdSchedulerFactory.instantiate(StdSchedulerFactory.java:1040) ~[quartz-2.3.0.jar:na] ... 74 common frames omitted
when i use C3p0PoolingConnectionProvider it default use ComboPooledDataSource 。
at StdSchedulerFactory line 1392
private void populateProviderWithExtraProps(PoolingConnectionProvider cp, Properties props) throws Exception { Properties copyProps = new Properties(); copyProps.putAll(props); // Remove all the default properties first (they don't always match to setter name, and they are already // been set!) copyProps.remove(PoolingConnectionProvider.DB_DRIVER); copyProps.remove(PoolingConnectionProvider.DB_URL); copyProps.remove(PoolingConnectionProvider.DB_USER); copyProps.remove(PoolingConnectionProvider.DB_PASSWORD); copyProps.remove(PoolingConnectionProvider.DB_MAX_CONNECTIONS); copyProps.remove(PoolingConnectionProvider.DB_VALIDATION_QUERY); props.remove(PoolingConnectionProvider.POOLING_PROVIDER); setBeanProps(cp.getDataSource(), copyProps); }"copyProps" not remove properties "validateOnCheckout",but ComboPooledDataSource don't have this properties ,lead to Exception
Caused by: java.lang.NoSuchMethodException: No setter for property 'validateOnCheckout' at org.quartz.impl.StdSchedulerFactory.setBeanProps(StdSchedulerFactory.java:1447) ~[quartz-2.3.0.jar:na] at org.quartz.impl.StdSchedulerFactory.populateProviderWithExtraProps(StdSchedulerFactory.java:1405) ~[quartz-2.3.0.jar:na] at org.quartz.impl.StdSchedulerFactory.instantiate(StdSchedulerFactory.java:1040) ~[quartz-2.3.0.jar:na] ... 74 common frames omitted