feat(legacy): move session store to database (#2523)
This commit is contained in:
parent
be282fac80
commit
001466f8fd
14 changed files with 2259 additions and 5 deletions
|
@ -0,0 +1,34 @@
|
|||
# pylint: disable=invalid-name
|
||||
|
||||
from django.db import migrations
|
||||
|
||||
from ._migrations import legacy_migration_factory
|
||||
|
||||
UP = """
|
||||
CREATE TABLE "sessions"
|
||||
(
|
||||
"id" CHAR(32) NOT NULL,
|
||||
"modified" INTEGER,
|
||||
"lifetime" INTEGER,
|
||||
"data" TEXT,
|
||||
PRIMARY KEY ("id")
|
||||
);
|
||||
"""
|
||||
|
||||
DOWN = """
|
||||
DROP TABLE IF EXISTS "sessions" CASCADE;
|
||||
"""
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
("legacy", "0044_add_track_types_analyzer_options"),
|
||||
]
|
||||
operations = [
|
||||
migrations.RunPython(
|
||||
code=legacy_migration_factory(
|
||||
target="45",
|
||||
sql=UP,
|
||||
)
|
||||
)
|
||||
]
|
Loading…
Add table
Add a link
Reference in a new issue