Merge pull request #12 from reivilibre/master
Add information from #2 to README about being race-safe
This commit is contained in:
@@ -10,6 +10,14 @@ given file that would change the tables to match the calculated state. (Note
|
|||||||
that if `-t` is given then each change to a particular state group is wrapped
|
that if `-t` is given then each change to a particular state group is wrapped
|
||||||
in a transaction).
|
in a transaction).
|
||||||
|
|
||||||
|
The SQL generated by the `-o` option is safe to apply against the database with
|
||||||
|
Synapse running. This is because the `state_groups` and `state_groups_state`
|
||||||
|
tables are append-only: once written to the database, they are never modified.
|
||||||
|
There is therefore no danger of a modification racing against a running synapse.
|
||||||
|
Further, this script makes its changes within atomic transactions, and each
|
||||||
|
transaction should not affect the results from any of the queries that synapse
|
||||||
|
performs.
|
||||||
|
|
||||||
The tool will also ensure that the generated state deltas do give the same state
|
The tool will also ensure that the generated state deltas do give the same state
|
||||||
as the existing state deltas.
|
as the existing state deltas.
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user