From ec896d01f6e4c641d25054d1421571ed88026dd7 Mon Sep 17 00:00:00 2001 From: dvanaken Date: Wed, 23 Oct 2019 16:17:25 -0400 Subject: [PATCH] Updated MySQL-specific migration that enables compression to be non-atomic --- .../website/website/migrations/0002_enable_compression.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/server/website/website/migrations/0002_enable_compression.py b/server/website/website/migrations/0002_enable_compression.py index a9ef5eb..6bfcafe 100644 --- a/server/website/website/migrations/0002_enable_compression.py +++ b/server/website/website/migrations/0002_enable_compression.py @@ -45,15 +45,11 @@ def compression_supported(schema_editor): def enable_compression(apps, schema_editor): - # try: if compression_supported(schema_editor): for table in TABLES_TO_COMPRESS: schema_editor.execute(ALTER_SQL % (table, 'zlib')) schema_editor.execute(OPTIMIZE_SQL % table) - # except ProgrammingError: - # LOG.warning("Error applying forward migration '0002_enable_compression'... Skipping.") - def disable_compression(apps, schema_editor): try: @@ -68,6 +64,8 @@ def disable_compression(apps, schema_editor): class Migration(migrations.Migration): + atomic = False + dependencies = [ ('website', '0001_initial'), ]