feat: improve event logging for queries + refactor (#27943)

Co-authored-by: Beto Dealmeida <roberto@dealmeida.net>
This commit is contained in:
Maxime Beauchemin
2024-04-22 16:30:50 -07:00
committed by GitHub
parent 83fedcc9ea
commit cfc440c56c
14 changed files with 169 additions and 132 deletions

View File

@@ -144,8 +144,9 @@ class TestEventLogger(unittest.TestCase):
assert logger.records == [
{
"records": [{"path": "/", "engine": "bar"}],
"database_id": None,
"user_id": 2,
"duration": 15000.0,
"duration": 15000,
}
]
@@ -191,6 +192,7 @@ class TestEventLogger(unittest.TestCase):
"payload_override": {"engine": "sqlite"},
}
],
"database_id": None,
"user_id": 2,
"duration": 5558756000,
}