![]() |
Kea 2.0.0
|
Public Member Functions | |
DNSClientImpl (D2UpdateMessagePtr &response_placeholder, DNSClient::Callback *callback, const DNSClient::Protocol proto) | |
virtual | ~DNSClientImpl () |
void | doUpdate (asiolink::IOService &io_service, const asiolink::IOAddress &ns_addr, const uint16_t ns_port, D2UpdateMessage &update, const unsigned int wait, const D2TsigKeyPtr &tsig_key) |
DNSClient::Status | getStatus (const asiodns::IOFetch::Result) |
void | incrStats (const std::string &stat, bool update_key=true) |
virtual void | operator() (asiodns::IOFetch::Result result) |
Callback method. More... | |
![]() | |
Callback () | |
Default Constructor. More... | |
virtual | ~Callback () |
Virtual Destructor. More... | |
Public Attributes | |
DNSClient::Callback * | callback_ |
util::OutputBufferPtr | in_buf_ |
DNSClient::Protocol | proto_ |
D2UpdateMessagePtr & | response_ |
dns::TSIGContextPtr | tsig_context_ |
std::string | tsig_key_name_ |
Definition at line 38 of file dns_client.cc.
isc::d2::DNSClientImpl::DNSClientImpl | ( | D2UpdateMessagePtr & | response_placeholder, |
DNSClient::Callback * | callback, | ||
const DNSClient::Protocol | proto | ||
) |
Definition at line 90 of file dns_client.cc.
|
virtual |
Definition at line 127 of file dns_client.cc.
void isc::d2::DNSClientImpl::doUpdate | ( | asiolink::IOService & | io_service, |
const asiolink::IOAddress & | ns_addr, | ||
const uint16_t | ns_port, | ||
D2UpdateMessage & | update, | ||
const unsigned int | wait, | ||
const D2TsigKeyPtr & | tsig_key | ||
) |
Definition at line 191 of file dns_client.cc.
References isc::d2::DNSClient::getMaxTimeout(), in_buf_, incrStats(), isc_throw, isc::asiolink::IOService::post(), isc::dns::AbstractMessageRenderer::setBuffer(), isc::d2::D2UpdateMessage::toWire(), tsig_context_, tsig_key_name_, and isc::asiodns::IOFetch::UDP.
Referenced by isc::d2::DNSClient::doUpdate().
DNSClient::Status isc::d2::DNSClientImpl::getStatus | ( | const asiodns::IOFetch::Result | result | ) |
Definition at line 173 of file dns_client.cc.
References isc::d2::DNSClient::IO_STOPPED, isc::d2::DNSClient::OTHER, isc::asiodns::IOFetch::STOPPED, isc::d2::DNSClient::SUCCESS, isc::asiodns::IOFetch::SUCCESS, isc::asiodns::IOFetch::TIME_OUT, and isc::d2::DNSClient::TIMEOUT.
Referenced by operator()().
void isc::d2::DNSClientImpl::incrStats | ( | const std::string & | stat, |
bool | update_key = true |
||
) |
Definition at line 256 of file dns_client.cc.
References isc::stats::StatsMgr::addValue(), isc::stats::StatsMgr::generateName(), isc::stats::StatsMgr::instance(), and tsig_key_name_.
Referenced by doUpdate(), and operator()().
|
virtual |
Callback method.
This is the method called when the fetch completes.
result | Result of the fetch |
Implements isc::asiodns::IOFetch::Callback.
Definition at line 131 of file dns_client.cc.
References callback_, isc::d2::d2_to_dns_logger, isc::log::DBGLVL_TRACE_DETAIL, isc::d2::DHCP_DDNS_INVALID_RESPONSE, getStatus(), in_buf_, isc::d2::D2UpdateMessage::INBOUND, incrStats(), isc::d2::DNSClient::INVALID_RESPONSE, LOG_DEBUG, response_, isc::d2::DNSClient::SUCCESS, isc::d2::DNSClient::TIMEOUT, tsig_context_, and isc::Exception::what().
DNSClient::Callback* isc::d2::DNSClientImpl::callback_ |
Definition at line 55 of file dns_client.cc.
Referenced by operator()().
util::OutputBufferPtr isc::d2::DNSClientImpl::in_buf_ |
Definition at line 41 of file dns_client.cc.
Referenced by doUpdate(), and operator()().
DNSClient::Protocol isc::d2::DNSClientImpl::proto_ |
Definition at line 57 of file dns_client.cc.
D2UpdateMessagePtr& isc::d2::DNSClientImpl::response_ |
Definition at line 52 of file dns_client.cc.
Referenced by operator()().
dns::TSIGContextPtr isc::d2::DNSClientImpl::tsig_context_ |
Definition at line 59 of file dns_client.cc.
Referenced by doUpdate(), and operator()().
std::string isc::d2::DNSClientImpl::tsig_key_name_ |
Definition at line 61 of file dns_client.cc.
Referenced by doUpdate(), and incrStats().