I have an application to test that requires only one conversation per socket connection. Currently, TCPSampler re-uses sockets for multiple conversations. I've added an enhancement to select whether to re-use the socket or create a new socket for each conversation. Patch is attached.
Created attachment 19452 [details] Patch to implement this enhancement Adds a Re-Use Connection checkbox to the TCLSampler. If checked (the default) then the TCPSampler will re-use the same connection in each loop for each thread. If not checked TCPSampler will open a new connection with each loop.
Thanks for the patches. I had to change the TCPConfig patch slightly to ensure that existing test plans (without the new variable) retained the original behaviour. The next nightly build dated after this update will contain the fix: http://people.apache.org/builds/jakarta-jmeter/nightly/
This issue has been migrated to GitHub: https://github.com/apache/jmeter/issues/1853