summary refs log tree commit diff
path: root/scripts-dev
diff options
context:
space:
mode:
authorAndrew Morgan <andrew@amorgan.xyz>2020-03-20 14:39:41 +0000
committerAndrew Morgan <andrew@amorgan.xyz>2020-03-20 14:39:41 +0000
commit032fed6f42268d37a7b8a78ee3631980fda4aee9 (patch)
treed84356343c5a7ab4b1d0bf2923501f714077e06f /scripts-dev
parent1.7.1 (diff)
parentAdd database config class (#6513) (diff)
downloadsynapse-032fed6f42268d37a7b8a78ee3631980fda4aee9.tar.xz
Add database config class (#6513)
* commit '2284eb3a5':
  Add database config class (#6513)
  too many parens
Diffstat (limited to 'scripts-dev')
-rwxr-xr-xscripts-dev/update_database9
1 files changed, 2 insertions, 7 deletions
diff --git a/scripts-dev/update_database b/scripts-dev/update_database

index 23017c21f8..1d62f0403a 100755 --- a/scripts-dev/update_database +++ b/scripts-dev/update_database
@@ -26,7 +26,6 @@ from synapse.config.homeserver import HomeServerConfig from synapse.metrics.background_process_metrics import run_as_background_process from synapse.server import HomeServer from synapse.storage import DataStore -from synapse.storage.prepare_database import prepare_database logger = logging.getLogger("update_database") @@ -77,12 +76,8 @@ if __name__ == "__main__": # Instantiate and initialise the homeserver object. hs = MockHomeserver(config) - db_conn = hs.get_db_conn() - # Update the database to the latest schema. - prepare_database(db_conn, hs.database_engine, config=config) - db_conn.commit() - - # setup instantiates the store within the homeserver object. + # Setup instantiates the store within the homeserver object and updates the + # DB. hs.setup() store = hs.get_datastore()