binderhub icon indicating copy to clipboard operation
binderhub copied to clipboard

Add ability to enable websocket compression on binder

Open jcoady opened this issue 6 years ago • 4 comments

Websocket compression has been turned off by default in jupyter notebook in an earlier release.

https://github.com/jupyter/notebook/issues/2490

It remains turned off by default in binder, when it used to be enabled in an earlier release of notebook running on binder. Should it remain turned off by default for binder? Should the user be able to turn on websocket compression via jupyter notebook command line options. Currently this is not possible on binder.

NotebookApp.websocket_compression_options : Any Default: None

Set the tornado compression options for websocket connections.

This value will be returned from WebSocketHandler.get_compression_options(). None (default) will disable compression. A dict (even an empty one) will enable compression.

See the tornado docs for WebSocketHandler.get_compression_options for details.

jcoady avatar Dec 21 '17 00:12 jcoady

Should we just enable this by default on binder?

yuvipanda avatar Dec 21 '17 20:12 yuvipanda

Would be good to have @minrk and co chime in who had opinions in jupyter/notebook#2490

betatim avatar Dec 22 '17 01:12 betatim

This is one of those cases where it's hard to say what the logical defaults should be, but it's certainly more likely to be desirable for binder than the notebook itself. We could also conceivably do this at the nginx ingress level, so that we don't suffer the compression cost in the Python server, but do it perhaps in a more performant layer. Anyone want to investigate enabling one-sided websocket compression in nginx ingress?

minrk avatar Jan 02 '18 15:01 minrk

Are there any news on this? I found in local tests that setting websocket_compression_options has not effect on the transferred notebook json anyway.

LustigePerson avatar May 11 '21 11:05 LustigePerson