From 6d74511c5c555b4b078fe3755ae75edad4d7a599 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Thu, 4 Nov 2021 10:44:28 +0100 Subject: [PATCH] Bug 29386: Extend background_jobs.data to LONGTEXT TEXT is too small, we must extend it to allow bigger jobs. Signed-off-by: Marcel de Rooy Signed-off-by: Jonathan Druart Signed-off-by: Kyle M Hall (cherry picked from commit d79599b7ecd384ae5b8beee12e80fb522b1e4583) Signed-off-by: Fridolin Somers --- installer/data/mysql/atomicupdate/bug_29386.pl | 14 ++++++++++++++ installer/data/mysql/kohastructure.sql | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) create mode 100755 installer/data/mysql/atomicupdate/bug_29386.pl diff --git a/installer/data/mysql/atomicupdate/bug_29386.pl b/installer/data/mysql/atomicupdate/bug_29386.pl new file mode 100755 index 0000000000..ba57d823a1 --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_29386.pl @@ -0,0 +1,14 @@ +use Modern::Perl; + +return { + bug_number => "29386", + description => "Extend background_jobs.data to LONGTEXT", + up => sub { + my ($args) = @_; + my ($dbh, $out) = @$args{qw(dbh out)}; + $dbh->do(q| + ALTER TABLE background_jobs + CHANGE COLUMN `data` `data` LONGTEXT DEFAULT NULL + |); + }, +} diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql index 01a55c9ccd..c6535134a3 100644 --- a/installer/data/mysql/kohastructure.sql +++ b/installer/data/mysql/kohastructure.sql @@ -4683,7 +4683,7 @@ CREATE TABLE background_jobs ( size INT(11), borrowernumber INT(11), type VARCHAR(64), - data TEXT, + data LONGTEXT, enqueued_on DATETIME DEFAULT NULL, started_on DATETIME DEFAULT NULL, ended_on DATETIME DEFAULT NULL, -- 2.39.5