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

Adding "withSourcesJar" in a Gradle quarkus-cxf build causes duplicate sources to appear in JAR #35854

Open
jskillin-idt opened this issue Sep 11, 2023 · 1 comment
Labels
area/gradle Gradle kind/bug Something isn't working

Comments

@jskillin-idt
Copy link
Contributor

Describe the bug

This was originally reported at quarkiverse/quarkus-cxf#859 but was re-reported here by request.

A project with at least the following lines triggers a build failure, in which the generated source from the WSDL is attempted to be packaged more than once in the source JAR:

plugins {
    // ...
    id 'java'
    id 'io.quarkus' // 3.0.1.Final
}

// ...
dependencies {
    // ...
    implementation 'io.quarkiverse.cxf:quarkus-cxf:2.0.2'
}
// ...
java {
    // ...
    withSourcesJar()
}
// ...

An example failure using the reproducer:

> Task :sourcesJar FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':sourcesJar'.
> Entry wsdl2java/org/jboss/eap/quickstarts/wscalculator/calculator/Multiply.java is a duplicate but no duplicate handling strategy has been set. Please refer to https://docs.gradle.org/8.1.1/dsl/org.gradle.api.tasks.Copy.html#org.gradle.api.tasks.Copy:duplicatesStrategy for details.

Expected behavior

No response

Actual behavior

No response

How to Reproduce?

Reproducer: https://github.com/jskillin-idt/quarkiverse-quarkus-cxf-issues-859

Output of uname -a or ver

No response

Output of java -version

No response

GraalVM version (if different from Java)

No response

Quarkus version or git rev

3.0.1.Final

Build tool (ie. output of mvnw --version or gradlew --version)

Gradle 8.1.1

Additional information

No response

@jskillin-idt jskillin-idt added the kind/bug Something isn't working label Sep 11, 2023
@quarkus-bot quarkus-bot bot added the area/gradle Gradle label Sep 11, 2023
@quarkus-bot
Copy link

quarkus-bot bot commented Sep 11, 2023

/cc @glefloch, @quarkusio/devtools

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/gradle Gradle kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant