pax_global_header 0000666 0000000 0000000 00000000064 13154316420 0014511 g ustar 00root root 0000000 0000000 52 comment=ec8510710ac71f79f513c19f35d5da320c92e2f2 HikariCP-HikariCP-2.7.1/ 0000775 0000000 0000000 00000000000 13154316420 0014602 5 ustar 00root root 0000000 0000000 HikariCP-HikariCP-2.7.1/.editorconfig 0000664 0000000 0000000 00000000427 13154316420 0017262 0 ustar 00root root 0000000 0000000 # EditorConfig is awesome: http://EditorConfig.org # top-most EditorConfig file root = true [**] end_of_line = lf insert_final_newline = true charset = utf-8 indent_style = space trim_trailing_whitespace = true [**.{java,xml}] indent_size = 3 [**.{yaml,yml}] indent_size = 2 HikariCP-HikariCP-2.7.1/.github/ 0000775 0000000 0000000 00000000000 13154316420 0016142 5 ustar 00root root 0000000 0000000 HikariCP-HikariCP-2.7.1/.github/ISSUE_TEMPLATE.md 0000664 0000000 0000000 00000000346 13154316420 0020652 0 ustar 00root root 0000000 0000000 #### Environment ``` HikariCP version: x.x.x JDK version : 1.8.0_111 Database : PostgreSQL|MySQL|... Driver version : x.x.x ``` ----------------------------------------------------------------------------------------- HikariCP-HikariCP-2.7.1/.gitignore 0000664 0000000 0000000 00000000300 13154316420 0016563 0 ustar 00root root 0000000 0000000 .classpath .project .settings/ target/ dependency-reduced-pom.xml .DS_Store **/*.iml *.class *.jar *.war *.ear *.iml *.iws *.ipr .tm_* .classpath .project .settings/ .idea/ .gradle/ out/ HikariCP-HikariCP-2.7.1/.travis.yml 0000664 0000000 0000000 00000001436 13154316420 0016717 0 ustar 00root root 0000000 0000000 sudo: false language: java dist: - trusty before_script: - if [[ "x$JDK" == *'x9'* ]]; then export MAVEN_SKIP_RC=true; fi - if [[ "x$JDK" != *'x9'* ]]; then export COVERALLS=coveralls:report; fi script: - export JDK8_HOME=$(jdk_switcher home oraclejdk8) - export JDK9_HOME=/usr/lib/jvm/java-9-oracle - test -d "${JDK9_HOME}" || export JDK9_HOME=$(jdk_switcher home oraclejdk8) before_cache: # No sense in caching current build artifacts - rm -rf $HOME/.m2/repository/com/zaxxer cache: directories: - $HOME/.m2/repository matrix: fast_finish: true include: - jdk: oraclejdk8 - jdk: oraclejdk9 env: - JDK=9 install: /bin/true script: - mvn package -Dskip.unit.tests=true -Dmaven.javadoc.skip=true -V -B - mvn test $COVERALLS -V -P coverage HikariCP-HikariCP-2.7.1/CHANGES 0000664 0000000 0000000 00000073104 13154316420 0015602 0 ustar 00root root 0000000 0000000 HikariCP Changes Changes in 2.7.1 * issue 968 Wrong label order in MicrometerMetricsTracker for the connection usage metric. * issue 967 incorrect bitwise operator value in ConcurrentBag.requite method intended to cause parkNanos() to be called every 256 iterations. Thanks to @ztkmkoo for finding this. Changes in 2.7.0 * added support for micrometer metrics (currently Alpha-level support). * issue 905 mask JDBC password in URLs * issue 940 fix Prometheus metric collector for multiple data config * issue 941 add support for setting a default schema * issue 955 fix possible race condition when Statements are closed on different threads from which they were created. Changes in 2.6.3 * issue 878 load driver class from ThreadContext classloader if it is not found via the regular classloader. Changes in 2.6.2 * issue 890 add support for Prometheus metrics and multiple HikariCP pools. * issue 880 fix race condition caused by sorting collection while the condition of sort can change. * issue 876 add support for using a Prometheus CollectorRegistry other than the default one. * issue 867 support network timeout even for Connection.isValid(). * issue 866 mark commit state dirty when Connection.getMetaData() is called. Changes in 2.6.1 * issue 821 if a disconnection class exception is thrown during initial connection setup, do not set the flag that indicates that checkDriverSupport() is complete. * issue 835 fix increased CPU consumption under heavy load caused by excessive spinning in the ConcurrentBag.requite() method. * issue 817 updated behavior of new initializationFailTimeout, please see the official documentation for details. * issue 742 add direct MXBean accessor methods to HikariDataSource for users who do not want run run JMX. Changes in 2.6.0 * Redesign of the contention code path resulting in doubling contended throughput; now contended pool access retains 98% of the uncontended throughput. * issue 793 add new HikariConfig method, setScheduledExecutor(ScheduledExecutorService), and deprecate method setScheduledExecutorService(ScheduledThreadPoolExecutor). It is unfortunate that the deprecated method has the more accurate name, but its signature cannot be changed without breaking binary compatibility. * issue 770 add a new property initializationFailTimeout, and deprecate configuration property initializationFailFast. * issue 774 significantly improve spike load handling. * issues 518/769 add new metric for tracking how long physical connection acquisition is taking. DropWizard histogram name "ConnectionCreation", and Prometheus summary name "hikaricp_connection_creation_millis". * issue 741 cancel HouseKeeper task on pool shutdown. If the ScheduledExecutor being used did not belong to HikariCP, this task would remain scheduled after shutdown, causing a memory leak. * issue 781 more technically accurate wording of pool startup and shutdown log messages. Changes in 2.5.1 * issue 719 only reset lastConnectionFailure after a successful dataSource.getConnection() call. * issue 716 do not scan deeper than 10 nested SQLExceptions, it's typically a trap ... a chain that never terminates. * issue 714 fix possible issue with cross-thread visibility. Change pool entry state from AtomicInteger w/lazySet() to a volatile int with use of AtomicIntegerFieldUpdater. Changes in 2.5.0 * Release 2.5.0 marks the start of a Java 8 HikariCP artifact. The Java 7 artifact is now called "HikariCP-java7". * HikariCP 2.5.0 and HikariCP-java7 2.4.8 have identical functionality. Changes in 2.4.12 * issue 878 search for driverClass in both HikariCP class classloader and Thread Context ClassLoader Changes in 2.4.11 * issue 793 add new HikariConfig method, setScheduledExecutor(ScheduledExecutorService), and deprecate method setScheduledExecutorService(ScheduledThreadPoolExecutor). It is unfortunate that the deprecated method has the more accurate name, but its signature cannot be changed without breaking binary compatibility. * issue 600 ignore Java 8 default methods when generating proxy classes for Java 7. Changes in 2.4.10 * Redesign of the contention code path resulting in doubling contended throughput; now contended pool access retains 98% of the uncontended throughput. * issue 770 add a new property initializationFailTimeout, and deprecate configuration property initializationFailFast. * issue 774 significantly improve spike load handling. * issue 741 cancel HouseKeeper task on pool shutdown. If the ScheduledExecutor being used did not belong to HikariCP, this task would remain scheduled after shutdown, causing a memory leak. Changes in 2.4.9 * issue 719 only reset lastConnectionFailure after a successful dataSource.getConnection() call. * issue 716 do not scan deeper than 10 nested SQLExceptions, it's typically a trap ... a chain that never terminates. * issue 714 fix possible issue with cross-thread visibility. Change pool entry state from AtomicInteger w/lazySet() to a volatile int with use of AtomicIntegerFieldUpdater. Changes in 2.4.8 * Release 2.4.8 marks the start of a Java 7 HikariCP artifact, HikariCP-java7, representing support for Java 7 entering maintenance mode. * Added Connection.commit() call to the fail-fast initialization for databases that automatically start a new Connection in a transaction and throw an exception on close if it is not committed. * feature 694: report if a previously reported leaked connection is returned to the pool * issue 689: log a warning if default transaction isolation level cannot be detected. This can occur with pseudo-database drivers such as the one for JSonar * issue 674: fix regression caused by pull request #450 (overzealous optimisation) Changes in 2.4.7 * Miscellaneous stability improvements. * Removed Oracle SQL state 61000, added specific error code (2399) to evict connections when it is encountered. * issue 664: do not recycle PoolEntry objects that have closed their held connection. * issue 641, 643: reflection used method String.toUpperCase() without a Locale, which causes problems in some locales such as Turkish. * pull 632: added support for Prometheus metrics tracker. * issue 650: detect Amazon Redshift connection refused error codes. Changes in 2.4.6 * Added Oracle SQL error code 61000 (exceeded maximum connect time) to evict connections when it is encountered. * issue 621: fix NPE in shutdown if invoked during initialization. * issue 606, 610: housekeeper thread was running before all class members were initialized, causing an unrecoverable exception and disabling idle connection retirement (maximumLifetime still applied). Changes in 2.4.5 * issue 596: fix bug that occurs when minimumIdle is set to 0, but maximumPoolSize is not explicitly set. * issue 594: fix incompatibility with various libraries caused by storing a non-String object in System properties. * issue 593: improve logging when network timeout is not supported by the driver * issue 591: improve thread-safety of Statement proxies Changes in 2.4.4 * Generate unique sequential pool names, even across container classloaders to avoid JMX name collisions when registering pools. * Improve pool stability when running on computers using power-saving or sleep modes where wake-up previously caused pool to grow to maximum size. * Improve pool stability under severe thread-starvation conditions. Previous code could interpret prolonged starvation (exceeding one minute) as non-contiguous clock advancement, and reacted by soft-evicting connections (unnecessarily). * Added connection timeout rate to Dropwizard metrics (ConnectionTimeoutRate). * issue 563: Do not start the house-keeping thread until after pool initialisation has succeeded. * issue 559: Ensure the pool refill after house-keeping does not enqueue more add connection requests if there are already minimumIdle requests pending. * issue 555: include support for Java 8 interface 'default' methods during proxy generation. * issue 547: decreased allowable minimum connectionTimeout and validationTimeout to 250ms. * issue 495: implemented iterator() method on custom FastList to support Tomcat memory leak detection. Changes in 2.3.13 * issue 512: reduce the number of calls made to Connection.getAutoCommit(). Changes in 2.4.3 * Improve pool shutdown behavior. Stop active connection acquisition once the shutdown sequence has initiated. * Improved detection and reporting of ambiguous pool configuration, when both the connection URL and DataSource class names are specified. Changes in 2.4.2 * Improve accuracy of timeouts for getConnection() calls by accounting for possibly long delay aliveness tests. * Improve adherence to minimumIdle goal by closing idle connections starting from longest idle time to shortest. Additionally, stop when minimumIdle is reached even if connections exceeding idleTimeout remain (but are still within maxLifetime). * Introduce larger variance into maxLifetime to avoid mass connection closing and subsequent new connection creation load on the database. Connections now have a maximum lifetime between 97.5-100% of configured maxLifetime. In the case of the default 30 minute lifetime, this generates actual lifetimes with a maximum deviation of 45 seconds. Currently, no attempt is made to further avoid clustering that may occur due to randomness. * Ongoing com.zaxxer.hikari.metrics refactors. This is not considered public API until such time as we announce it. Caveat lector. * Performance improvements in the getConnection()/close() hot path. * issue 452: fixed race condition when creating an rapidly ramping connections in the pool. * issue 415: removed use of java.beans classes to allow use of HikariCP with the Zulu JRE compact3 profile. * issue 406: execute validation query during connection setup to make sure it is valid SQL. Changes in 2.3.12 * Fixed issue with proxy generation whereby the generated classes contain the major version number for Java 8, which makes them incompatible with the Java 7 runtime. Changes in 2.4.1 * issue 380: housekeeper was not being scheduled in the case of a user specified ScheduledExecutorService instance. * issue 340: rollback change that elides setting the readonly property if the user never explicitly configured it. See discussion in the Github issue tracker. Also fixes binary ABI breakage between 2.3.9 and 2.4.0. * issue 379: stop closing idle connections, to keep minimumIdle connections in pool * issue 375: fixed InvalidPathException in HikariConfig * issue 362: fixed NullPointerException in closing connection (closing statements) * issue 357: allow altering the username & password through JMX at runtime * issue 349: handle integer Transaction isolation level * Throw SQLTransientConnectionException instead of SQLTimeoutException * for validating connection, if network time out is set, do not set query timeout too * ResultSet.getStatement() should return StatementProxy Changes in 2.4.0 * Consolidated distribution into single JVM target (Java 7/8). Java 6 support has entered maintenance mode, bug fixes will continue on the 2.3.x branch. * Removed runtime dependency on Javassist by pre-generating proxy classes at build-time. * Significantly reduced overhead, and increased reliability, of ConcurrentBag. * Reduced garbage generation by 2-3x. * Add connection soft-eviction and replacement if backward system clock motion or significant forward jumps (greater than 1 minute) are detected. * Pool configuration properties and DataSource methods previously marked as @Deprecated have been removed. * Deprecated HikariDataSource.shutdown() in favor of close(). * Improve shutdown performance. * Allow user specified ScheduledThreadPoolExecutor for housekeeping timer. Useful in applications with dozens or hundreds of pools in the same JVM. * Reduce overhead and accuracy of Dropwizard gauges. Changes in 2.3.7 * Try harder at resolving the driver by various means when both driverClassName and jdbcUrl have been specified. * Allow a specifically set DataSource instance to override other settings such as jdbcUrl, dataSourceClassName, or driverClassName. * Fixed issue where, in the case of a driver-based configuration (jdbcUrl), we were not initialising the network timeout Executor. * Fixed race condition uncovered during load-testing in which the connections in the pool can spike to the maximum pool size when many connections reach their maxLifetime at the same time. Changes in 2.3.6 * Allow explicit definition of driverClassName to override DriverManager.getDriver(url) located driver. * Fixed a rare issue where a Connection that is held out of the pool, and never used by the holding thread, upon returning to the pool might be given to another thread without an aliveness test. Changes in 2.3.5 * Fixed regression caused by enhancement #279 that imposed a runtime dependency on Dropwizard metrics. Changes in 2.3.4 * Fixed class cast exception when setting the HealthCheckRegistry via JNDI lookup. * Allow Dropwizard MetricRegistry/HealthCheckRegistry to be set after pool startup -- one time only. * Make logger in BaseHikariPool non-static and use getClass() to log messages as the implementation class rather than as BaseHikariPool. * Removed deprecation from connectionInitSql, it will be allowed. * Made suspect/resume lock non-static (should be be shared across pools). * Improved unwrap() behavior in the Hibernate HikariConnectionProvider. * Improved leak detection log Changes in 2.3.3 * Fixed bad interaction with PostgeSQL JDBC driver whereby a SQLException thrown by PostgreSQL where the getNextException() call returns the original exception and causes an infinite loop in HikariCP (and eventual stack overflow). * Throw a typed Exception rather than a simple RuntimeException when pool initialization fails. * Allow Dropwizard Metrics and HealthChecks to be configured by a JNDI lookup. Changes in 2.3.2 * Add support for Dropwizard HealthChecks through the introduction of two initial health checks: ConnectivityCheck and Connection99Percent. See the Github project wiki for documentation. * Allow a lower maxLifetime setting of 30 seconds (compared to previous 120 second limit) * Improve the message displayed when a connection leak is detected. * Fixed a bug where Connection.setNetworkTimeout() was called on an already closed connection resulting in a warning log from the AS400 JDBC driver. Changes in 2.3.1 * Work around a bug in the MySQL Connector/J implementation of Connection.setNetworkTimeout() that results in non-deterministic asynchronous application of the timeout, resulting in an NPE from the MySQL driver when setNetworkTimeout() is followed immediately by close(). * Introduced a separate validationTimeout property, distict from connectionTimeout, to allow greater control for some deployments that desire a long (or infinite) connectionTimeout but expect the aliveness check to succeed for fail within a different (shorter) amount of time. Changes in 2.3.0 * Support pool suspend/resume to support certain failover scenarios. * Fix theoretical race in JDBC 4.0 detection support. * Improve shutdown() semantics to avoid exceptions as connections are forcefully aborted. * Unregister Codahale metrics at shutdown, if metrics are enabled. * Major internal project layout restructuring to allow shared use of common code between the Java 6/7 and Java 8 versions. * Fixed bug where two pools in the same VM (and ClassLoading domain), using drivers with differing JDBC support levels, would fail unless both pools were using connectionTestQuery. * Improved timeliness of maxLifetime evictions, while increasing performance of getConnection() slightly as a side-effect. * Fixed bug in HikariDataSource unwrap() semantics. * Allow a lower leakDetectionThreshold of 2 seconds. * Fixed bug when using the HikariJNDIFactory that required the presence of Codahale metrics. * Support initializationFailFast even when minimumIdle = 0 * Log internal pool inconsistencies rather than throwing exceptions that might disrupt internal executors. * Guard against poor or unreliable System.nanoTime() implementations. Changes in 2.2.5 * Fixes for Java 6 compatibility. * Implement full transaction state tracking. This allows HikariCP to bypass the automatic rollback when connections are returned to the pool if the transaction state is "clean". * Rename MBean closeIdleConnections() to softEvictConnections() and implement "evict on return" semantics. * Fixed bug in code that sets HikariConfig values from a Properties instance that prevented defaults from being read properly. * Fixed an obscure bug in connection creation with a driver that throws an exception when setTransactionIsolation() is called with the value returned by getTransactionIsolation(). We now bypass setTransactionIsolation() if the user has not configured an isolation level (using the default). * Fix a bug where DataSource.loginTimeout() was always being set to 1 second. * Fix bug where some drivers return 0 from Connection.getNetworkTimeout(), and yet throw SQLFeatureNotSupportedException when setNetworkTimeout() is called. This broke they way that HikariCP had implemented JDBC 4.1 support detection. Changes in 2.2.4 * Generate proxy classes into the same protection domain as the HikariCP loaded classes. This solves issues with signed jars. * Improve accuracy of pool statistics available to JMX and logged at debug level (at a slight performance cost). * Fixed issue where after a database down condition, and when minimumIdle is set to 0, when the database connectivity is restored the connections could ramp up to the maximum pool size. Eventually, idleTimeout and maxLifetime would restore normal pool conditions, but it was still undesirable behavior. * Improved connection timeout handling by using Connection.setNetworkTimeout() if available (JDBC 4.1). * driverClassName is no longer a required property when jdbcUrl is specified. Omitting this property only works for compliant drivers. * Add auto-detection of support for Statement.setQueryTimeout() used in the alive check. Fixes failures with test queries on the PostgreSQL driver when not using JDBC4 isValid() alive checks. * The pool now defaults to fail-fast initialization. If you need to start your application without/before the database, you will need to explicitly set initializationFailFast to false. * Dropwizard/Codahale metrics are now supported via the setMetricRegistry() method in HikariConfig and in HikariDataSource. * Fixed issue with pool initialization of MySQL after default value of initializationFailFast property was changed to false. * Further shadow runtime dependency on Codahale metrics from reflection performed by Spring and other IoC containers. * Fix issue where network timeout was not properly restored to its default value after modifying it for the duration of the addConnection() method. Changes in 2.1.0 * Significant internal refactor supporting creation of new proxy instances (throwaway) around Connections for each call to getConnection(). This can avoid issues where a thread continues to try to use a connection after it is closed [returned to the pool]. * Allow HikariConfig(String propertyFileName) to load properties file from classloader as a stream, with fall-back to the file-system. * Allow loading of properties file specified by -Dhikaricp.configurationFile system property when using the default HikariConfig() or HikariDataSource() constructors. * Fixed accounting issue with totalConnections when aborting connections during shutdown, causing a warning message to be logged. * Fixed regression in Java 8 codeline that would prevent minimumIdle from being set before maxPoolSize. * Fixed regression with Tomcat carping about ThreadLocal variables held after web application restart * Change to make HikariConfig.getTransactionIsolation()/setTransactionIsolation() follow proper bean semantics. * Fixed issue where connections created in the pool would skip the alive check the first time they were used. Changes in 2.0.1 * Split project into Java 6/7 and Java 8 components. * Fixed issue in JNDI object factory which would not allow JNDI-defined DataSource properties to pass-thru to the pool. * Fixed issue where under certain conditions getConnection() could timeout prematurely. * Fixed issue where user-defined pool name would be overridden by the automatically generated name. * Fixed NPE when one of either username and password is defined, and the other is null. * Fixed issue tracking the statements when there are mixed statement types (Statement, PreparedStatement, etc.) open on the connection and the number of unclosed statements exceeds 32. * Fixed issue where housekeeping threads would add idle connections even when minimumIdle was 0. * Fixed issue where Wrapper.isWrapperFor() and Wrapper.unwrap() calls did not recurse as per specification. * HikariDataSource now implements the Closable interface. * Integrated change to allow specifying a ThreadGroup for thread creation is certain restricted environments. Changes in 1.4.0 *) Fix bug that did not allow minIdle property to be set. Changes in 1.3.9 *) Added pool name to housekeeping thread name to make thread dumps more meaningful in containers with multiple pools. *) Improved shutdown semantics; make a concerted effort to close idle connections and abort or close active connections. *) Performance enhancements. Changes in 1.3.8 *) Fixed incorrect logic when using JDBC4 isValid() test for alive status of connection. Changes in 1.3.7 *) Added JNDI object factory (com.zaxxer.hikari.HikariJNDIFactory) for Tomcat and other containers that prefer JNDI-registered DataSource factories. *) Fix NPE that can occur when connections cannot be created and callers to getConnection() timeout. *) Various bug fixes and minor enhancements. Changes in 1.3.6 *) Include connection failure cause in calls to getConnection() that timeout (due to connection failure). Removed chatty logging. *) Java8 Compatibility fixes. *) Include pool name in logging messages. Thanks for the contribution @jaredstehler. Changes in 1.3.5 *) Fixed a regression in the Javassist code generation. *) Various bug fixes and minor enhancements. Changes in 1.3.4 *) Added new property isolateInternalQueries used to control whether internal pool queries such as connection alive tests are isolated in their own transaction. *) Added properties for DriverManager (driverClassName) and JDBC URL-based (jdbcUrl) configuration. 1999 called and wants its JDBC driver back. *) Added new username and password properties to allow default authentication for connections. *) Added support for the getConnection(username, password) method signature to HikariDataSource. *) Added new property readOnly to control the default read-only status of connections in the pool. *) Deprecated acquireIncrement property. *) Deprecated acquireRetries property. *) Deprecated acquireRetryDelay property. *) Deprecated minimumPoolSize property. *) Added new property minimumIdle used to control the minimum number of idle connections the pool should try to maintain on a running basis. *) Added evictConnection(Connection) method to HikariDataSource to allow special cases where users wish to forcibly eject a connection from the pool. To use used cautiously, read the JavaDoc before using. *) Various bug fixes and minor enhancements. Changes in 1.3.3 *) Removed shared state contention that was causing excessive CPU cache-line flushing. Nearly 4x improvement in Connection acquisition/release performance. *) Fixed issue with Tomcat carping about ThreadLocal variables held after web application restart. *) Fixed issue where the maximum configured connections could be overrun during large burst requests for connections. Changes in 1.3.2 *) Java 6 compatibility. *) HikariDataSource now extends HikariConfig, so pool properties can be set directly on a HikariDataSource without need to create a HikariConfig. The cost of doing so is a small runtime cost due to the fact that an "is initialized" check must be performed on every invocation of getConnection() due to lazy initialization of the pool. *) Added Sybase-specific disconnect error codes to SQLException snooping. *) Added HikariConfig.setCatalog() method to set DataSource catalog. *) Add DataSource.close() method that is synonymous with shutdown(). *) More performance improvements (never ending). *) Moved benchmarks to https://github.com/brettwooldridge/HikariCP-benchmark Changes in 1.3.0 *) Pool is now backed by a custom lock-less ConcurrentBag that provides superior performance to LinkedBlockingQueue and LinkedTransferQueue for usage patterns of connection pools. *) Fixed bugs reported against the 1.2.9 release. *) Added more detailed logging for broken connections and failures during new connection creation. Changes in 1.2.9 *) Added a fail-fast option for pool initialization. If enabled, a RuntimeException will be thrown if there are errors during pool initialization. *) Made the registration of the HikariCP MBeans optional. They now default to not being registered. Registering them causes a minor performance hit due to additional pool data collection in HikariDataSource.getConnection(). *) Added the SQLException message to the log entry when an exception occurs during physical connection acquisition. *) Implemented an orderly shutdown of the pool via the shutdown() method on HikariDataSource. *) Listened to "Adele - Live At The Royal Albert Hall" on endless loop. Changes in 1.2.8 *) Fixed a critical bug introduced in 1.2.7 occurring when the number of concurrently open statements exceeds sixteen. Changes in 1.2.7 *) Finally achieved performance parity between the generated delegates and the former method of instrumenting driver classes directly. *) Improved generated delegate code. Removed unnecessary casts, moved to a static proxy factory rather than a singleton (performance win). *) Improved performance of FastStatementList (primary source of speed-up to reach parity with former instrumentation code). *) Removed aliveness check on connection creation. *) Track connection isolation level and only reset if the state has become "dirty". Avoids unnecessary round trip to the DB during the aliveness check. *) Added interface IConnectionCustomizer and related HikariConfig property 'connectionCustomizerClassName' to allow users to specify a connection customization implementation. Changes in 1.2.6 *) Fixed regression that caused IndexOutOfBounds when multiple unclosed Statements existed at the time of Connection.close(). *) Fixed incorrect pom.xml dependency on Hibernate. Changes in 1.2.5 *) Instrumentation mode (agent) removed due to narrowing gap between delegation mode and instrumentation (and to simplify the code base). *) Added setDataSource() to HikariConfig to allow a DataSource instance to be explicitly wrapped by the pool. Only available when creating HikariConfig programmatically or constructing HikariConfig from a java.util.Properties instance. *) Fixed Hibernate threading issue (certain usage patterns) introduced in 1.2.2. *) Fixed issue observed with PostgreSQL whereby the query that tests the connection for "aliveness" also starts a transaction (when auto-commit is false), thereby causing a later failure when we tried to set the transaction isolation level. *) Fixed issue where idleTimeout could not be set to 0, thereby disabling it. Incorrect value validation caused 0 to be rejected as a valid value. Changes in 1.2.4 *) Fix another Hibernate-related issue whereby an NPE is encountered when a thread that was not the thread that obtained a Connection tries to interact with that Connection. Changes in 1.2.3 *) Fix internal (but suppressed) exception during rollback of connections returned to the pool with auto-commit turned off. *) Fix a reflection issue that causes Hibernate failures due to the CallableStatement interface being incorrectly injected into statement proxies that are PreparedStatement or Statement instances. Changes in 1.2.2 *) Perform a rollback() on connections returned to the pool with auto commit disabled. *) Add a constructor for HikariConfig that accepts a Properties object. *) Speed improvements for delegate mode. *) Fix a bug where connection timeouts could not be disabled. *) Permit setting the DataSource logWriter either on the HikariDataSource or via addDataSourceProperty() on the HikariConfig. *) Add transactionIsolation property to allow setting the default transaction isolation level for connections. Changes in 1.2.1 *) Clear SQL warnings before returning a connection to the user. *) Added asynchronous connection backfill strategy that triggers when the pool becomes empty as a result of dispatching a connection. *) Changed default acquireIncrement to 1, set minimum timeout of 100ms for acquiring a connection. Changes in 1.1.9 *) Added connectionInitSql property to allow setting connection properties when a new connection is created. *) Added setDataSourceProperties() setter to HikariConfig to allow easier configuration though Spring. HikariCP-HikariCP-2.7.1/LICENSE 0000664 0000000 0000000 00000024041 13154316420 0015610 0 ustar 00root root 0000000 0000000 Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: You must give any other recipients of the Work or Derivative Works a copy of this License; and You must cause any modified files to carry prominent notices stating that You changed the files; and You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. HikariCP-HikariCP-2.7.1/README.md 0000664 0000000 0000000 00000072460 13154316420 0016072 0 ustar 00root root 0000000 0000000