[logback-dev] ExecutorServiceUtil's use of Executors.defaultThreadFactory()

Paul Summermatter paulrs at mac.com
Mon Feb 28 17:10:06 CET 2022


RE: Logback 1.2.10

All,

	We ran into a problem last week in a production environment where there were thousands of idle thread pool threads all with the name 'pool-NNN-thread'. We have been unable to reproduce the situation in non-prod, but we have discovered that logback makes use of thread pools but does not create a custom thread factory to name the threads as belonging to/initiated by logback. TimeBasedArchiveRemover is one example that makes use of a scheduled executor backed by Executors.defaultThreadFactory() (which provides only generic names for created threads). It would be very helpful if logback stopped using this factory and instead created its own, providing names for the threads that clearly indicate their creation was triggered by logback, e.g., "logback-NNN-thread". Is this something that has been previously discussed? Do folks agree that this would be useful? If so, should I file an enhancement request via JIRA? Any feedback or guidance would be appreciated.

Regards,
Paul


More information about the logback-dev mailing list