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

Log a warn message once the component used has not a quarkus extension #3127

Closed
aboucham opened this issue Mar 17, 2022 · 12 comments · Fixed by #3640
Closed

Log a warn message once the component used has not a quarkus extension #3127

aboucham opened this issue Mar 17, 2022 · 12 comments · Fixed by #3640
Assignees
Labels
Milestone

Comments

@aboucham
Copy link

Log a warn message once the component used has not a quarkus extension.

For the moment, we see only the following lines in the operator log:

{"level":"info","ts":1647441251.3206353,"logger":"camel-k.maven.build","msg":"[INFO] Scanning for projects..."}
{"level":"info","ts":1647441252.2915804,"logger":"camel-k.maven.build","msg":"[ERROR] [ERROR] Some problems were encountered while processing the POMs:"}
{"level":"info","ts":1647441252.2962983,"logger":"camel-k.maven.build","msg":"[ERROR] 'dependencies.dependency.version' for org.apache.camel:camel-aws-starter:jar is missing. @ line 64, column 17"}
{"level":"info","ts":1647441252.3024638,"logger":"camel-k.maven.build","msg":"[ERROR] 'dependencies.dependency.version' for org.apache.camel:camel-http4:jar is missing. @ line 72, column 17"}
{"level":"info","ts":1647441252.3025827,"logger":"camel-k.maven.build","msg":" @ "}
{"level":"info","ts":1647441252.3131278,"logger":"camel-k.maven.build","msg":"[ERROR] The build could not read 1 project -> [Help 1]"}
@squakez squakez added kind/feature New feature or request good first issue Does not require full understanding of the codebase labels Mar 17, 2022
@parul5sahoo
Copy link
Contributor

Hey @aboucham, I would like to work on this issue, although I am a beginner, this seems like a fairly simpler solution to work around.

@squakez
Copy link
Contributor

squakez commented Mar 28, 2022

Just assigned to you. Please, let us know if you need any help.

@parul5sahoo
Copy link
Contributor

yes, it would be great if you can share some resources to refer, sort of code walkthroughs or any resource that shall be useful in giving a headstart.

@squakez
Copy link
Contributor

squakez commented Mar 30, 2022

I think some possible way to fix it is to scan the log provided from the builder. However, I'm just noticing a more general scenario could be covered by #3149. @phantomjinx can you please confirm that with the work you're doing that you are covering also the error mentioned in this issue?

@phantomjinx
Copy link
Contributor

@squakez
No. I don't believe it is. I think this refers to adding more logging messages whereas #3149 seeks to grab the quarkus logging if the command immediately fails.

@squakez
Copy link
Contributor

squakez commented Mar 30, 2022

Thanks @phantomjinx. I was trying to think a simple approach to parse the log, capture the kind of error and bubble up into the Builder error conditions. However, for the sake of simplicity, I think we can start inspecting the content of the maven log line here, and if it complains of a camel dependency missing a version (such as in the issue description) we can add an additional line of log explaining that likely, the component has not a Camel Quarkus extension valid. @parul5sahoo I hope that can give you some hint on how to proceed.

@jamesnetherton
Copy link
Contributor

Can't we verify the validity of any requested camel artifacts by attempting to look them up in the catalog, instead of parsing logs?

@squakez
Copy link
Contributor

squakez commented Mar 30, 2022

Can't we verify the validity of any requested camel artifacts by attempting to look them up in the catalog, instead of parsing logs?

Yeah, it's a very good idea. Probably we can extend the functions in https://github.com/apache/camel-k/blob/main/pkg/util/camel/camel_dependencies.go to lookup into the catalog, otherwise returning an error. If we go through this path, I am not sure if it's still suitable as a "good first issue" for contributors as it requires a bit of knowledge of the project.

@parul5sahoo
Copy link
Contributor

Incase the issue would need a bit of investing, I would like to collaborate on this issue with an experienced collaborator if that's possible..

@squakez
Copy link
Contributor

squakez commented Mar 31, 2022

Incase the issue would need a bit of investing, I would like to collaborate on this issue with an experienced collaborator if that's possible..

Don't worry. Please, look for some other issue that you'd like to work on. I'm unassigning for now.

@squakez squakez removed the good first issue Does not require full understanding of the codebase label Mar 31, 2022
@github-actions
Copy link
Contributor

This issue has been automatically marked as stale due to 90 days of inactivity.
It will be closed if no further activity occurs within 15 days.
If you think that’s incorrect or the issue should never stale, please simply write any comment.
Thanks for your contributions!

@tadayosi
Copy link
Member

It's still a nice-to-have and shouldn't be stale.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
6 participants