Hi! I am running 3D printing software Fluidd behind CF proxy and I am experiencing websockets drops while streaming webcam.
I thought it might be Fluidd bug so I opened an issue here: https://github.com/fluidd-core/fluidd/issues/933 but after further investigation I found that it happens only while accessing through CF proxy.
I tried it through unproxied domain and I haven’t experienced this.
When I don’t have webcam enabled, everything works fine, but once I enable webcam stream, after few seconds everything stops - the currently loading frame fails to load and WS stops completely until Fluidd restarts itself due to WS not working.
You can see here network activity when frame fails to load: https://user-images.githubusercontent.com/13891066/199123940-552020d2-e18f-4cbd-8bf9-0ee0d3e18696.png
and here websocket communication - the first row is last message before drop: https://user-images.githubusercontent.com/13891066/200000743-abee4341-b1e9-41e7-88a2-b7222808db97.jpg
Do you have any idea what might be causing this? Is it maybe some setting?
I thought CF might be caching all frames and there’s too much of them so it causes problem, so I tried to set cache bypass for the webcam stream like this: (http.host eq "my.domain.tld" and http.request.uri.path eq "/webcam")
but if I used it correctly, it didn’t help.
Thank you for answers and sorry for late reply, of course, just when I posted it I found more ideas to diagnose
When I said “it works unproxied”, I realized it’s not unproxied, it’s just pointed directly to my LAN IP.
So I tried to make unproxied DNS record pointed at my public IP and… it crashed too. That means CF proxy isn’t the problem here.
I have two ISPs at home and I’m load balancing between them, both in CF (so my requests are not going just to one IP) and in router (so I have double the internet speed in some cases).
I was thinking if this maybe isn’t the problem, like switching between IPs and this would confuse browser or something. Because I know I had this problem with FTP and FileZilla - when I logged in with one IP and started manipulating files, those requests coming from the other IP failed.
So I tried to point subdomain directly to one of my public IPs and it still was happening. I tried the second one and again, it crashed.
One more thing I noticed is when the frame stops loading and I open completely different website hosted on my domain, it’s not working too for those 10 - 20 seconds.
This means one 3 things:
something is wrong with my routing from WAN
or with both ISPs
or with Traefik reverse proxy I use
I have already checked debug logs of Traefik and there was nothing unusual in it. Also as I said, DNS record pointed to my local Traefik IP works without problem, this 98 % means that Traefik isn’t the problem here.