Henry Robinson has posted comments on this change.

Change subject: Move Impala HTTP handlers to a separate class
......................................................................


Patch Set 1:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/3370/1/be/src/service/impala-server.cc
File be/src/service/impala-server.cc:

PS1, Line 316: http_handler_.reset(new ImpalaHttpHandler(this));
> But the lifetime of 'this' is already the lifetime of this scoped object (i
I see what you mean. The other bit of state that the callbacks have, 
implicitly, is a pointer to their containing object (i.e. the 
ImpalaHttpHandler). They don't dereference that right now, but there's nothing 
to stop one of them doing so in the future, and it would be a bit surprising to 
find a crash because there are methods being called on an object which has 
since been destroyed. I thought about doing this, but I think it's better not 
to surprise people with unexpected lifetimes, even if it would be safe here.


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I8453b3367653914163ca6acae48e7605f73cc675
Gerrit-PatchSet: 1
Gerrit-Project: Impala
Gerrit-Branch: cdh5-trunk
Gerrit-Owner: Henry Robinson <[email protected]>
Gerrit-Reviewer: Henry Robinson <[email protected]>
Gerrit-Reviewer: Matthew Jacobs <[email protected]>
Gerrit-HasComments: Yes

Reply via email to