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

ASF GitHub Bot commented on GEODE-2324:
---------------------------------------

GitHub user galen-pivotal opened a pull request:

    https://github.com/apache/geode/pull/349

    [GEODE-2324] fixes to AcceptorImpl.close()

    If the thread is interrupted during closing, just continue to shut down
    what we can.
    
    * Catch InterruptedException so cleanup continues.
    * Remove top-level exception handler to avoid masking exceptions that
    * could short-circuit shutdown.
    * Fix a synchronization bug that could cause AcceptorImpl to try to shut
      down twice.
    * Fix what looks like a bug where if closing the socket throws an
      IOException, we fail to shut anything else down, though we still have
      ourselves marked as shut down.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/galen-pivotal/incubator-geode 
feature/GEODE-2324

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/geode/pull/349.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 #349
    
----
commit 26f70874102bad830f81b36d496c6469103f2e74
Author: Galen O'Sullivan <gosulli...@pivotal.io>
Date:   2017-01-18T23:00:47Z

    [GEODE-2324] fixes to AcceptorImpl.close()
    
    If the thread is interrupted during closing, just continue to shut down
    what we can.
    
    * Catch InterruptedException so cleanup continues.
    * Remove top-level exception handler to avoid masking exceptions that
    * could short-circuit shutdown.
    * Fix a synchronization bug that could cause AcceptorImpl to try to shut
      down twice.
    * Fix what looks like a bug where if closing the socket throws an
      IOException, we fail to shut anything else down, though we still have
      ourselves marked as shut down.

----


> If AcceptorImpl is interrupted during shutdown, it does not clean up properly.
> ------------------------------------------------------------------------------
>
>                 Key: GEODE-2324
>                 URL: https://issues.apache.org/jira/browse/GEODE-2324
>             Project: Geode
>          Issue Type: Bug
>          Components: client/server
>    Affects Versions: 1.0.0-incubating
>            Reporter: Galen O'Sullivan
>            Assignee: Galen O'Sullivan
>
> In {{AcceptorImpl.close()}}, the call to 
> {{this.pool.awaitTermination(PoolImpl.SHUTDOWN_TIMEOUT, 
> TimeUnit.MILLISECONDS))}} can throw an {{InterruptedException}}, in which 
> case neither {pool} nor {{hsPool}} or anything else that comes after is 
> properly closed and an error message is logged.
> I believe that the thread will be interrupted if a shutdown command is issued 
> (for example, through gfsh), though I haven't created a reproduction yet.



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

Reply via email to