GitHub user olegz opened a pull request:
https://github.com/apache/nifi/pull/117
NIFI-1061 fixed deadlock caused by DBCPConnectionPool.onConfigured()
Current implementation of DBCPConnectionPool was attempting to test if
connection could be obtained via dataSource.getConnection().
Such call is naturally a blocking call and the duration of the block is
dependent on driver implementation. Some drivers (e.g., Phoenix -
https://phoenix.apache.org/installation.html)
attempts numerous retries before failing creating a deadlock when attempt
was made to disable DBCPConnectionPool which was still being enabled.
This fix removes the connection test from DBCPConnectionPool.onConfigured()
operation returning successfully upon creation of DataSource.
For more details see comments in
https://issues.apache.org/jira/browse/NIFI-1061
The fix also cleaned up the code in
StandardProcessScheduler.getScheduleState for better readability.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/olegz/nifi NIFI-1061
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/nifi/pull/117.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #117
----
commit 370950b0193c0a64cb023b2e64d9ea40c9ad97f4
Author: Oleg Zhurakousky <[email protected]>
Date: 2015-11-09T19:47:50Z
NIFI-1061 fixed deadlock caused by DBCPConnectionPool.onConfigured()
Current implementation of DBCPConnectionPool was attempting to test if
connection could be obtained via dataSource.getConnection().
Such call is naturally a blocking call and the duration of the block is
dependent on driver implementation. Some drivers (e.g., Phoenix -
https://phoenix.apache.org/installation.html)
attempts numerous retries before failing creating a deadlock when attempt
was made to disable DBCPConnectionPool which was still being enabled.
This fix removes the connection test from DBCPConnectionPool.onConfigured()
operation returning successfully upon creation of DataSource.
For more details see comments in
https://issues.apache.org/jira/browse/NIFI-1061
The fix also cleaned up the code in
StandardProcessScheduler.getScheduleState for better readability.
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---