kubernetes-sigs / kubebuilder-declarative-pattern

A toolkit for building declarative operators with kubebuilder
Apache License 2.0
254 stars 84 forks source link

Proposal to move KB declarative pattern to an external plugin #293

Open varshaprasad96 opened 1 year ago

varshaprasad96 commented 1 year ago

What would you like to be added: This is a follow up based on the conversation in https://github.com/kubernetes-sigs/kubebuilder-declarative-pattern/pull/291#issuecomment-1381123158. With the introduction of Phase 2 (out-of-tree external plugins) in Kubebuilder, we now have the flexibility to extend Kubebuilder and build/release any plugin independently outside the KB project. This paves way for smoother version upgrades across projects and eases the maintenance effort.

Given this, we would like to know if we can go ahead with moving the Kubebuilder-declarative-pattern out of Kubebuilder, and building an external plugin for the same. The immediate benefits of this are:

This would decouple the inter-dependency of both the projects.

varshaprasad96 commented 1 year ago

cc: @camilamacedo86

justinsb commented 1 year ago

As discussed in controller-runtime office hours, this sounds like a good move for both projects - it's exciting that external plugins are now supported. If anyone wants to work on this they are very welcome to - please just comment here. Otherwise I'll likely tackle it if/when I find time!

em-r commented 1 year ago

@justinsb I'm interested in working on this, however, I'm still new to the declarative pattern, would that be okay?

justinsb commented 1 year ago

Of course @em-r - any help would be greatly appreciated. I'm not familiar with the external plugin architecture, but maybe between us we can figure it out :-)

A good way to proceed might be to try copying the plugin code into this repository, and seeing what breaks, and maybe send a WIP PR to enable collaboration and discussion if there's any issues. But happy to work however best suits you!

em-r commented 1 year ago

Thank you @justinsb Indeed, a WIP PR is definitely a good way to move forward, I'll go ahead and assign the ticket to myself, and send a WIP PR once I copy the plugin code to this repository.

/assign

camilamacedo86 commented 1 year ago

Hi @em-r,

@rashmigottipati and @brycecr are those that who worked out mostly in the plugin phase 2 (external plugins API) code implementation. Also, feel free to ping in the kubebuilder channel and raise questions or issues. We will try to help us much as possible. If we do not know something we can find out :-)

Thank you for looking on that. That is a terrific nice project/initiative that will help a lot !!!

em-r commented 1 year ago

@camilamacedo86 - sounds great, I'll definitely reach out in kubebuilder channel, thank you for the support!