You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafodion.apache.org by "Arvind Narain (JIRA)" <ji...@apache.org> on 2016/10/25 19:17:59 UTC

[jira] [Created] (TRAFODION-2309) Memory leak observed in Repository context

Arvind Narain created TRAFODION-2309:
----------------------------------------

             Summary: Memory leak observed in Repository context
                 Key: TRAFODION-2309
                 URL: https://issues.apache.org/jira/browse/TRAFODION-2309
             Project: Apache Trafodion
          Issue Type: Bug
          Components: connectivity-mxosrvr
            Reporter: Arvind Narain
            Assignee: Arvind Narain


Currently repository context in mxosrvr uses the same allocated psrvrstmt to execute different statements - upsert into the metric_session_table, insert and update the records for metric_query_aggr_table and metric_query_table. This could lead to memory leaks over time. 

Ideally we should be preparing each of these statements and repeatedly executing rather than execdirect. 

For the current implementation as long as master executor executes deallocate statement, this memory leak can be avoided or reduced. Rather than give back the statement and allocate it again we could reallocate the statement handle. This would avoid any thread conflicts with  psrvrstmt handlers from default and repository context.

Repository context also generates "missing stats" warnings for tables in "_REPOS_" schema.

Also for queries that get reprepared a small memory leak was observed when google profiler was used.

So changes planned:
1. Use REALLOCSQLMXHDLS() after each execute.
2. Avoid missing stats message
3. Handle delete of tmpSqlString in reprepare.




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