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
Add some clarifications to README.md in the database schema directory #6615
Merged
Merged
Changes from all commits
Commits
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 some clarifications to `README.md` in the database schema directory. |
24 changes: 16 additions & 8 deletions
24
synapse/storage/data_stores/main/schema/full_schemas/README.md
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 |
---|---|---|
@@ -1,13 +1,21 @@ | ||
# Building full schema dumps | ||
# Synapse Database Schemas | ||
|
||
These schemas need to be made from a database that has had all background updates run. | ||
These schemas are used as a basis to create brand new Synapse databases, on both | ||
SQLite3 and Postgres. | ||
|
||
To do so, use `scripts-dev/make_full_schema.sh`. This will produce | ||
`full.sql.postgres ` and `full.sql.sqlite` files. | ||
## Building full schema dumps | ||
|
||
If you want to recreate these schemas, they need to be made from a database that | ||
has had all background updates run. | ||
|
||
To do so, use `scripts-dev/make_full_schema.sh`. This will produce new | ||
`full.sql.postgres ` and `full.sql.sqlite` files. | ||
|
||
Ensure postgres is installed and your user has the ability to run bash commands | ||
such as `createdb`. | ||
such as `createdb`, then call | ||
|
||
./scripts-dev/make_full_schema.sh -p postgres_username -o output_dir/ | ||
|
||
``` | ||
./scripts-dev/make_full_schema.sh -p postgres_username -o output_dir/ | ||
``` | ||
There are currently two folders with full-schema snapshots. `16` is a snapshot | ||
from 2015, for historical reference. The other contains the most recent full | ||
schema snapshot. |
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.