Changeset 1278
- Timestamp:
- 11/15/08 21:56:36 (22 months ago)
- Location:
- trunk/pdns/pdns
- Files:
-
- 2 modified
-
communicator.cc (modified) (3 diffs)
-
resolver.cc (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/pdns/pdns/communicator.cc
r1277 r1278 247 247 (sdomains.size()>1 ? "" : "s")<< 248 248 " checking"<<endl; 249 249 map<string, int> skipMasters; 250 250 for(vector<DomainInfo>::iterator i=sdomains.begin();i!=sdomains.end();++i) { 251 251 Resolver resolver; … … 262 262 for(vector<string>::const_iterator iter = i->masters.begin(); iter != i->masters.end(); ++iter) { 263 263 try { 264 if(skipMasters[*iter] > 5) 265 throw AhuException("Skipping query to '"+*iter+"' because of previous timeouts in this cycle"); 266 264 267 resolver.getSoaSerial(*iter, i->zone, &theirserial); 265 268 skipMasters[*iter]=0; 266 269 if(theirserial<i->serial) { 267 270 L<<Logger::Error<<"Domain "<<i->zone<<" more recent than master, our serial "<<ourserial<<" > their serial "<<theirserial<<endl; … … 279 282 } 280 283 catch(ResolverException &re) { 284 if(re.reason.find("Timeout") != string::npos) 285 skipMasters[*iter]++; 286 281 287 L<<Logger::Error<<"Error trying to retrieve/refresh '"+i->zone+"': "+re.reason<<endl; 282 288 if(next(iter) != i->masters.end()) -
trunk/pdns/pdns/resolver.cc
r1215 r1278 185 185 186 186 struct timeval timeout; 187 timeout.tv_sec= 1;188 timeout.tv_usec= 500000;187 timeout.tv_sec=0; 188 timeout.tv_usec=750000; 189 189 190 190 int res=select(d_sock+1,&rd,0,0,&timeout);