-
-
Notifications
You must be signed in to change notification settings - Fork 322
What you see is what you REST #1052
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
base: main
Are you sure you want to change the base?
Conversation
|
Awesome! With this, one could build powerful micro-services with very little effort. Thinking about use cases e.g. in financial industry, it would be important to protect the notebooks, so that the user of the API cannot modify the notebook (i.e. the running microservice) itself.
Variables not explicitly defined should not be accessible from the API. Maybe the default could be to listen / publish all variables, unless
|
|
Your first point makes a lot of sense! Not only would explicitly defining which variables users can change via the API (in production/deployment settings) enhance notebook protection, but it would also allow for further optimization since execution plans can be computed beforehand and only once. For your second point, I was thinking about adding a configuration option which would allow users to run Pluto in an "API only" mode which would disable notebook editing and access features, restricting use to the API only. Perhaps this mode will also default to only serving "endpoints" defined by the |
src/Configuration.jl
Outdated
| disable_writing_notebook_files::Bool = false | ||
| notebook::Union{Nothing,String} = nothing | ||
| simulated_lag::Real=0.0 | ||
| enable_rest::Bool = false |
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.
Is there a significant performance impact of having the REST API enabled?
Otherwise, I would suggest to enable it as default.
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.
There isn't any performance impact, but right now there are zero security features at all. It's probably not a big deal though, so I will update that
|
The client functionality is now in a separate package https://github.com/JuliaPluto/PlutoRESTClient.jl. I haven't published it nor removed the client code from the PR yet though |
|
@ctrekker frontend tests are fixed on |
Watch the presentation!
https://www.youtube.com/watch?v=xsxJt4prFG4
Try it out!