eclipse-vertx / vert.x

Vert.x is a tool-kit for building reactive applications on the JVM
http://vertx.io
Other
14.26k stars 2.07k forks source link

Avoid DnsNameResolver FastThreadLocal query server address stream implementation #5187

Closed vietj closed 5 months ago

vietj commented 5 months ago

DnsClient implementation relies on building multiple instances of DnsNameResolver which by default instantiate a FastThreadLocal query server address stream. As side effect this expand the FastThreadLocal entry size which can be considered as a leak.

DnsNameResolverBuilder now accepts a query server address stream instance to override the default FastThreadLocal instance, to avoid this (slow but steady) leak.