[ 
https://issues.apache.org/jira/browse/NIFI-1436?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15115506#comment-15115506
 ] 

ASF GitHub Bot commented on NIFI-1436:
--------------------------------------

Github user bbende commented on the pull request:

    https://github.com/apache/nifi/pull/189#issuecomment-174575236
  
    So I originally thought about removing the loop in close() which would 
avoid the locking as you suggested, but I wasn't 100% sure if selector.close() 
also closed the channels. The JavaDoc says:
    
         * <p> Any uncancelled keys still associated with this selector are
         * invalidated, their channels are deregistered, and any other resources
         * associated with this selector are released.
    
    As long as "any other resources associated with this selector are released" 
means "all the channels are closed" then we are good.


> Intermittent Failure of TestListenSyslog
> ----------------------------------------
>
>                 Key: NIFI-1436
>                 URL: https://issues.apache.org/jira/browse/NIFI-1436
>             Project: Apache NiFi
>          Issue Type: Bug
>    Affects Versions: 0.5.0
>            Reporter: Bryan Bende
>            Assignee: Bryan Bende
>            Priority: Minor
>             Fix For: 0.5.0
>
>
> Tests run: 8, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 2.165 sec <<< 
> FAILURE! - in org.apache.nifi.processors.standard.TestListenSyslog
> testTCPSingleConnection(org.apache.nifi.processors.standard.TestListenSyslog) 
>  Time elapsed: 0.716 sec  <<< ERROR!
> java.util.ConcurrentModificationException: null
>       at java.util.HashMap$HashIterator.nextNode(HashMap.java:1429)
>       at java.util.HashMap$KeyIterator.next(HashMap.java:1453)
>       at 
> java.util.Collections$UnmodifiableCollection$1.next(Collections.java:1042)
>       at 
> org.apache.nifi.processor.util.listen.dispatcher.SocketChannelDispatcher.close(SocketChannelDispatcher.java:219)
>       at 
> org.apache.nifi.processors.standard.ListenSyslog.onUnscheduled(ListenSyslog.java:313)
>       at 
> org.apache.nifi.processors.standard.TestListenSyslog.testTCPSingleConnection(TestListenSyslog.java:166)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to