Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Use room_stats_state.room_type column instead of fetching m.room.create event #13130

Closed
squahtx opened this issue Jun 29, 2022 · 2 comments · Fixed by #14263
Closed

Use room_stats_state.room_type column instead of fetching m.room.create event #13130

squahtx opened this issue Jun 29, 2022 · 2 comments · Fixed by #14263
Assignees
Labels
A-Spaces Hierarchical organization of rooms P4 (OBSOLETE: use S- labels.) Okay backlog: will not schedule, will accept patches S-Tolerable Minor significance, cosmetic issues, low or no impact to users. T-Task Refactoring, removal, replacement, enabling or disabling functionality, other engineering tasks.

Comments

@squahtx
Copy link
Contributor

squahtx commented Jun 29, 2022

#13031 introduced a room_type column in room_stats_state. There are now one or two places where we can avoid fetching m.room.create events and just use the new column instead.

Searching for EventContentFields.ROOM_TYPE or "room_type" ought to find them all.

eg. if we make get_room_with_stats return room_type, we can avoid fetching the m.room.create event in RoomSummaryHandler._build_room_entry.

@squahtx squahtx added S-Tolerable Minor significance, cosmetic issues, low or no impact to users. T-Task Refactoring, removal, replacement, enabling or disabling functionality, other engineering tasks. A-Spaces Hierarchical organization of rooms P4 (OBSOLETE: use S- labels.) Okay backlog: will not schedule, will accept patches labels Jun 29, 2022
@clokep
Copy link
Member

clokep commented Jun 29, 2022

We do need to wait until the background update finishes, however. I'm unsure if we have a standard way of doing that?

@clokep
Copy link
Member

clokep commented Oct 21, 2022

eg. if we make get_room_with_stats return room_type

Looks like #13208 already did this part! 🎉

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A-Spaces Hierarchical organization of rooms P4 (OBSOLETE: use S- labels.) Okay backlog: will not schedule, will accept patches S-Tolerable Minor significance, cosmetic issues, low or no impact to users. T-Task Refactoring, removal, replacement, enabling or disabling functionality, other engineering tasks.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants