-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
feat: add gRPC public API #4448
base: master
Are you sure you want to change the base?
Conversation
Hey @chrislusf would love some feedback on this -- started with a very small example, but it should outline the approach. |
This is good. But need to be split into smaller PRs with one change at a time. |
Yeah, this is actually very close to the first PR I'd like to submit for this feature. The real addition here is The approach I wanted to take was to introduce exactly one new API (see I haven't actually written the implementation for the info endpoint I'm proposing (would love any help/pointers in that direction though, what you'd expect it to return, etc). |
Signed-off-by: vados <vados@vadosware.io>
467017c
to
91d5204
Compare
I don’t understand what is the value of having a grpc documentation generator in OpenApi? Is it true that someone will use these and make a lot of their own integrations and external components? So far it looks like a bunch of extra code that needs to be maintained for no one knows. |
Hi @kmlebedev would you mind explaining something about the documentation generator comment you made? My intent was to add an API to enable access to currently CLI-only commands that are available. The documentation-related notes/comments that are in the proto files are due to my (re)using Google shared proto schemas -- that's not strictly necessary but I thought it would be good to reuse.
The intent here was for controlling Administration via CLI is fine for installations that are manually managed, but it is unnecessarily hard to automate, I think.
If there's a different way to perform the administration tasks I wanted to lay out that I missed I'd appreciate a pointer! If CLI is intended to the be the only way to administer seaweed for the forseeable future then that's fine as well. I'm also open to how you think this should be structured, based on the goal of being able to administer |
@t3hmrman I understand the idea and it will probably be useful, but I would like it to be the code used. Can you share your case of using this API in place of the cli? |
Would you mind explaining this bit? I'm not sure I understand.
It's a bit wide-ranging, but I'd like to be able to perform all the CLI operations via API if possible -- right now I basically do this by scripting a sidecar container that runs CLI commands, but ideally I could trigger the actions directly. |
What problem are we solving?
This PR aims to solve multiple problems at the same time:
How are we solving the problem?
The idea is to create a public gRPC API, and use
protoc-gen-openapi
, which supports OpenAPI v3 to generate YAML spec documents.See discussion in #4306 -- though we didn't discuss this particular solution, it seems like a good way to actually get both things done at the same time.
How is the PR tested?
There are no tests for the PR just yet, but what the API should look like is nailed down, tests should be added.
Checks