Diff for /loncom/loncnew between versions 1.38 and 1.39

version 1.38, 2004/01/05 09:29:36 version 1.39, 2004/01/13 09:57:18
Line 89  my $DebugLevel = 0; Line 89  my $DebugLevel = 0;
 my $NextDebugLevel= 2; # So Sigint can toggle this.  my $NextDebugLevel= 2; # So Sigint can toggle this.
 my $IdleTimeout= 3600; # Wait an hour before pruning connections.  my $IdleTimeout= 3600; # Wait an hour before pruning connections.
   
   my $LogTransactions = 0; # When True, all transactions/replies get logged.
   
 #  #
 #  The variables below are only used by the child processes.  #  The variables below are only used by the child processes.
 #  #
Line 513  sub CompleteTransaction { Line 515  sub CompleteTransaction {
   
     if (!$Transaction->isDeferred()) { # Normal transaction      if (!$Transaction->isDeferred()) { # Normal transaction
  my $data   = $Socket->GetReply(); # Data to send.   my $data   = $Socket->GetReply(); # Data to send.
    if($LogTransactions) {
       Log("SUCCESS", "Reply from lond: '$data'");
    }
  StartClientReply($Transaction, $data);   StartClientReply($Transaction, $data);
     } else { # Delete deferred transaction file.      } else { # Delete deferred transaction file.
  Log("SUCCESS", "A delayed transaction was completed");   Log("SUCCESS", "A delayed transaction was completed");
Line 1217  sub ClientRequest { Line 1222  sub ClientRequest {
     exit;      exit;
  }   }
  Debug(8, "Complete transaction received: ".$data);   Debug(8, "Complete transaction received: ".$data);
    if($LogTransactions) {
       Log("SUCCESS", "Transaction: '$data'"); # Transaction has \n.
    }
  my $Transaction = LondTransaction->new($data);   my $Transaction = LondTransaction->new($data);
  $Transaction->SetClient($socket);   $Transaction->SetClient($socket);
  QueueTransaction($Transaction);   QueueTransaction($Transaction);
Line 1325  sub SetupLoncListener { Line 1333  sub SetupLoncListener {
       fd     => $socket);        fd     => $socket);
 }  }
   
   #
   #   Toggle transaction logging.
   #  Implicit inputs:  
   #     LogTransactions
   #  Implicit Outputs:
   #     LogTransactions
   sub ToggleTransactionLogging {
       print STDERR "Toggle transaction logging...\n";
       if(!$LogTransactions) {
    $LogTransactions = 1;
       } else {
    $LogTransactions = 0;
       }
   
   
       Log("SUCCESS", "Toggled transaction logging: $LogTransactions \n");
   }
   
 =pod   =pod 
   
 =head2 ChildStatus  =head2 ChildStatus
Line 1422  sub ChildProcess { Line 1448  sub ChildProcess {
     Event->signal(signal   => "USR1",      Event->signal(signal   => "USR1",
   cb       => \&ChildStatus,    cb       => \&ChildStatus,
   data     => "USR1");    data     => "USR1");
       Event->signal(signal   => "USR2",
     cb       => \&ToggleTransactionLogging);
     Event->signal(signal   => "INT",      Event->signal(signal   => "INT",
   cb       => \&ToggleDebug,    cb       => \&ToggleDebug,
   data     => "INT");    data     => "INT");

Removed from v.1.38  
changed lines
  Added in v.1.39


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>