This repository was archived by the owner on Apr 26, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
This repository was archived by the owner on Apr 26, 2024. It is now read-only.
Optimize /backfill to respond faster #15653
Copy link
Copy link
Open
Labels
A-FederationA-Messages-Endpoint/messages client API endpoint (`RoomMessageListRestServlet`) (which also triggers /backfill)/messages client API endpoint (`RoomMessageListRestServlet`) (which also triggers /backfill)A-PerformancePerformance, both client-facing and admin-facingPerformance, both client-facing and admin-facingT-EnhancementNew features, changes in functionality, improvements in performance, or user-facing enhancements.New features, changes in functionality, improvements in performance, or user-facing enhancements.
Milestone
Description
Since /backfill is a big part of /messages performance, optimizing /backfill would help other servers respond to our /backfill requests faster which means we can respond to /messages faster.
From the examples below, it seems like we have these obvious opportunities to improve:
get_backfill_events(...): Seems like a pretty slow query that we could probably turn into a recursive query.get_current_state->get_filtered_current_state_ids: Takes ~200msis_host_joined: uncached call took ~200ms_get_state_groups_from_groups(...): A known slow thing
Metadata
Metadata
Assignees
Labels
A-FederationA-Messages-Endpoint/messages client API endpoint (`RoomMessageListRestServlet`) (which also triggers /backfill)/messages client API endpoint (`RoomMessageListRestServlet`) (which also triggers /backfill)A-PerformancePerformance, both client-facing and admin-facingPerformance, both client-facing and admin-facingT-EnhancementNew features, changes in functionality, improvements in performance, or user-facing enhancements.New features, changes in functionality, improvements in performance, or user-facing enhancements.

