Pull request: querylog: fix oldest calc
Updates #4591. Squashed commit of the following: commit 70b70c78c85311363535536c7ea12336b21accf8 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed May 25 17:35:54 2022 +0300 querylog: fix oldest calc
This commit is contained in:
@@ -28,8 +28,11 @@ type QueryLog interface {
|
||||
WriteDiskConfig(c *Config)
|
||||
}
|
||||
|
||||
// Config - configuration object
|
||||
// Config is the query log configuration structure.
|
||||
type Config struct {
|
||||
// Anonymizer processes the IP addresses to anonymize those if needed.
|
||||
Anonymizer *aghnet.IPMut
|
||||
|
||||
// ConfigModified is called when the configuration is changed, for
|
||||
// example by HTTP requests.
|
||||
ConfigModified func()
|
||||
@@ -68,9 +71,6 @@ type Config struct {
|
||||
// AnonymizeClientIP tells if the query log should anonymize clients' IP
|
||||
// addresses.
|
||||
AnonymizeClientIP bool
|
||||
|
||||
// Anonymizer processes the IP addresses to anonymize those if needed.
|
||||
Anonymizer *aghnet.IPMut
|
||||
}
|
||||
|
||||
// AddParams is the parameters for adding an entry.
|
||||
@@ -91,18 +91,18 @@ type AddParams struct {
|
||||
// Result is the filtering result (optional).
|
||||
Result *filtering.Result
|
||||
|
||||
// Elapsed is the time spent for processing the request.
|
||||
Elapsed time.Duration
|
||||
|
||||
ClientID string
|
||||
|
||||
ClientIP net.IP
|
||||
|
||||
// Upstream is the URL of the upstream DNS server.
|
||||
Upstream string
|
||||
|
||||
ClientProto ClientProto
|
||||
|
||||
ClientIP net.IP
|
||||
|
||||
// Elapsed is the time spent for processing the request.
|
||||
Elapsed time.Duration
|
||||
|
||||
// Cached indicates if the response is served from cache.
|
||||
Cached bool
|
||||
|
||||
|
||||
Reference in New Issue
Block a user