BIND 10 #1601: pass reference instead of shared pointer within AuthSrv
BIND 10 Development
do-not-reply at isc.org
Tue Mar 6 18:53:14 UTC 2012
#1601: pass reference instead of shared pointer within AuthSrv
-------------------------------------+-------------------------------------
Reporter: | Owner: jinmei
jinmei | Status: reviewing
Type: task | Milestone:
Priority: | Sprint-20120320
medium | Resolution:
Component: | Sensitive: 0
b10-auth | Sub-Project: DNS
Keywords: | Estimated Difficulty: 3
Defect Severity: N/A | Total Hours: 0
Feature Depending on Ticket: auth |
performance |
Add Hours to Ticket: 0 |
Internal?: 0 |
-------------------------------------+-------------------------------------
Comment (by jinmei):
Replying to [comment:7 vorner]:
> It should be ready for review. I first tried to change the interface of
the callbacks, but I got completely lost in the resolver code (which
needed to be changed as well as the result). So this changes it inside the
authoritative processing only.
>
> I don't think this needs a changelog entry, as this does not change any
public API. The speedup won't be too large either, I think (but I didn't
test it).
The changes basically look okay. I agree that we should keep the
callback interface intact at least for now. I also agree we don't
need a changelog for it.
I have two minor comments:
- Not related to the ticket, but I noticed we can make one additional
cleanup:
{{{#!diff
MessageLookup(AuthSrv* srv) : server_(srv) {}
virtual void operator()(const IOMessage& io_message,
MessagePtr message,
- MessagePtr answer_message,
+ MessagePtr, // unused in this implementation
OutputBufferPtr buffer,
DNSServer* server) const
{
- (void) answer_message;
server_->processMessage(io_message, *message, *buffer, server);
}
private:
}}}
- query_bench can be more sharedptr free. I'm attaching a suggested
patch.
I'd leave the decision on these to you (although I believe the first
cleanup is good to make even if not in this ticket). After that
please feel free to merge.
--
Ticket URL: <http://bind10.isc.org/ticket/1601#comment:10>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development
More information about the bind10-tickets
mailing list