Changeset 27402


Ignore:
Timestamp:
05/23/13 13:43:54 (8 years ago)
Author:
jmt12
Message:

If a socket fails to be created, and if we are the first client, then it is more likely to be caused by the server being a bit slow to startup, rather than by the TCP port pool being exhausted

File:
1 edited

Legend:

Unmodified
Added
Removed
  • gs2-extensions/tdb-edit/trunk/src/perllib/SocketsSwimmingThreadPoolClient.pm

    r26993 r27402  
    6767      return $socket;
    6868    }
    69     print "Failed to create client socket: $!\n";
    70     print "=> Most likely cause - TCP ephemeral ports exhausted (stuck in TIME_WAITs)\n";
    71     print "=> Retry in " . $retry_time . " seconds.\n";
    72     sleep($retry_time);
     69    # if we are the very first caller, and a socket didn't get created, then
     70    # most likely the server is still starting up... wait a little longer
     71    # before complaining
     72    if ($self->{'firstcaller'})
     73    {
     74      print "* Still waiting...\n";
     75    }
     76    else
     77    {
     78      print "Failed to create client socket: $!\n";
     79      print "=> Most likely cause - TCP ephemeral ports exhausted (stuck in TIME_WAITs)\n";
     80      print "=> Retry in " . $retry_time . " seconds.\n";
     81      sleep($retry_time);
     82    }
    7383    $retry_limit--;
    7484  }
Note: See TracChangeset for help on using the changeset viewer.