-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Mark,

On 1/11/19 12:23, Mark Thomas wrote:
> On 10/01/2019 19:55, Mark Thomas wrote:
> 
> <snip/>
> 
>> I've just tracked down one leak although it is a relatively small
>> one. Next steps are to fix that leak and then find the next one.
>> And then repeat.
> 
> Found it.
> 
> The leak impacted NIO and NIO2 when used with OpenSSL.
> 
> The bug is in Tomcat Native. I have a fix that I am currently
> testing. That fix should be in the next Tomcat Native release.
> 
> For those interested in the technical details, Tomcat Native
> allocates some Native memory to track various attributes of each
> connection.
> 
> In APR/Native this memory is allocated from a new APR memory pool
> that is associated with the connection. When the connection closes,
> the pool is destroyed and the memory freed. All is good.
> 
> In NIO[2]+OpenSSL the per connection memory was allocated from the
> APR memory pool associated with the Connector so the memory was not
> released until the Connector was stopped. The fix is to create a
> pool per connection and use that for the per connection
> allocations. With a fix to do that in place, memory use is now
> broadly static under extended TLS load.

Nice work.

I think you can file this under "stuff we knew might be a problem" and
was the reason we were considering reference-counting, etc. to make
sure we didn't leak *connections*. Here, the connection was
cleaned-up, but some of the associated data wasn't being cleaned from
a shared cache. Do I have that right?

Is there a way, short of bouncing Tomcat, to flush that cache? For
example, bouncing or otherwise re-initializing the connector or
something like that?

- -chris
-----BEGIN PGP SIGNATURE-----
Comment: Using GnuPG with Thunderbird - https://www.enigmail.net/

iQIzBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAlw40t8ACgkQHPApP6U8
pFg4DQ/+Pwyp6P1jMmw+pW8ewxJL0FsI2QjZ439jPVHhBmdO+GmQk23FyhGGKHCb
zj6XtAmLR3h6xGxKpzYVufpIFOhPV6r/ZQ7sb3Mj6dAuI6fN3Apbhc73iHb8qTw8
0TX4yo8fhiXLqa6ImgTqJ56a0hgefbwYeZxPnD35J1hioqDfge4oTdgGCig1lrJi
zOQSVuDiBf2QeY22qGjBJFoFYanGmXnWGLIyOmRJfYWZbBQvc7g1bxl28I6AT4b5
ea/pVu1C0YYNbO7+3Rp+iA2yRY1Db5HR1xn7R8X4tKnbetL20QZL/nCRzgCmtdn/
lFki7HzJRyQQU/kNYNyeAOQsQNSS+C7esWWpt3SqNjX5JzCrOXZ2YxeIFKK9wD3s
yHwqRuHpRhCB22ZQczbBhBmuGEWG2Ovs1gS92DCtS4O135ka1FbruuG9O5j7R60A
fF3EnqCTsqlmkYePhmdNgFmvNiGhbCiOF9wh9L5UaXf5iMAnohCsqBWlTQZdGfQZ
YLt8g4P8PGVrIp3Rgj7r8bKvhgRQekgOqkNIRAf9yC8Rcwfm9ANn2mydjFrEX8fk
Z/hh3b4Z0NYAZ+NGbfg1Cpv7qk5cCX4PV8YqAtm9zNU7O//Cf58de7+la1xuZbn9
FOUtv1aJcNvhuw7IjID+ACMtlIsQAXhckyL1CpP85/exQXIRqN0=
=TLMC
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to