-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add activity watching to kernels #1827
Conversation
need to update a few tests to take the added timestamps into account |
I just spotted this in the hackpad. Does it align with the activity tracking added to the kernel gateway a while back? |
last_activity: | ||
type: string | ||
description: | | ||
ISO 8601 timestamp for the last-seen activity on this kernel. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this explicitly be UTC?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They are explicitly timezone-aware, and UTC as an implementation detail. I'll add that detail, though.
@parente I forgot about the KG activity API! This is significantly less than that:
Do you think we should pull in the KG API wholesale, rather than this simpler tracker? What have you used the more detailed information for? |
I think the extra detail was added shotgun style because we didn't have our hands around everything that operators would want to know to make decisions about monitoring and shutting down kernels. At a minimum it'd be good to have the field names and types that are common match at least, even if the API is not 100% the same. The original issue is here: jupyter-server/kernel_gateway#96 @rwhorman probably has more detail on what's used or not at the moment. |
\o/ Can we use this from the hub too, thus taking out last activity tracking from the proxy? |
"name": kernel.kernel_name, | ||
"last_activity": kernel.last_activity, | ||
"execution_state": kernel.execution_state, | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Woo!
This is so excellent to see. |
jupyterhub/jupyterhub#857 is related, talks about adopting a standardized format for exposing white-box metrics (such as last-activity!). |
5d80a46
to
4826fe9
Compare
@parente Nothing conclusive, as we're still experimenting and adjusting our model. |
48e7d07
to
26ec1bc
Compare
Heads up, this has a merge conflict. |
26ec1bc
to
e0a0d28
Compare
Thanks, rebased. |
Hopefully this will make it into 4.4?
…On Fri, Jan 13, 2017 at 6:54 AM, Min RK ***@***.***> wrote:
Thanks, rebased.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#1827 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAB23rAW9fMxFseaT75VW-A6x5fotPLgks5rR5APgaJpZM4KTsKR>
.
--
Yuvi Panda T
http://yuvi.in/blog
|
I'm hoping we might go straight to 5.0, because I'm getting tired of telling people that the new clipboard functionality (#1286) is not available yet. |
What's the status of this? I'm trying to push towards a 5.0 release. Is this going to be mergeable fairly soon, or should we hold it for 5.1? |
adds to kernel REST model: - last_activity: datetime-aware timestamp - execution_state: from last recorded status message
instead of +00:00
add /api/status endpoint for retrieving current status includes - started: start time of the server - last_activity: latest activity across all endpoints - connections: number of current connections - kernels: number of current kernels
because travis is slow
@takluyver fixing it now. I think it's in good shape, I just need to update the new tests to deal with the token changes. |
e0a0d28
to
2a5f8d2
Compare
The js/tree group for py3.5.1 build was stuck on Travis for 2 hours and 45 minutes without starting, so I stopped it and restarted it just now. |
Thanks, @ivanov! Looks all green now. I'm happy with it as-is now, but further reviews and ideas are always welcome. |
🎉 |
adds to kernel REST model:
related: jupyterlab/jupyterlab#1070
next PR: shutdown idle kernels