Skip to content
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

[Feature] Add support for adding plugin details in client generator #1690

Open
YourTechBud opened this issue Jun 17, 2023 · 0 comments
Open
Assignees
Labels
enhancement New feature or request p/medium
Milestone

Comments

@YourTechBud
Copy link
Collaborator

YourTechBud commented Jun 17, 2023

The problem faced currently?

The worker sdk needs to manually provider the plugin details they wish to apply to their handlers. This leads to typos

How can we solve it?

  • spacectl client generate command will fetch the list of plugins from SC (Ref: [Feature] Add endpoint to return a list of available plugins. #1689)
  • Each driver to implement a method named GeneratePlugins()
  • The output of GeneratePlugins() will be an exposed struct named Plugins with a member function for each plugin registered in SC.
    • The member function will be named as `<upperCamelCase(driver)><upperCamelCase(name)>
    • Example: if driver=opa; name=is-admin then name of function will be OpaIsAdmin()
    • Each function will return a struct named PluginDetails which implements a PluginImpl interface. This interface will have 3 methods:
      • Name() -> name of plugin
      • Driver() -> driver of plugin
      • Params() -> type any (will always be nil for now)
  • The output of this will be in a separate file named plugins.go
  • We want this support only for the golang and typescript drivers

If you want this feature to be implemented, give it a thumbs up reaction, so that we can determine which features are important to you.
👍

@YourTechBud YourTechBud added the enhancement New feature or request label Jun 17, 2023
@YourTechBud YourTechBud added this to the v0.22.0 milestone Jun 17, 2023
@YourTechBud YourTechBud moved this to 🔖 Ready in @SpaceCloudIO's Backlog Jun 17, 2023
@YourTechBud YourTechBud moved this from 🔖 Ready to 📋 Backlog in @SpaceCloudIO's Backlog Jun 17, 2023
@YourTechBud YourTechBud moved this from 📋 Backlog to 🔖 Ready in @SpaceCloudIO's Backlog Jun 17, 2023
@YourTechBud YourTechBud moved this from 🔖 Ready to 📋 Backlog in @SpaceCloudIO's Backlog Jun 17, 2023
@YourTechBud YourTechBud moved this from 📋 Backlog to 🏗 In progress in @SpaceCloudIO's Backlog Jul 8, 2023
@YourTechBud YourTechBud moved this from 🏗 In progress to 👀 In review in @SpaceCloudIO's Backlog Sep 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request p/medium
Projects
Status: 👀 In review
Development

No branches or pull requests

2 participants