* whois,rdns: use 1 hour cache TTL
This commit is contained in:
parent
e04ffde105
commit
abd251c5c1
|
@ -72,7 +72,7 @@ func (r *RDNS) Begin(ip string) {
|
||||||
// TTL expired
|
// TTL expired
|
||||||
}
|
}
|
||||||
expire = make([]byte, 8)
|
expire = make([]byte, 8)
|
||||||
const ttl = 12 * 60 * 60
|
const ttl = 1 * 60 * 60
|
||||||
binary.BigEndian.PutUint64(expire, now+ttl)
|
binary.BigEndian.PutUint64(expire, now+ttl)
|
||||||
_ = r.ipAddrs.Set([]byte(ip), expire)
|
_ = r.ipAddrs.Set([]byte(ip), expire)
|
||||||
|
|
||||||
|
|
|
@ -205,7 +205,7 @@ func (w *Whois) Begin(ip string) {
|
||||||
// TTL expired
|
// TTL expired
|
||||||
}
|
}
|
||||||
expire = make([]byte, 8)
|
expire = make([]byte, 8)
|
||||||
const ttl = 12 * 60 * 60
|
const ttl = 1 * 60 * 60
|
||||||
binary.BigEndian.PutUint64(expire, now+ttl)
|
binary.BigEndian.PutUint64(expire, now+ttl)
|
||||||
_ = w.ipAddrs.Set([]byte(ip), expire)
|
_ = w.ipAddrs.Set([]byte(ip), expire)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue