+

Search Tips   |   Advanced Search


Add a socket close

You can manually add a socket close element to a socket API performance test.

In a performance test, socket close elements close the connection to a server. A socket close element relates to a specific socket connection.

Ensure that for each socket connection, there is a corresponding socket close. If not, during the test run, the operating system can run out of socket handles, causing the test to fail. To add a socket close to a performance test:

  1. Open the performance test in the test editor.

  2. In the Test Contents area of the test editor, right-click the test node, and click Add > Socket Close.

  3. In the Test Element Details section, click Change and select the socket connection to close. You can specify a Think Time delay before the test establishes the connection.


Results

After you have closed a connection, you can no longer send or receive data from that connection. If any test elements use a connection after the close element, they are flagged with an error in the test editor.


Related reference

  • Socket close details