-
Notifications
You must be signed in to change notification settings - Fork 345
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
fix(#3896): Fix dependency inspector supporting property placeholders #3901
Conversation
FYI @tadayosi |
Thanks a lot Christoph for taking care of this issue! As already commented in the review, I don't think checking only
This kamelet has
|
Thinking a bit further, what should we really do with the use of Kamelet placeholders in terms of the dependency resolution? The original intention why we've added a stricter component dependency validation is to improve UX in case of wrong components used in the user's integration, so that Camel K can give users early feedback on possible misconfigurations in user side. Since it is related only to Kamelets and Kamelets already have an explicitly defined set of dependencies, so dependency resolution is not a problem in this case, right? Is it just fine to skip it silently and everything should work fine? |
I wonder if throwing an error at this state when the uri does not resolve to a component in the Catalog is the right thing to do in general. Using placeholders in the uri may be only one scenario where throwing an error because of this is inappropriate. What about uri that for some other reason does not resolve to a component that we know. We also support jitpack dependencies and custom Maven repositories that might ship libraries with custom components that are not known to the Catalog. All these will raise the error here or am I missing something? |
I think it's a good question, and I raised the same at #3449 (comment). In Camel, users can even change the scheme name for the existing components. At that time, I took that Camel K doesn't allow such use cases like extending with their own components or simply renaming the components. We assume every valid component should be present in the Camel Quarkus and Catalog. But we can rethink about the assumption and explore what level of flexibility Camel K can provide to users regarding extensibility of components. Can you think of any other cases where throwing an error at this state might cause issues? |
And yes, what I've implemented for 1.11.0 might be a bit too stricter and less flexible when handling dependencies. Possibly we should move the dependency check at a later stage. We can revisit it as well. |
8ea51a5
to
6a0edcb
Compare
…olders Do not raise errors during dependency inspection when using property placeholders in URIs. Fixes http-sink Kamelet which uses {{url}} as endpoint URI
6a0edcb
to
f9cd7c9
Compare
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.
Looks great. Thanks @christophd !
The CI job failing because of
Does that sound familiar to somebody? Could someone please rerun the failing CI job so we make sure this has been a temp hiccup |
Re-running it. |
@squakez thank you! YAY! all green! |
Do not raise errors during dependency inspection when using property placeholders in toURI. Fixes http-sink Kamelet
Fixes #3896