You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-dev@hadoop.apache.org by "James Clampffer (JIRA)" <ji...@apache.org> on 2018/07/18 17:09:00 UTC

[jira] [Created] (HDFS-13745) libhdfs++: Fix race in FileSystem destructor

James Clampffer created HDFS-13745:
--------------------------------------

             Summary: libhdfs++: Fix race in FileSystem destructor
                 Key: HDFS-13745
                 URL: https://issues.apache.org/jira/browse/HDFS-13745
             Project: Hadoop HDFS
          Issue Type: Task
          Components: native
            Reporter: James Clampffer
            Assignee: James Clampffer


Whatever happens to have the last shared_ptr to the IoService will run ~IoService when the shared_ptr goes out of scope.  IoService's destructor is responsible for joining all worker threads in the pool.  Most callbacks now own weak_ptr<IoService> that can be promoted to a shared_ptr in order to post new async tasks.  If a callback object is the last thing holding the IoService shared_ptr it's going to try to join the thread pool inside of one of the thread pool's threads.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: hdfs-dev-unsubscribe@hadoop.apache.org
For additional commands, e-mail: hdfs-dev-help@hadoop.apache.org