drop legacy domain tables
This commit is contained in:
14
db/migrate/20250722005802_move_blob_files_tablespaces.rb
Normal file
14
db/migrate/20250722005802_move_blob_files_tablespaces.rb
Normal file
@@ -0,0 +1,14 @@
|
||||
class MoveBlobFilesTablespaces < ActiveRecord::Migration[7.2]
|
||||
disable_ddl_transaction!
|
||||
|
||||
def up
|
||||
64.times { |i| execute <<-SQL }
|
||||
ALTER TABLE blob_files_#{i.to_s.rjust(2, "0")} SET TABLESPACE pg_default;
|
||||
ALTER INDEX index_blob_files_#{i.to_s.rjust(2, "0")}_on_sha256 SET TABLESPACE pg_default;
|
||||
SQL
|
||||
end
|
||||
|
||||
def down
|
||||
raise ActiveRecord::IrreversibleMigration
|
||||
end
|
||||
end
|
||||
13
db/migrate/20250722010327_drop_old_e621_domain_tables.rb
Normal file
13
db/migrate/20250722010327_drop_old_e621_domain_tables.rb
Normal file
@@ -0,0 +1,13 @@
|
||||
class DropOldE621DomainTables < ActiveRecord::Migration[7.2]
|
||||
def up
|
||||
drop_table :domain_e621_favs
|
||||
drop_table :domain_e621_taggings
|
||||
drop_table :domain_e621_tags
|
||||
drop_table :domain_e621_posts
|
||||
drop_table :domain_e621_users
|
||||
end
|
||||
|
||||
def down
|
||||
raise ActiveRecord::IrreversibleMigration
|
||||
end
|
||||
end
|
||||
15
db/migrate/20250722010822_drop_old_fa_domain_tables.rb
Normal file
15
db/migrate/20250722010822_drop_old_fa_domain_tables.rb
Normal file
@@ -0,0 +1,15 @@
|
||||
class DropOldFaDomainTables < ActiveRecord::Migration[7.2]
|
||||
def up
|
||||
drop_table :domain_fa_user_avatar_versions
|
||||
drop_table :domain_fa_user_avatars
|
||||
drop_table :domain_fa_favs
|
||||
drop_table :domain_fa_user_factors
|
||||
drop_table :domain_fa_follows
|
||||
drop_table :domain_fa_post_factors
|
||||
drop_table :domain_fa_users
|
||||
end
|
||||
|
||||
def down
|
||||
raise ActiveRecord::IrreversibleMigration
|
||||
end
|
||||
end
|
||||
17
db/migrate/20250722013801_drop_old_ib_domain_tables.rb
Normal file
17
db/migrate/20250722013801_drop_old_ib_domain_tables.rb
Normal file
@@ -0,0 +1,17 @@
|
||||
class DropOldIbDomainTables < ActiveRecord::Migration[7.2]
|
||||
def up
|
||||
drop_table :domain_inkbunny_favs
|
||||
drop_table :domain_inkbunny_taggings
|
||||
drop_table :domain_inkbunny_pool_joins
|
||||
drop_table :domain_inkbunny_follows
|
||||
drop_table :domain_inkbunny_pools
|
||||
drop_table :domain_inkbunny_tags
|
||||
drop_table :domain_inkbunny_files
|
||||
drop_table :domain_inkbunny_posts
|
||||
drop_table :domain_inkbunny_users
|
||||
end
|
||||
|
||||
def down
|
||||
raise ActiveRecord::IrreversibleMigration
|
||||
end
|
||||
end
|
||||
1657
db/structure.sql
1657
db/structure.sql
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user