-
Notifications
You must be signed in to change notification settings - Fork 503
Delete unreferenced state groups in background #18254
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 54 commits
Commits
Show all changes
62 commits
Select commit
Hold shift + click to select a range
e6a3c46
Add background job to clear unreferenced state groups
devonh f9670ff
Add changelog entry
devonh 9afe80b
Merge branch 'develop' into devon/unreferenced-bg
devonh 20efdd2
Add test for unreferenced state group cleanup
devonh 9c50123
Remove comments
devonh 28679b6
Fix linter errors
devonh e606f42
Merge branch 'develop' into devon/unreferenced-bg
devonh 977d83b
Order state_groups
devonh a487bcb
Update synapse/storage/controllers/purge_events.py
devonh 69d72c2
Update synapse/storage/controllers/purge_events.py
devonh d8bfac4
Update synapse/storage/controllers/purge_events.py
devonh 0955b7b
Update synapse/storage/controllers/purge_events.py
devonh ce87ba6
Change mark as pending deletion to do nothing on conflict
devonh 3900791
Fix linter errors
devonh fe1df20
Move state group deletion job to background updates
devonh cc9e33b
Fix linter error
devonh 801ca86
Pull over all the db calls since that's what it wants...
devonh ccb2158
Try OVERRIDING SYSTEM VALUE
devonh ca7ed76
Move OVERRIDING SYSTEM VALUE
devonh f45dcb1
Update synapse/storage/databases/state/bg_updates.py
devonh 5e05af2
Update synapse/storage/databases/state/bg_updates.py
devonh 7d1ce8d
Review comments & cleanup
devonh 3c50f71
No string interpolation for sql
devonh 7f611e0
Move background task to current schema version
devonh 21dc067
Comment ignoring table port
devonh 09a817f
Deduplicate find_unreferenced_groups
devonh 042af6e
Don't reuse variables
devonh 4cae2e5
Switch to not use single transaction
devonh ae367b2
Try casting
devonh 977a8d8
Readd duplication
devonh d8f920b
Put it back in place
devonh 6582fed
Put it back in place
devonh ecb8ed5
Fix linter error
devonh 8eae7dd
Use multiple db pools
devonh 8ef4a23
Remove duplication again
devonh dfa55a9
Lift logic to purge events controller
devonh 02c2c87
Add IGNORED_BACKGROUND_UPDATES to port_db
devonh 6851eaa
Fix error
devonh d1ca8c7
Update comment on ignoring state_groups_pending_deletion
devonh 0f7c874
Try different sql
devonh 35f15e7
Fixes
devonh 89ec2a3
Update synapse/_scripts/synapse_port_db.py
devonh f5e59f2
Fix port_db syntax
devonh 92d459d
Remove unnecessary code
devonh 5f5f090
Only clear state groups up to max from first iteration
devonh 7c5cf8c
Merge branch 'develop' into devon/unreferenced-bg
devonh 0f53005
Don't delete state groups that would dedelta things
devonh cb7a427
Merge branch 'develop' into devon/unreferenced-bg
devonh 1a4bf3a
Update changelog for new PR
devonh d949884
Move background update to new schema version path
devonh c16f7ee
Fix logic for old deps
devonh ad33303
Remove unnecessary filtering
devonh 7984461
Process groups backwards and simplify logic
devonh 8e18b00
Remove unused var
devonh 093107b
Handle duplicate state groups in edges table
devonh a74d5f3
Combine SQL query
devonh 543828a
Fix linter errors
devonh 1bbcdf8
Update synapse/storage/controllers/purge_events.py
devonh fc70c49
Update synapse/storage/controllers/purge_events.py
devonh c0f0c9c
Rework selection logic to account for in batch chains
devonh b61a294
Update synapse/storage/controllers/purge_events.py
devonh 33ca176
Fix linter error
devonh 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
There are no files selected for viewing
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| Add background job to clear unreferenced state groups. |
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.