()
| 154 | // Docker file system operations (especially on network shares) can be 10-100ms per operation |
| 155 | // vs <1ms for local file systems, so we need more parallel operations to maintain throughput |
| 156 | function isDockerContainer() { |
| 157 | return require('fs').existsSync('/.dockerenv') || |
| 158 | (require('fs').existsSync('/proc/self/cgroup') && |
| 159 | require('fs').readFileSync('/proc/self/cgroup', 'utf8').includes('docker')); |
| 160 | } |
| 161 | |
| 162 | const MAX_CONCURRENT_OPS = isDockerContainer() ? 100 : 50; // Higher concurrency in Docker |
| 163 |
no outgoing calls
no test coverage detected