--- loncom/loncnew 2008/10/06 10:55:46 1.88 +++ loncom/loncnew 2010/12/20 11:15:51 1.90 @@ -2,7 +2,7 @@ # The LearningOnline Network with CAPA # lonc maintains the connections to remote computers # -# $Id: loncnew,v 1.88 2008/10/06 10:55:46 foxr Exp $ +# $Id: loncnew,v 1.90 2010/12/20 11:15:51 foxr Exp $ # # Copyright Michigan State University Board of Trustees # @@ -85,7 +85,7 @@ my $ClientConnection = 0; # Uniquifier f my $DebugLevel = 0; my $NextDebugLevel= 2; # So Sigint can toggle this. -my $IdleTimeout= 600; # Wait 10 minutes before pruning connections. +my $IdleTimeout= 7200; # Wait two hours before pruning connections. my $LogTransactions = 0; # When True, all transactions/replies get logged. my $executable = $0; # Get the full path to me. @@ -761,6 +761,7 @@ sub KillSocket { delete ($ActiveTransactions{$Socket}); } if(exists($ActiveConnections{$Socket})) { + $ActiveConnections{$Socket}->cancel; delete($ActiveConnections{$Socket}); $ConnectionCount--; if ($ConnectionCount < 0) { $ConnectionCount = 0; } @@ -772,6 +773,7 @@ sub KillSocket { EmptyQueue(); CloseAllLondConnections; # Should all already be closed but... } + UpdateStatus(); } =pod @@ -1206,7 +1208,7 @@ sub MakeLondConnection { &GetServerPort(), &GetHostId()); - if($Connection eq undef) { # Needs to be more robust later. + if($Connection eq undef) { Log("CRITICAL","Failed to make a connection with lond."); $ConnectionRetriesLeft--; return 0; # Failure.