swagger-api / validator-badge

Validate your Swagger JSON/YAML today!
http://swagger.io
Apache License 2.0
210 stars 85 forks source link

Too Many Open Files #138

Open nickdgriffin opened 5 years ago

nickdgriffin commented 5 years ago

I'm making use of the Docker image for v1.0.5, and am deploying to Kubernetes, and every once in a while the validator spams out a stream of log messages about there being too many open files and then crashes.

Example:

2019-02-14 15:46:42.635:WARN:oejs.ServerConnector:qtp1791741888-16-acceptor-0@18e5ff1-ServerConnector@56ac7bf4{HTTP/1.1}{0.0.0.0:8080}: 
java.io.IOException: Too many open files
        at sun.nio.ch.ServerSocketChannelImpl.accept0(Native Method)
        at sun.nio.ch.ServerSocketChannelImpl.accept(ServerSocketChannelImpl.java:422)
        at sun.nio.ch.ServerSocketChannelImpl.accept(ServerSocketChannelImpl.java:250)
        at org.eclipse.jetty.server.ServerConnector.accept(ServerConnector.java:377)
        at org.eclipse.jetty.server.AbstractConnector$Acceptor.run(AbstractConnector.java:500)
        at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635)
        at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555)
        at java.lang.Thread.run(Thread.java:748)

We are running a bunch of our own applications that are far more active than the validator is and they never report issues with too many open files, so I don't think it's an issue with the configuration of the Docker Engine.

Looking inside the container, at this particular point in time, I can see that "/validator/webapp/WEB-INF/classes/error.png" is open over 44k times - which doesn't seem right.