Bugzilla – Attachment 157484 Details for
Bug 35111
Background jobs worker crashes on SIGPIPE when database connection lost in Ubuntu 22.04
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 35111: Ignore SIGPIPE in background jobs worker
Bug-35111-Ignore-SIGPIPE-in-background-jobs-worker.patch (text/plain), 1.62 KB, created by
David Cook
on 2023-10-20 01:39:58 UTC
(
hide
)
Description:
Bug 35111: Ignore SIGPIPE in background jobs worker
Filename:
MIME Type:
Creator:
David Cook
Created:
2023-10-20 01:39:58 UTC
Size:
1.62 KB
patch
obsolete
>From abbe8394c5d4c42d11755e1d1dfcf10a70fa895b Mon Sep 17 00:00:00 2001 >From: David Cook <dcook@prosentient.com.au> >Date: Fri, 20 Oct 2023 01:15:00 +0000 >Subject: [PATCH] Bug 35111: Ignore SIGPIPE in background jobs worker > >This change explicitly ignores SIGPIPE signals in the background jobs >worker. > >Daemons like Starman ignore SIGPIPE so it makes sense to explicitly set this. >Differences in the inner workings of MySQL vs MariaDB client libraries have yielded >different behaviours in automatic reconnections and potentially SIGPIPE handling, >so this helps to make the overall behaviour more consistent. > >Test plan: >0. Apply patch and run "restart_all" >1. Go to http://localhost:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=29 >2. Click "Save" > "MARCXML" >3. Go to http://localhost:8081/cgi-bin/koha/tools/stage-marc-import.pl >4. Click "Choose file", choose the MARCXML file, click "Upload file" >5. Click "Stage for import" >6. Note the job is marked as "100% Finished" > >7. In a separate window run "docker restart koha-db-1" >8. Repeat steps 3-5 for uploading file and running stage for import >9. Note that the job is marked as "100% Finished" as you'd expect >--- > misc/workers/background_jobs_worker.pl | 2 ++ > 1 file changed, 2 insertions(+) > >diff --git a/misc/workers/background_jobs_worker.pl b/misc/workers/background_jobs_worker.pl >index 7d2c4f3876..723adbd08c 100755 >--- a/misc/workers/background_jobs_worker.pl >+++ b/misc/workers/background_jobs_worker.pl >@@ -64,6 +64,8 @@ use Koha::Logger; > use Koha::BackgroundJobs; > use C4::Context; > >+$SIG{'PIPE'} = 'IGNORE'; >+ > my ( $help, @queues ); > > my $max_processes = $ENV{MAX_PROCESSES}; >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 35111
:
157484
|
157786
|
157990