You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "Yida Wu (Jira)" <ji...@apache.org> on 2022/03/10 19:24:00 UTC

[jira] [Created] (IMPALA-11176) Memory leak in ClientCacheHelper

Yida Wu created IMPALA-11176:
--------------------------------

             Summary: Memory leak in ClientCacheHelper
                 Key: IMPALA-11176
                 URL: https://issues.apache.org/jira/browse/IMPALA-11176
             Project: IMPALA
          Issue Type: Bug
          Components: Backend
    Affects Versions: Impala 3.4.0, Impala 4.0.0
            Reporter: Yida Wu
             Fix For: Impala 4.1.0


ClientCacheHelper::CreateClient uses a function pointer "factory_method" to create a new ThriftClientImpl object and store it in a share pointer of type ThriftClientImpl.

However, in the implementation of the function pointer, which uses ClientCache::MakeClient, it creates a derived object of ThriftClientImpl and return the pointer as the base object pointer ThriftClientImpl*. When the ClientCacheHelper::CreateClient uses the returned pointer to create a base shared pointer, it can't recognize that the pointer is from a derived object, therefore something goes wrong that the shared pointer couldn't release all the memory occupied by the derived object.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org