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

Add --run-background-updates option to update_database script. #10954

Merged
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .ci/scripts/test_synapse_port_db.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ python -m synapse.app.homeserver --generate-keys -c .ci/sqlite-config.yaml
echo "--- Prepare test database"

# Make sure the SQLite3 database is using the latest schema and has no pending background update.
scripts-dev/update_database --database-config .ci/sqlite-config.yaml
scripts/update_synapse_database --database-config .ci/sqlite-config.yaml

# Create the PostgreSQL database.
.ci/scripts/postgres_exec.py "CREATE DATABASE synapse"
Expand All @@ -46,7 +46,7 @@ echo "--- Prepare empty SQLite database"
# we do this by deleting the sqlite db, and then doing the same again.
rm .ci/test_db.db

scripts-dev/update_database --database-config .ci/sqlite-config.yaml
scripts/update_synapse_database --database-config .ci/sqlite-config.yaml

# re-create the PostgreSQL database.
.ci/scripts/postgres_exec.py \
Expand Down
2 changes: 1 addition & 1 deletion scripts-dev/lint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,10 @@ else
"scripts/hash_password"
"scripts/register_new_matrix_user"
"scripts/synapse_port_db"
"scripts/update_synapse_database"
"scripts-dev"
"scripts-dev/build_debian_packages"
"scripts-dev/sign_json"
"scripts-dev/update_database"
"contrib" "synctl" "setup.py" "synmark" "stubs" ".ci"
)
fi
Expand Down
2 changes: 1 addition & 1 deletion scripts-dev/make_full_schema.sh
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ python -m synapse.app.homeserver --generate-keys -c "$SQLITE_CONFIG"

# Make sure the SQLite3 database is using the latest schema and has no pending background update.
echo "Running db background jobs..."
scripts-dev/update_database --database-config "$SQLITE_CONFIG"
scripts/update_synapse_database --database-config "$SQLITE_CONFIG"
richvdh marked this conversation as resolved.
Show resolved Hide resolved

# Create the PostgreSQL database.
echo "Creating postgres database..."
Expand Down
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ lint_targets =
scripts/hash_password
scripts/register_new_matrix_user
scripts/synapse_port_db
scripts/update_synapse_database
scripts-dev
scripts-dev/build_debian_packages
scripts-dev/sign_json
scripts-dev/update_database
stubs
contrib
synctl
Expand Down