Metadata-Version: 2.1
Name: pvlink
Version: 0.2.2
Summary: ParaView-Web RemoteRenderer in Jupyter
Home-page: https://gitlab.version.fz-juelich.de/jupyter4jsc/j4j_extras/pvlink
Author: Juelich Supercomputing Centre (JSC)
Author-email: a.grosch@fz-juelich.de
License: BSD
Keywords: Jupyter,Widgets,IPython
Platform: Linux
Platform: Mac OS X
Platform: Windows
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: BSD License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Framework :: Jupyter
Description-Content-Type: text/markdown
Requires-Dist: ipywidgets (>=7.0.0)
Requires-Dist: psutil (>=4.0.0)
Requires-Dist: twisted (>=19.2.1)
Requires-Dist: wslink (>=0.1.13)
Provides-Extra: docs
Requires-Dist: sphinx (>=1.5) ; extra == 'docs'
Requires-Dist: recommonmark ; extra == 'docs'
Requires-Dist: sphinx-rtd-theme ; extra == 'docs'
Requires-Dist: nbsphinx (<0.4.0,>=0.2.13) ; extra == 'docs'
Requires-Dist: jupyter-sphinx ; extra == 'docs'
Requires-Dist: nbsphinx-link ; extra == 'docs'
Requires-Dist: pytest-check-links ; extra == 'docs'
Requires-Dist: pypandoc ; extra == 'docs'
Provides-Extra: examples
Provides-Extra: test
Requires-Dist: pytest (>=3.6) ; extra == 'test'
Requires-Dist: pytest-cov ; extra == 'test'
Requires-Dist: nbval ; extra == 'test'

# pvlink

ParaView-Web RemoteRenderer in Jupyter

## Installation

You can install pvlink using `pip` and `jupyter labextension install`:

```bash
pip install pvlink
jupyter labextension install pvlink
```

If you are using Jupyter Notebook 5.2 or earlier, you may also need to enable
the nbextension:
```bash
jupyter nbextension enable --py [--sys-prefix|--user|--system] pvlink
```


## Usage
For examples see the [example notebook](examples/Examples.ipynb).  
The RemoteRenderer additionally requires the `paraview.simple` and `paraview.web modules`.


## Jupyter Proxy Setup (using nginx)

To enable streaming these settings need to be set, in the nginx config file for Jupyter (for example: in /etc/nginx/conf.d/):

```
# top-level http config for websocket headers
# If Upgrade is defined, Connection = upgrade
# If Upgrade is empty, Connection = close
map $http_upgrade $connection_upgrade {
    default upgrade;
    ''      close;
}

... location ... {
   ...
           # websocket headers
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection $connection_upgrade;
  ...
}
```

An unused stream is automatically disconnected by nginx, after `proxy_read_timeout`'s seconds are exceeded. The default value of 60s is reached quite fast, therefore it is recommended to increase this value. 
For example:
```
# HTTPS server to handle JupyterHub
server {
    listen 443 ssl;
    ...
    proxy_read_timeout 3600s;
    ...
```


