Skip to content

Jetty 12: leak tracking of Pool entries #9148

@sbordet

Description

@sbordet

Jetty version(s)
12

Enhancement Description
Class Pool is now used for both ByteBuffer and client-side Connection pooling: it is much faster and better than previous implementations, but has the drawback that it is sensitive to leaking if Pool entries are not released back to the Pool.

For this reason, we need a leak detection component.
However, differently from LeakDetector (that should be removed), it cannot rely on GC because Pool always keeps a strong reference to the pooled entry.

The proposed solution is to use a time-based leak detection: if an acquired entry is not released back to the Pool within a certain period of time, or at a specific moment, then report it as leaked.

Classes to be removed:
LeakDetector
LeakTrackingByteBufferPool
LeakTrackingConnectionPool

Metadata

Metadata

Assignees

Type

No type

Projects

Relationships

None yet

Development

No branches or pull requests

Issue actions