3 ms·
Where do you host askgolang? I have been working on a go server with websockets too. It seems like websockets cause trouble with Heroku, Google App Engine, and
by bridgeyman 13y ago
Where do you host askgolang? I have been working on a go server with websockets too. It seems like websockets cause trouble with Heroku, Google App Engine, and AWS (if you use the ELB).
- carbocation 13y agoThis is on an instance of the smallest linode available (1024MB). It sits there with all of my other side projects. Load average is negligible despite the HN load: Load average: 0.04 0.06 0.06 I'm using Postgres on the backend and am not using any caching. This is being reverse proxied by nginx (so that I can host multiple golang projects on the same server over port 80).
- carbocation 13y agoAnother thing to mention: I believe websockets use up file descriptors. If you are having issues with websockets despite nominal load, it's worth checking if you're exhausting your file descriptors. I don't know about the architecture of Heroku, GAE, or AWS w/ ELB in terms of supporting the HTTP 1.1 Upgrade request to websockets. Perhaps they all use a reverse proxy that doesn't pass along the Upgrade request? Even nginx didn't support this before ~1.3.13.
- ismarc 13y agoI've been working with websockets on AWS for some data intensive bi-directional communication and haven't had any issues with it...However, I don't have it set up as an HTTP listener, I have it set to TCP 80 -> TCP <mylocalport>. The server architecture doesn't matter if a user drifts backend hosts if their connection drops and reestablishes (no stickiness needed). I haven't tried it under the HTTPS setting for SSL connections yet, but if there's flakiness, I know I can just terminate SSL on the ec2 instances instead of the ELB.