From 263dbe7bfe8ef3fac599c461a16cabfd28f8c5be Mon Sep 17 00:00:00 2001 From: epriestley Date: Fri, 19 Sep 2014 05:44:29 -0700 Subject: [PATCH] Drop old Audit tables; make markup cache binary Summary: Ref T1191. - Fixes T6096. We've migrated away from this table in T4896. The data is now in the transaction table. There have been no reads or writes to this table for some time and I haven't seen any issues from users. - Fixes T6097. Same deal as above. The data is now in the transaction comment table. - Fixes T6100. This cache is safe to wipe out, since it's purely read-through. Wiping it will make the migration faster. The column type change fixes storage of PHP serialized objects in a text column. Test Plan: - Ran migrations. - Observed some yellow go blue on the Database Status screen. Reviewers: btrahan Reviewed By: btrahan Subscribers: epriestley Maniphest Tasks: T6096, T6100, T6097, T1191 Differential Revision: https://secure.phabricator.com/D10520 --- resources/sql/autopatches/20140918.schema.1.dropaudit.sql | 1 + resources/sql/autopatches/20140918.schema.2.dropauditinline.sql | 1 + resources/sql/autopatches/20140918.schema.3.wipecache.sql | 1 + resources/sql/autopatches/20140918.schema.4.cachetype.sql | 2 ++ 4 files changed, 5 insertions(+) create mode 100644 resources/sql/autopatches/20140918.schema.1.dropaudit.sql create mode 100644 resources/sql/autopatches/20140918.schema.2.dropauditinline.sql create mode 100644 resources/sql/autopatches/20140918.schema.3.wipecache.sql create mode 100644 resources/sql/autopatches/20140918.schema.4.cachetype.sql diff --git a/resources/sql/autopatches/20140918.schema.1.dropaudit.sql b/resources/sql/autopatches/20140918.schema.1.dropaudit.sql new file mode 100644 index 0000000000..ee01e84883 --- /dev/null +++ b/resources/sql/autopatches/20140918.schema.1.dropaudit.sql @@ -0,0 +1 @@ +DROP TABLE {$NAMESPACE}_audit.audit_comment; diff --git a/resources/sql/autopatches/20140918.schema.2.dropauditinline.sql b/resources/sql/autopatches/20140918.schema.2.dropauditinline.sql new file mode 100644 index 0000000000..692261cb3b --- /dev/null +++ b/resources/sql/autopatches/20140918.schema.2.dropauditinline.sql @@ -0,0 +1 @@ +DROP TABLE {$NAMESPACE}_audit.audit_inlinecomment; diff --git a/resources/sql/autopatches/20140918.schema.3.wipecache.sql b/resources/sql/autopatches/20140918.schema.3.wipecache.sql new file mode 100644 index 0000000000..636f2ef3ea --- /dev/null +++ b/resources/sql/autopatches/20140918.schema.3.wipecache.sql @@ -0,0 +1 @@ +TRUNCATE TABLE {$NAMESPACE}_cache.cache_markupcache; diff --git a/resources/sql/autopatches/20140918.schema.4.cachetype.sql b/resources/sql/autopatches/20140918.schema.4.cachetype.sql new file mode 100644 index 0000000000..1ce047798a --- /dev/null +++ b/resources/sql/autopatches/20140918.schema.4.cachetype.sql @@ -0,0 +1,2 @@ +ALTER TABLE {$NAMESPACE}_cache.cache_markupcache + CHANGE cacheData cacheData LONGBLOB NOT NULL;