Open kencrimavx opened 2 years ago
Is it actually 11, or are you reporting that number because the default report comes out once when the number exceeds a default threshold of 10?
It's specifically 11, I believe. We saw 11/transport in our prod env, so we spun up an additional instance with only Winston installed to validate.
🔎 Search Terms
File Descriptors, Linux, Threads, Workers
The problem
WinstonJS Version: 3.3.3 NodeJS Version: 14.16.0 Linux Distribution: Ubuntu 18.04.3 LTS (Bionic Beaver)
When we instantiate a logger on an OSX machine, we see one file descriptor per transport, as expected, but in Linux environments, we're seeing 11 per transport. We're curious whether it's an issue on our end, or a part of Winston's implementation. Our use case involves a large number of worker threads being spun up, each with its own instance of Winston, so the multiplicative file descriptors presents something of an issue for us. Is there anything that can be done to configure this?
What version of Winston presents the issue?
3.3.3
What version of Node are you using?
14.16.0
If this worked in a previous version of Winston, which was it?
No response
Minimum Working Example
Logger code:
LSOF Command
lsof | grep "testlog" | wc -l // 11 Results once './logger' has been required
We ran it on an AWS EC2 T2 Micro, if that makes any difference.
Additional information
No response