[
https://issues.apache.org/jira/browse/QPID-7001?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15142760#comment-15142760
]
Keith Wall commented on QPID-7001:
----------------------------------
It seems like the only explanation for this NPE is a race within
{{java.nio.channels.spi.AbstractSelectableChannel#register()}} itself.
#register() registers the interest and then updates the attachment, seemingly
with no lock that makes the operation atomic. As Qpid's accept code
-{{SelectionTask#processSelectionKeys()}} - deregisters interest (which clear
the current attachment), then processes the accept backlog, then reregisters
the socket channel, it seems there is the possibility of a race. A
{{#select}} occurring at the precise moment between register's calls to
interestOps() and attach() could lead to the NPE if there was already a socket
backlog ready to accept. r1729828 should eliminate the possibility.
> [Java Broker] NullPointerException can be thrown from Port IO Thread
> --------------------------------------------------------------------
>
> Key: QPID-7001
> URL: https://issues.apache.org/jira/browse/QPID-7001
> Project: Qpid
> Issue Type: Bug
> Components: Java Broker
> Affects Versions: qpid-java-6.0, qpid-java-6.1
> Reporter: Alex Rudyy
> Priority: Critical
> Attachments: 0001-WIP-Add-system-test.patch, test.log.tar.gz
>
>
> I run into the following issue in my tests:
> {noformat}
> ########################################################################
> #
> # Unhandled Exception java.lang.NullPointerException in Thread
> IO-pool-Port-amqp-1
> #
> # Exiting
> #
> ########################################################################
> java.lang.NullPointerException
> at
> org.apache.qpid.server.transport.SelectorThread$SelectionTask$1.run(SelectorThread.java:190)
> at
> org.apache.qpid.server.transport.SelectorThread.run(SelectorThread.java:457)
> at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
> {noformat}
> I've seen this exception occurring from time to time in the BDB HA test
> MultiNodeTest#testInFlightTransactionsWhilstMajorityIsLost
> It seems that NPE occurs on heavy loads when multiple connections are trying
> to restore connectivity because of failover. The issue might affect users
> severely production deployments of the 6.x brokers, as NPE kills the broker
> and manual intervention could be required to start-up the broker
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]