[freeside-commits] freeside/FS/bin freeside-torrus-srvderive, 1.37, 1.38
Ivan,,,
ivan at wavetail.420.am
Fri Apr 8 10:02:58 PDT 2011
Update of /home/cvs/cvsroot/freeside/FS/bin
In directory wavetail.420.am:/tmp/cvs-serv17105/FS/bin
Modified Files:
freeside-torrus-srvderive
Log Message:
continue attempting to handle mysql hanging on queries, RT#10574
Index: freeside-torrus-srvderive
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/bin/freeside-torrus-srvderive,v
retrieving revision 1.37
retrieving revision 1.38
diff -u -w -d -r1.37 -r1.38
--- freeside-torrus-srvderive 8 Apr 2011 14:53:15 -0000 1.37
+++ freeside-torrus-srvderive 8 Apr 2011 17:02:56 -0000 1.38
@@ -64,7 +64,7 @@
my $found = 0;
- foreach my $torrus_srvderive ( qsearch('torrus_srvderive', {}) ) {
+ SERVICEID: foreach my $torrus_srvderive ( qsearch('torrus_srvderive', {}) ) {
my $serviceid = $torrus_srvderive->serviceid;
@@ -117,7 +117,7 @@
eval {
my $h = set_sig_handler( 'ALRM', sub { die "_timeout\n"; } );
- alarm(5*60); #$torrus_srvderive->last_srv_date ? 5*60 : 15*60);
+ alarm(10*60); #5*60); #$torrus_srvderive->last_srv_date ? 5*60 : 15*60);
$sth->execute($serviceid, $serviceid) or die $sth->errstr;
alarm(0);
};
@@ -127,8 +127,9 @@
warn "search timed out; reconnecting and restarting\n";
dbh->clone()->do("KILL QUERY ". dbh->{"mysql_thread_id"})
if driver_name eq 'mysql';
+ dbh->rollback; #or die dbh->errstr;
adminsuidsetup($user);
- next MAIN;
+ next SERVICEID; #MAIN;
} elsif ( $@ ) {
die $@;
}
@@ -178,7 +179,7 @@
$isth->errstr;
dbh->rollback; #or die dbh->errstr;
sleep 5;
- next MAIN;
+ next SERVICEID; #MAIN;
}
}
More information about the freeside-commits
mailing list