From 6916b37234d0ddee15e1d54c17bde62f65913945 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Wed, 27 May 2015 10:39:52 -0400 Subject: [PATCH] Reduce communication between SSL and UDP Previously, every TLS connection caused a communication with UDP and this was bad. Then every UDP connection caused a communication and this was better. This takes things a little further by only doing the communication if there is a known interested party now. --- xCAT-server/sbin/xcatd | 2 ++ 1 file changed, 2 insertions(+) diff --git a/xCAT-server/sbin/xcatd b/xCAT-server/sbin/xcatd index 6dac1d512..6c862f2b4 100755 --- a/xCAT-server/sbin/xcatd +++ b/xCAT-server/sbin/xcatd @@ -526,6 +526,8 @@ sub grant_tcrequests { my $requestors = shift; my $udpcontext = shift; my $availableslots = $batchclients; + if (not keys %{$requestors}) { return; } # skip the interaction with SSL if + # no requests are actually pending my $oldtime = time()-180; #drop requests older than three minutes if still around my $msg; eval { store_fd({'req'=>'get_client_count'}, $sslctl); $msg = fd_retrieve($sslctl); };