-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"Resource temporarily unavailable" #1451
Comments
The port is the one from the request line so presumably it's just what is sent. Or the internal port is not using TLS and what is sent is the hostname without a port. In any case it's the URI port not the connection port which may differ based on your environment. If you get |
I'll close this as I don't think the issue is in Cowboy. Please provide more information if it is. |
Ok, just one more question: is there any easy way to debug this in cowboy? (get more information than {:error, "closed"}) |
You can try tracing using |
In seemingly random cases, a websocket connection to cowboy is closed before being able to send anything. I turned on the debug level in nginx reverse proxy to see what is different between a connection working out ok and one that gets closed. I found two differences. These lines were only present in the error case:
But in both cases there were several of the "Resource temporarily unavailable" lines, so I don't know if that's the error.
Also quite often this was not there in the error case:
In general, post even and delete posted event lines were present also in the error case, simply a lot less.
Unfortunately, coming to cowboy now, in the websocket handler I only get these information:
reason:
{:error, "closed"}
request:
%{host: "<hostname>", method: "GET", path: "/", peer: {{127, 0, 0, 1}, 50306}, port: 80, qs: "", scheme: "http", version: :"HTTP/1.1"}
Interestingly, port 80 is neither the original public port (which is 443) nor the internal port that cowboy listens on (4240). I don't know if this could help.
How can I find out (e.g. in the websocket handler) more about the connection dropping / resource not available issue than the reason "closed"?
The text was updated successfully, but these errors were encountered: