Skip to content

Jupyverse Modularity - Workflow to add "server extension" ? #305

@oscar6echo

Description

@oscar6echo

I understand from the doc and conversation that Jupyverse is modular by design 👍

So I understand it should be feasible to add endpoints, aka server extensions. aka asphalt plugins (?).
Do such plugins need be in the jupyverse repo ? Or is there a way to add one by config before lauching the server ?

More generally is there a short demo/tutorial on how to create such a custom plugin (hello world with maybe some use of shared resources) ?

I have the following generic idea in mind:

  • A Jupyterlab extension collects some data in the browser - say a token or user input data in extension frontend.
  • The labextension sends it to a "POST" custom jupyverse endpoint/plugin
  • This plugin saves it on the disk in a specific folder
  • Then the kernel can read it from this folder

Similarly the data flow can go the other way if the plugin has a corresponding "GET" endpoint availalble to the labextension.

This would be a relatively generic way to pass data from frontend to kernel and back - which is a frequent use case - and it would be easy to customize.

NOTE: In the case of Jupyterlite, the facility to exchange data between frontend and kernel is the IndexedDB - accessible in read-write from both kernel and frontend 👍


Side question:
In the repo there is a lot of "fps" but there is mention (#277) that "fps" has been replaced by asphalt.
However there are still "fps-xyz" imports all over the place including after this mention.
Why ? migration on going? renaming not done ? Just to understand.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions