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

[quarkus] in JVM mode we should no restrict the languages we can use #1154

Closed
lburgazzoli opened this issue Dec 18, 2019 · 0 comments · Fixed by #1161
Closed

[quarkus] in JVM mode we should no restrict the languages we can use #1154

lburgazzoli opened this issue Dec 18, 2019 · 0 comments · Fixed by #1161
Assignees
Milestone

Comments

@lburgazzoli
Copy link
Contributor

func (t *quarkusTrait) addRuntimeDependencies(e *Environment) error {
dependencies := &e.Integration.Status.Dependencies
for _, s := range e.Integration.Sources() {
meta := metadata.Extract(e.CamelCatalog, s)
switch language := s.InferLanguage(); language {
case v1alpha1.LanguageYaml:
addRuntimeDependency("camel-k-quarkus-loader-yaml", dependencies)
case v1alpha1.LanguageXML:
addRuntimeDependency("camel-k-quarkus-loader-xml", dependencies)
case v1alpha1.LanguageJavaScript:
addRuntimeDependency("camel-k-quarkus-loader-js", dependencies)
default:
return fmt.Errorf("unsupported language for Quarkus runtime: %s", language)
}
if strings.HasPrefix(s.Loader, "knative-source") {
addRuntimeDependency("camel-k-quarkus-loader-knative", dependencies)
addRuntimeDependency("camel-k-quarkus-knative", dependencies)
}
addRuntimeDependency("camel-k-runtime-quarkus", dependencies)
for _, d := range meta.Dependencies.List() {
util.StringSliceUniqueAdd(dependencies, d)
}
}
return nil
}

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

Successfully merging a pull request may close this issue.

2 participants