<!DOCTYPE html><html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<div class="moz-cite-prefix">On 26/11/2025 10:32, David wrote:<br>
</div>
<blockquote type="cite" cite="mid:CAG-0zZdhzfX0m6bG5c0XGYTGuBBn2Vym6A06yZEpoPmz3=whfw@mail.gmail.com">
<div dir="ltr"><br>
<div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">I
assume it also benefits from being able to use HTTP
persistent<span class="gmail-Apple-converted-space"> </span><br>
connections.<br>
</blockquote>
<div><br>
</div>
<div>Just trying to understand, does that mean that virtual
threads don't have this? Because running Socket Statistics
in the background showing 17K established connections while
running virtual threads vs 140 when using platform threads.</div>
<div><br>
</div>
<div>At this point I am just trying to understand where this
delay is coming from and why virtual threads trigger this.</div>
<br>
</div>
</div>
</blockquote>
Persistent connections avoid needing a separate TCP connection for
each request. LoomBenchmark's FixedPlatformPool appears to use a
thread pool with 4 workers so it gets to benefit from the having the
cached connection. Tomcat probably has more configuration to
limit/configure the number connections to keep alive, probably 100
or 200 by default. LoomBenchmark.java's virtualThreadExecutor is a
completely different test. It attempts to establish 10k concurrent
connections, it's probably causing connections to be closed and
re-established at each iteration.<br>
<br>
-Alan<br>
</body>
</html>