This repository has been 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
Optimize how we calculate likely_domains
during backfill
#13575
Merged
MadLittleMods
merged 15 commits into
develop
from
madlittlemods/optimize-backfill-likely-domains
Aug 30, 2022
+89
−70
Merged
Changes from 1 commit
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
4e397c5
Optimize how we calculate likely_domains during backfill
MadLittleMods abd77f7
Update query to order servers by how long they have been in the room …
MadLittleMods d9cd3ef
No need to select depth, just sort by it
MadLittleMods a55f094
Add changelog
MadLittleMods 396ca2d
Replace usage of get_domains_from_state with get_current_hosts_in_room
MadLittleMods cf68485
Add some comments why least depth
MadLittleMods b90ab98
Fix lints
MadLittleMods 6ba5ef3
Skip asking our own server
MadLittleMods 55330c8
Fix logic direction
MadLittleMods aafb356
Sort get_users_in_room so that it matches get_current_hosts_in_room
MadLittleMods f32739c
Fix ambiguous column references and join mistake
MadLittleMods 6700cf5
Use list for guaranteed sort order
MadLittleMods 3fb2ade
Re-arrange to make the logic flow better
MadLittleMods 9a56cbe
Use a set for fast lookups
MadLittleMods 42b04c4
Fix lint about initializing a set
MadLittleMods File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Replace usage of get_domains_from_state with get_current_hosts_in_room
commit 396ca2d885d8cfbabca985f19e92db4b98a0de73
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Eliminating this option to get domains for a room in favor of
get_current_hosts_in_room
.In a room like
#matrixhq
, getting all 80k state events in the room, then whittling it down in the app is not faster than a quick targeted database query or maybe even luckily hitting the cache.