Fix Matrix event handle time metrics (ref #120)
This commit is contained in:
@@ -383,10 +383,6 @@ class MatrixHandler(BaseMatrixHandler):
|
|||||||
elif evt.type == EventType.ROOM_TOMBSTONE:
|
elif evt.type == EventType.ROOM_TOMBSTONE:
|
||||||
await self.handle_room_upgrade(evt.room_id, evt.sender, evt.content.replacement_room)
|
await self.handle_room_upgrade(evt.room_id, evt.sender, evt.content.replacement_room)
|
||||||
|
|
||||||
# async def handle_event(self, evt: MatrixEvent) -> None:
|
async def log_event_handle_duration(self, evt: Event, duration: float) -> None:
|
||||||
# if self.filter_matrix_event(evt):
|
if EVENT_TIME:
|
||||||
# return
|
EVENT_TIME.labels(event_type=str(evt.type)).observe(duration)
|
||||||
# start_time = time.time()
|
|
||||||
#
|
|
||||||
# if EVENT_TIME:
|
|
||||||
# EVENT_TIME.labels(event_type=evt_type).observe(time.time() - start_time)
|
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ setuptools.setup(
|
|||||||
|
|
||||||
install_requires=[
|
install_requires=[
|
||||||
"aiohttp>=3.0.1,<4",
|
"aiohttp>=3.0.1,<4",
|
||||||
"mautrix>=0.4.0.dev79,<0.5",
|
"mautrix>=0.4.0.dev80,<0.5",
|
||||||
"SQLAlchemy>=1.2.3,<2",
|
"SQLAlchemy>=1.2.3,<2",
|
||||||
"alembic>=1.0.0,<2",
|
"alembic>=1.0.0,<2",
|
||||||
"commonmark>=0.8.1,<0.10",
|
"commonmark>=0.8.1,<0.10",
|
||||||
|
|||||||
Reference in New Issue
Block a user