jupyter / tmpnb

Creates temporary Jupyter Notebook servers using Docker containers. [DEPRECATED - See BinderHub project]
https://github.com/jupyterhub/binderhub
BSD 3-Clause "New" or "Revised" License
528 stars 123 forks source link

Don't replace containers immediately when draining #199

Closed parente closed 8 years ago

parente commented 8 years ago

Let the next heartbeat task detect that containers are missing and handle their replacement. Replacing immediately leads to chaos when the heartbeat goes off in the middle of the asynchronous drains. For example:

screen shot 2015-12-28 at 9 28 03 pm

Notice the number of containers doubles after a drain on the left side of the graph (before this fix). There's no overshoot after the drain on the right side of the graph (after this fix).

parente commented 8 years ago

@captainsafia @rgbkrk Opened this PR so that I could capture the plot of the behavior somewhere. I'll merge it myself since it's clearly the right fix for the current chaos that can ensue when inopportune heartbeats occur.

rgbkrk commented 8 years ago

:+1: