mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-14 00:24:40 +00:00
Reporting: Unbound DNS - duckdb consuming a lot of time doing index maintenance, this should lower the cpu load significantly.
This commit is contained in:
parent
958ff5b7ca
commit
02f44d9024
@ -110,7 +110,9 @@ class DNSReader:
|
||||
""".format(intv=size, min=(size//60), lim=((60//(size//60))*24))
|
||||
)
|
||||
|
||||
db.connection.execute("CREATE INDEX IF NOT EXISTS idx_query ON query (time)")
|
||||
# when an earlier version created an index, make sure it doesn't exists.
|
||||
# We do need to read the file anyway and adding an index means a **lot** of maintenance in the logger.
|
||||
db.connection.execute("DROP INDEX IF EXISTS idx_query")
|
||||
|
||||
def _sig(self, *args):
|
||||
# signal either open() or select() to gracefully close.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user