Open omnipresent07 opened 4 years ago
Hitting a blocker with Websockets:
ws://
ws://
from a secure domain https://
wss://
but the connection immediate fails, so this may not be supported by the Platform?I've been investigating setting the authorization header as part of the websocket connection request but it does not appear to be supported by web browsers.
Options
onOpen
https://stackoverflow.com/a/59796300
protocol
parameter of the websocket to send the auth token https://stackoverflow.com/a/44314168
1006
proxy_read_timeout
and proxy_send_timeout
extended in NGINX, issue persistshttp://nginx.org/en/docs/http/websocket.html https://www.nginx.com/blog/websocket-nginx/ https://github.com/grafana/grafana/issues/36929#issuecomment-954706911
upgrade
requests, issue persistsset token with cookie to authenticate already works without changes to the backend; so the first option works, the cookie name is X-Authorization-Token
, so below snippet will work before constructing the ws connection
document.cookie = `X-Authorization-Token=${AccessToken.get()}; path=/;`
This associate Github issue was closed on HMDA Platform but it's not clear if anything was done to correct the underlying problem. This should be tested/validated as part of pre-rollout activities.
Short description explaining the high-level reason for the new issue.
The backend API exposes websockets now as part of this PR https://github.com/cfpb/hmda-platform/pull/3779 . The front end can open a websocket at the time of the upload to better track when the submission is completed.