-
Notifications
You must be signed in to change notification settings - Fork 261
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
Proposal: Create a dedicated repository knative/client-pkg
for shared code
#1039
Comments
knative/client-pkg
for shared code
An alternative option would be to include the shared code to |
Let's revive this issue, to resolve cyclic dependencies. There are several options
Only the last option would have the benefit to break the dependency cycle ( This cycle can be resolved in two ways:
Option 1 has the benefit of clear separation as well as self-serving documentation that this is about shared code. The expectation is that people will be very careful when changing any signature within those packages. It would be on the same level as Option 2 has the benefit that features are applied only to a single repo and also the release process is transactional (the mono-repo advantage). The drawback is that it is easy to overlook the external dependants that depend on an internal package. Also it does not resolve the cycle on the repository level. Such a shared repository
My suggestion is to move on with |
This issue is stale because it has been open for 90 days with no |
/remove-lifecycle stale |
Following the original Related docs:
PoC changes:
Repository structureThe
Using the modulesTo consume the
For the plugins, the current PoC has both https://github.com/dsimansk/kn-plugin-source-kafka/blob/pr/multimodule/go.mod#L21-L23 VersioningThe final point to consider is versioning and release process. For the That's seems like the most significant drawback, as we'd need to handle this special case and create seconday tag for public module, here. E.g. for the next release
|
Just to clarify the TOC concerns:
|
I like the idea of reusing existing However, if we'd like to share |
@dsimansk Would this be a submodule in If this is not an issue, I'm fine with adding it to the general |
A JavaEE analogy would be to add AWT or Swing widgets to a server-side WAR dependency. |
Sure, you're right @rhuss. Surprisingly I've kind of mixed The Evan's comments mentioned that concern as well. Indeed we need to find out if it pollutes server-side repositories as well.
|
Sorry for the delay, I'd like to share a bit more points to keep this issue moving.
It wouldn't quiet straightforward with plugin like To summarize the above, there was an concern that using The second code pointer to In conclusion, it seems that best possible solution to address kn's shared code space is a standalone /cc @rhuss updated PTAL |
Let me try to summarize (and verify that I understand correctly):
If this is the case I see two options:
Is this kind of a fair summary @dsimansk ? |
Yes, that's perfect summary @rhuss.
We can definitely start to move those parts with out Serving,Eventing dependency. And re-evaluate the need for standalone |
We don't see a good alternative that's not a lot of work, so let's do this for now and create the dependency chain:
Whereas today it is:
|
(And at some point, it might be worth versioning the serving/eventing APIs / generated code separately from the rest of those repos) |
+1 in favour of adding the repo |
when doing the refactoring, here some ideas how to structure the top-level directory in client-pkg --> #889 (comment) |
/close |
@evankanderson: Closing this issue. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Feature request
I suggest creating a new repository in core knative called
client-pkg
which holds all the shared code that is proposed in #889Use case
The motivation for this change is that this split-off is needed to avoid cyclic dependencies when e.g. plugin code is referring to client support libraries like parsing options in a common way or reusing the way how sinks can be specified.
At the moment those plugins have a dependency back to
knative/client
which is not only an issue from an architectural perspective but has real issues when it comes to inlining of plugins.The text was updated successfully, but these errors were encountered: