Implement automatic monitoring of the iPython Notebook Server
Turribeach
Dataiku DSS Core Designer, Neuron, Dataiku DSS Adv Designer, Registered, Neuron 2023 Posts: 2,090 Neuron
Every few months we get an issue with the iPython Notebook Server that stops responding. Dataiku already provides process monitoring for the ipython process via supervisord. However this doesn't cover the case when the iPython process stops responding. This idea is to have Dataiku perform checks on the ipython server process to make sure it's responsive and if it is not then restart the ipython process.
Tagged:
Comments
-
Hi,
You can regularly call the https://developer.dataiku.com/latest/api-reference/python/client.html#dataikuapi.DSSClient.list_running_notebooks method.
In your specific issue case, it would not respond, so you need to add a timeout and react on exception:
import dataiku client = dataiku.api_client() import functools client._session.request = functools.partial(client._session.request, timeout=10) client.list_running_notebooks()