mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-06 12:45:03 -04:00
Add in flight request metrics
This tracks CPU and DB usage while requests are in flight, rather than when we write the response.
This commit is contained in:
parent
08462620bf
commit
dfa70adc33
2 changed files with 154 additions and 2 deletions
|
@ -85,7 +85,9 @@ class SynapseRequest(Request):
|
|||
def _started_processing(self, servlet_name):
|
||||
self.start_time = int(time.time() * 1000)
|
||||
self.request_metrics = RequestMetrics()
|
||||
self.request_metrics.start(self.start_time, name=servlet_name)
|
||||
self.request_metrics.start(
|
||||
self.start_time, name=servlet_name, method=self.method,
|
||||
)
|
||||
|
||||
self.site.access_logger.info(
|
||||
"%s - %s - Received request: %s %s",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue