lburgazzoli/gradle-karaf-plugin

Example code doesn't seem to work

Closed this issue · 4 comments

Sorry if this isn't really a bug, but there isn't a lot of documentation. I tried using the example, and I got "Could not find matching constructor for: com.github.lburgazzoli.gradle.plugin.karaf.features.model.FeatureDescriptor(org.gradle.api.internal.project.DefaultProject_Decorated)"

It looks like that class's constructor takes a project, so I tried doing "feature (project(':lparent:web:karaf-features:bundles-feature'))", but that didn't work either.

Yeah, documentation is something I should work on soon.
Can you post an example showing the problem ?

karaf {
I do:

features {
xsdVersion = "1.3.0"
feature {
name=':parent:web:karaf-features:bundles-feature'
description='a'
details='a'
includeProject=false
}
}

:parent:web:karaf-features:bundles-feature is that feature that should be included through a compile dependency.

I get:

16:21:00.844 [ERROR] [org.gradle.BuildExceptionReporter]
16:21:00.845 [ERROR] [org.gradle.BuildExceptionReporter] FAILURE: Build failed with an exception.
16:21:00.845 [ERROR] [org.gradle.BuildExceptionReporter]
16:21:00.845 [ERROR] [org.gradle.BuildExceptionReporter] * Where:
16:21:00.845 [ERROR] [org.gradle.BuildExceptionReporter] Build file '/Users/a/proj/proj_gradle/repo/source/proj/karaf-dist/build.gradle' line: 31
16:21:00.845 [ERROR] [org.gradle.BuildExceptionReporter]
16:21:00.845 [ERROR] [org.gradle.BuildExceptionReporter] * What went wrong:
16:21:00.845 [ERROR] [org.gradle.BuildExceptionReporter] A problem occurred evaluating project ':parent:karaf-dist'.
16:21:00.846 [ERROR] [org.gradle.BuildExceptionReporter] > Could not find matching constructor for: com.github.lburgazzoli.gradle.plugin.karaf.features.model.FeatureDescriptor(org.gradle.api.internal.project.DefaultProject_Decorated)
16:21:00.846 [ERROR] [org.gradle.BuildExceptionReporter]
16:21:00.846 [ERROR] [org.gradle.BuildExceptionReporter] * Try:
16:21:00.846 [ERROR] [org.gradle.BuildExceptionReporter] Run with --stacktrace option to get the stack trace.

Can you post the full gradle.build and the project structure ?

Closed as no feedback given