Bugzilla – Attachment 168550 Details for
Bug 37260
Problem with connection to broker not displayed on the about page
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 37260: Check message broker for both 'about' and 'sysinfo' tabs
Bug-37260-Check-message-broker-for-both-about-and-.patch (text/plain), 2.07 KB, created by
Jonathan Druart
on 2024-07-05 13:38:00 UTC
(
hide
)
Description:
Bug 37260: Check message broker for both 'about' and 'sysinfo' tabs
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2024-07-05 13:38:00 UTC
Size:
2.07 KB
patch
obsolete
>From 1e8209e0c4b9b46528db1843885729bb69fe1241 Mon Sep 17 00:00:00 2001 >From: Pedro Amorim <pedro.amorim@ptfs-europe.com> >Date: Fri, 5 Jul 2024 13:28:24 +0000 >Subject: [PATCH] Bug 37260: Check message broker for both 'about' and > 'sysinfo' tabs > >Test plan: >1) Apply test patch only >2) Visit <staff_url>/cgi-bin/koha/about.pl >3) Notice it shows 'Using RabbitMQ' (it should show 'Using SQL polling') >4) Apply this patch, repeat 3) >5) Notice it now shows 'Using SQL polling' >6) Remove test patch. Notice it shows 'Using RabbitMQ' again. >7) Repeat test plan but for /cgi-bin/koha/about.pl?tab=sysinfo tab > >Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >--- > about.pl | 25 +++++++++++++++---------- > 1 file changed, 15 insertions(+), 10 deletions(-) > >diff --git a/about.pl b/about.pl >index 37e400fbb77..3dff63118d7 100755 >--- a/about.pl >+++ b/about.pl >@@ -178,6 +178,8 @@ if ( $tab eq 'about' ) { > $where_is_memcached_config = 'config_only'; > } > >+ message_broker_check($template); >+ > $template->param( > effective_caching_method => $effective_caching_method, > memcached_servers => $memcached_servers, >@@ -672,16 +674,7 @@ if($tab eq 'sysinfo') { > $template->param( warnFastCataloging => $no_FA_framework ); > } > >- { >- # BackgroundJob - test connection to message broker >- eval { >- Koha::BackgroundJob->connect; >- }; >- if ( $@ ) { >- warn $@; >- $template->param( warnConnectBroker => $@ ); >- } >- } >+ message_broker_check($template); > > #BZ 28267: Warn administrators if there are database rows with a format other than 'DYNAMIC' > { >@@ -906,4 +899,16 @@ if ( $tab eq 'history' ) { > } > } > >+sub message_broker_check { >+ my $template = shift; >+ { >+ # BackgroundJob - test connection to message broker >+ eval { Koha::BackgroundJob->connect; }; >+ if ($@) { >+ warn $@; >+ $template->param( warnConnectBroker => $@ ); >+ } >+ } >+ } >+ > output_html_with_http_headers $query, $cookie, $template->output; >-- >2.34.1
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 37260
:
168529
|
168530
|
168549
|
168550
|
169167