jupyterhub / binderhub

Run your code in the cloud, with technology so advanced, it feels like magic!
https://binderhub.readthedocs.io
BSD 3-Clause "New" or "Revised" License
2.57k stars 390 forks source link

eventsource continues launching more containers if left open #317

Open rgbkrk opened 6 years ago

rgbkrk commented 6 years ago

If you leave the eventsource open after "ready" it continues launching more

Reproduction steps:

es = new window.EventSource('https://mybinder.org/build/gh/nteract/vdom/master')
es.onmessage = msg => console.log(msg)

Not a crazy deal for me, I just happened to notice while hitting the event source API directly. My current code does a .close appropriately. Figured this should probably be cleaned up though.

choldgraf commented 6 years ago

I think we just got burned by this with the nbinteract repository. @rgbkrk did you figure out a way to work around this from your side of things?

rgbkrk commented 6 years ago

Yeah, we .close() the event source after we get a freshly baked container. It wasn't an issue at the time, it just smelled like a likely operational problem waiting to happen.

choldgraf commented 6 years ago

it just smelled like a likely operational problem waiting to happen.

manics commented 3 years ago

Is this still a problem?