From 33d47537fc521bd83be18c12a8e0e61d8f8bbaec Mon Sep 17 00:00:00 2001 From: Jason Boyer Date: Wed, 2 Jun 2021 09:43:12 -0400 Subject: [PATCH] LP1930578: Really Stop Single Services Use the same timeout / escalation method for single services as is used for all services. Punted on any real refactoring for now. Signed-off-by: Jason Boyer Signed-off-by: Galen Charlton --- bin/opensrf-perl.pl.in | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/bin/opensrf-perl.pl.in b/bin/opensrf-perl.pl.in index d2f5267..b2bced6 100755 --- a/bin/opensrf-perl.pl.in +++ b/bin/opensrf-perl.pl.in @@ -113,7 +113,6 @@ if ($opt_localhost) { } my $C_COMMAND = "opensrf-c -c $opt_config -x opensrf -p $opt_pid_dir -h $hostname"; -my $PY_COMMAND = "opensrf.py -f $opt_config -p $opt_pid_dir ". ($opt_localhost ? '-l' : ''); sub verify_services { my $service = shift; @@ -446,7 +445,12 @@ sub do_start_services { sub do_signal { my $service = shift; my $signal = shift; - return do_signal_all($signal, $service); + do_signal_send($service, $signal); + + # if user passed a know non-shutdown signal, we're done. + return 1 if $signal =~ /HUP|USR1|USR2/; + + return do_signal_wait($service); } # returns the list of running services based on presence of PID files. -- 2.11.0