From: Chris Dary Date: Fri, 24 Sep 2021 19:47:08 +0000 (-0400) Subject: MultiDB README: Add a bit more detail X-Git-Tag: rel_1_7_4~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d95e15cac59dc449f712f51183462a8688a51086;p=thirdparty%2Fsqlalchemy%2Falembic.git MultiDB README: Add a bit more detail --- diff --git a/alembic/templates/multidb/README b/alembic/templates/multidb/README index 5db219f9..f046ec91 100644 --- a/alembic/templates/multidb/README +++ b/alembic/templates/multidb/README @@ -1 +1,12 @@ -Rudimentary multi-database configuration. \ No newline at end of file +Rudimentary multi-database configuration. + +Multi-DB isn't vastly different from generic. The primary difference is that it +will run the migrations N times (depending on how many databases you have +configured), providing one engine name and associated context for each run. + +That engine name will then allow the migration to restrict what runs within it to +just the appropriate migrations for that engine. You can see this behavior within +the mako template. + +In the provided configuration, you'll need to have `databases` provided in +alembic's config, and an `sqlalchemy.url` provided for each engine name.