Permalink
Browse files

remove packet cache scanning functions from rec_control get-all - too…

… much overhead!
  • Loading branch information...
1 parent 012de54 commit 8e42d27d936acd9fdd37327e96fda0b2ae916a42 @ahupowerdns ahupowerdns committed Mar 18, 2014
Showing with 4 additions and 1 deletion.
  1. +3 −1 pdns/rec_channel_rec.cc
  2. +1 −0 pdns/recursor_cache.cc
@@ -69,7 +69,9 @@ map<string,string> getAllStatsMap()
BOOST_FOREACH(the64bits, d_get64bitpointers) {
ret.insert(make_pair(the64bits.first, lexical_cast<string>(*the64bits.second)));
}
- BOOST_FOREACH(the32bitmembers, d_get32bitmembers) {
+ BOOST_FOREACH(the32bitmembers, d_get32bitmembers) {
+ if(the32bitmembers.first == "cache-bytes" || the32bitmembers.first=="packetcache-bytes")
+ continue; // too slow for 'get-all'
ret.insert(make_pair(the32bitmembers.first, lexical_cast<string>(the32bitmembers.second())));
}
return ret;
@@ -91,6 +91,7 @@ unsigned int MemRecursorCache::size()
return (unsigned int)d_cache.size();
}
+// this function is too slow to poll!
unsigned int MemRecursorCache::bytes()
{
unsigned int ret=0;

0 comments on commit 8e42d27

Please sign in to comment.