Catalina & Big Sur: too many open files
I am working as a software developer and I use maven for building a heavy Java project. I am trying to take advantage of maven's abilities to build modules in parallel but am stumped by a problem cause by macOS. Every time I try running parallel builds I run into an error message like this:
java.io.FileNotFoundException: ... (Too many open files)
I have tried setting bigger limits by following the guide here: https://www.macobserver.com/tips/deep-dive/evade-macos-many-open-files-error-pushing-limits/ but it doesn't seem to make a difference at all. Even setting the value to 10 Million causes the same issue, and I am not opening 10 Million files here. My guess is that macOS simply ignores the setting.
This is really super annoying, because instead of 5-10 minutes I have to wait 30-40 minutes for a build.What else can I do except the steps outlined in the article? Anyone around with real in-depth know-how why macOS ignores the limits and how to fix this?