Tim Armstrong has posted comments on this change.

Change subject: Fix parquet table writer dictionary leak
......................................................................


Patch Set 1:

(2 comments)

http://gerrit.cloudera.org:8080/#/c/6181/2//COMMIT_MSG
Commit Message:

Line 7: Fix parquet table writer dictionary leak
JIRA?


http://gerrit.cloudera.org:8080/#/c/6181/1/be/src/exec/hdfs-table-sink.cc
File be/src/exec/hdfs-table-sink.cc:

Line 579:     OutputPartition* partition = new OutputPartition();
> The issue is that the OutputPartition is passed down to the table writers, 
The OutputPartition owns the HdfsTableWriter via a scoped_ptr so we can safely 
use a raw OutputPartition* pointer in HdfsTableWriter. This pattern of an 
owning unique_ptr/scoped_ptr in one direction and a raw pointer for the inverse 
shows up elsewhere in the code (e.g. for "parent" pointers). 

I'd probably add a comment on HdfsTableWriter.output_ to note that ownership 
relationship but I think that would be clear and safe.


-- 
To view, visit http://gerrit.cloudera.org:8080/6181
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I06e354086ad24071d4fbf823f25f5df23933688f
Gerrit-PatchSet: 1
Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-Owner: Joe McDonnell <[email protected]>
Gerrit-Reviewer: Joe McDonnell <[email protected]>
Gerrit-Reviewer: Lars Volker <[email protected]>
Gerrit-Reviewer: Tim Armstrong <[email protected]>
Gerrit-HasComments: Yes

Reply via email to