You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
D:\Workspaces\GitHub\monolith>gradle :shadow:shadowJar
FAILURE: Build failed with an exception.
* What went wrong:
Could not resolve all dependencies for configuration ':shadow:runtime'.
> Could not find org.springframework.boot:spring-boot-starter-data-mongodb:.
Searched in the following locations:
https://jcenter.bintray.com/org/springframework/boot/spring-boot-starter-data-mongodb//spring-boot-starter-data-mongodb-.pom
https://jcenter.bintray.com/org/springframework/boot/spring-boot-starter-data-mongodb//spring-boot-starter-data-mongodb-.jar
Required by:
monolith:shadow:1.0 > monolith:io.github.szjug.greeting:1.0
monolith:shadow:1.0 > monolith:io.github.szjug.who:1.0
> Could not find org.springframework.boot:spring-boot-starter-web:.
Searched in the following locations:
https://jcenter.bintray.com/org/springframework/boot/spring-boot-starter-web//spring-boot-starter-web-.pom
https://jcenter.bintray.com/org/springframework/boot/spring-boot-starter-web//spring-boot-starter-web-.jar
Required by:
monolith:shadow:1.0 > monolith:io.github.szjug.greeting:1.0
monolith:shadow:1.0 > monolith:io.github.szjug.who:1.0
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 10.006 secs
Your greeting and who projects are relying on Spring Boot's dependency management to provide the versions for their dependencies. Unfortunately, due an apparent limitation in the way that Gradle works, that same dependency management isn't automatically applied to those dependencies when they're pulled in via a project dependency. This means that they end up without a version and dependency resolution fails. You may want to take this up with the Gradle team. It makes sense to me that, at least by default, the versions of the dependencies determined by the configuration of greeting and who would be used when those dependencies come in transitively via a project dependency.
In the meantime, you can work around the problem by configuring your shadow project to apply the Spring Boot plugin but with repackaging disabled (so you only use its dependency management):
in https://github.com/szjug/monolith project
notice that version is empty
ref johnrengelman/shadow#199
The text was updated successfully, but these errors were encountered: