From: Pieter Lexis Date: Fri, 13 Apr 2018 12:17:45 +0000 (+0200) Subject: ixfrdist: fix review comments by @rgacogne X-Git-Tag: dnsdist-1.3.1~148^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7d6ccb441767eda8a418f47d0505eaa0ba8eaf3e;p=pdns ixfrdist: fix review comments by @rgacogne --- diff --git a/docs/manpages/ixfrdist.1.rst b/docs/manpages/ixfrdist.1.rst index f01233d79..446d0bc85 100644 --- a/docs/manpages/ixfrdist.1.rst +++ b/docs/manpages/ixfrdist.1.rst @@ -39,8 +39,8 @@ Options --uid Drop effective user-id to *UID* after binding the listen sockets. --gid Drop effective group-id to *GID* after binding the listen sockets. --axfr-timeout Stop an inbound AXFR when it is not completed in *NUM* seconds. Defaults to 10 seconds. ---tcp-out-threads Amount of worker threads to handle TCP traffic. - This limits the number of concurrent AXFR/IXFR, the default is 10. +--tcp-in-threads Amount of worker threads to handle TCP traffic from clients. + This limits the number of concurrent AXFR/IXFR sessions, the default is 10. See also -------- diff --git a/pdns/ixfrdist.cc b/pdns/ixfrdist.cc index 152170973..c93f3d0d9 100644 --- a/pdns/ixfrdist.cc +++ b/pdns/ixfrdist.cc @@ -580,6 +580,7 @@ void handleTCPRequest(int fd, boost::any&) { if (saddr == ComboAddress("0.0.0.0", 0)) { g_log<> packets; if (mdp.d_qtype == QType::SOA) { - vector packet; + vector packet; bool ret = makeSOAPacket(mdp, packet); if (!ret) { close(cfd); @@ -732,7 +733,7 @@ int main(int argc, char** argv) { ("work-dir", po::value()->default_value("."), "Directory for storing AXFR and IXFR data") ("keep", po::value()->default_value(KEEP_DEFAULT), "Number of old zone versions to retain") ("axfr-timeout", po::value()->default_value(AXFRTIMEOUT_DEFAULT), "Timeout in seconds for an inbound AXFR to complete") - ("tcp-out-threads", po::value()->default_value(10), "Number of maximum simultaneous outbound TCP connections") + ("tcp-in-threads", po::value()->default_value(10), "Number of maximum simultaneous inbound TCP connections. Limits simultaneous AXFR/IXFR transactions") ; po::options_description alloptions; po::options_description hidden("hidden options"); @@ -933,7 +934,7 @@ int main(int argc, char** argv) { std::thread ut(updateThread); vector tcpHandlers; - for (int i = 0; i < g_vm["tcp-out-threads"].as(); ++i) { + for (int i = 0; i < g_vm["tcp-in-threads"].as(); ++i) { tcpHandlers.push_back(std::thread(tcpWorker, i)); }