-
Notifications
You must be signed in to change notification settings - Fork 311
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
How *should* other applications interface with jupyter server? #29
Comments
My inclination is that we'd follow the model used by JupyterLab for all server applications (which are a subset of server extensions): they can function either as Application or purely as an extension. We can probably step back and rethink how this was done in jlab and how it would apply to NotebookApp as well. |
@Zsailer Thank you for opening this discussion! Although I'm not one of the targeted responders, I would like to add my two cents (primarily because I have a vested interest in how this proceeds). I'm not familiar with server extensions outside of NB2KG. This extension essentially configures various classes that override kernel management and proxies the kernel management to a remote Kernel Gateway. This enables the ability to separate notebooks from kernels and, with Enterprise Gateway, the ability to have those kernels launched across managed clusters. I'm not sure if this extension would be considered an example of a "server extension" in the new jupyter_server sense. However, applications like Enterprise Gateway (and Kernel Gateway upon which EG itself is built), could only have achieved the functionality they provide by subclassing various pieces of the "server". These are true server-side applications that fundamentally change the "behavior" of that particular server instance by essentially creating a Kernel As A Service model while supporting a large set of options pertaining to the functionality they provide. As a result, I suspect you'd actually want a different application in this case, but one built on the core framework that is jupyter_server. I suppose one could always spin any kind of functionality in terms of "extensions", but I'm hoping that jupyter_server continues to provide the ability to alter the class hierarchy in order to maximize extensibility. I'd love to help out wherever possible on this project especially in the area of kernel management. |
Hi @kevin-bates Thanks for joining the conversation! This was helpful. I agree with @kevin-bates and @blink1073. Subclassing the ServerApp makes the most sense, specifically, for projects that change the server behavior. It also helps with code maintenance on sub-projects, configuration sanity, etc. I am thinking we should make the Practically, I think this means:
|
For reference, here is a list of projects that that might benefit from this split: |
Although at a lower level, @takluyver's jupyter_kernel_mgmt (see PR 4170) should probably be taken into consideration. Since there appears to be building momentum for changes in the server-side kernel and kernelspec management arena, I'm wondering if this wouldn't be a good topic for a community workshop or some set of meetings so we can all get on the same page. If others agree, I would love to participate and represent the gateways. |
Added jupyter_kernel_mgmt to the list! Thanks! |
@kevin-bates I'm not sure if there enough people to pull together for a community meet-up. We'd need 12-24 people. Do you have specific people in mind? |
I see - I didn't realize the workshops were that large. I'd like to make sure we're on the same page for future direction to avoid sibling projects like the gateways from getting orphaned because the new approaches didn't take them into consideration. I'm relatively new to Jupyter (and Open Source in general), so I'm not sure how to "keep tabs" or proactively contribute - other than watching dozens of repos, monitoring the forums, and filtering on items of interest (in particular, the future direction of kernel management). |
Hi both! I just wanted to pop in and encourage you both to submit a community workshop application. You don't need to have all of your attendees figured out ahead of time, and you can get up to a dozen folks in most geographical locations fairly quickly. |
Thanks, @ivanov! Okay, you convinced me ;) I'm up for it. How about you @kevin-bates? Would you be interested in co-organizing a meetup together? |
@Zsailer - just to make sure. Are you referring to a workshop, per the blog I referenced previously, or a single-day meetup? I'm assuming the former. One of my colleagues on EG - Luciano (@lresende) - has volunteered to help out with organization of a workshop although I'm happy to help out in other capacities. I'm hoping we can make this happen. |
@kevin-bates - yes, I was referring to the 2-3 day workshops described in the blog (funded by Bloomberg). Thank you for suggesting the idea! Hello @lresende! Thank you for volunteering to help organize a meetup. I think the first thing to do is submit a proposal to the Jupyter steering council. Do you have time today/tomorrow for a video call to discuss details? |
@Zsailer I am available to chat today or tomorrow (pst timezone), I am also working on a draft proposal based on the blog link. Let me reach out to you via e-mail to schedule something |
Oh, fantastic! Thank you for heading this. I look forward to chatting this afternoon. |
Closing this issue. We just finished a Jupyter Server Workshop! We'll be sharing a bunch of updates from this workshop very soon. |
Pinging @SylvainCorlay, @blink1073 and @jasongrout.
I'm hoping this discussion will bring me up to speed on everyone's thoughts/plans, so I apologize for anything that I say that's naive 😆
Essentially, I'm asking how should applications like the class Notebook, jupyterlab, etc. interface with the server? (I realize there's a big discussion that needs to happen about how we handle configuration, especially in a backward-compatible way. For now, I'm ignoring that question and just asking what is the end goal for jupyter_server).
1. Everything is a server extension
One approach is that each application is loaded through the server extension logic.
Each extension is added to the server extension list in the server config. The server has one entry point
jupyter server
(though we'd need to add shims for backward compatibility). The server+webapp launch and load the server extensions (i.e. the classic notebook, lab, etc.). Each extension loads it's specific configuration and these additional settings are added after the server and webapp are created. I'm not sure how we'd handle extension configurations from the CLI (will likely new traitlets logic...).In this scenario, the jupyter
ServerApp
andWebApp
are a general applications that expose API's to the backend jupyter services. Jupyter lab and the notebook are (first class) external applications that interface with server. As an example, here is a branch of the classic notebook that uses the current server extension logic to load the notebook.2. External apps subclass the server+webapp
Every external application subclass the jupyter
ServerApp
andWebApp
and add/update application specific configurations to these classes (I think this is whatjupyterlab_server
does?).In this case, each application comes with their own server, webapp, configuration template, and entry-point.
The text was updated successfully, but these errors were encountered: