Issue with gradle multi modules

Hi everyone just a quick one, i am doing a multi-module Gradle project. When i try to load one of my other modules i get Could not determine the dependencies of task ':bootJar'.
Could not resolve all task dependencies for configuration ':runtimeClasspath'. Could not resolve project :common.
Required by: project :
No matching configuration of project :common was found. The consumer was configured to find a library for use during runtime, compatible with Java 17, packaged as a jar, preferably optimized for standard JVMs, and its dependencies declared externally but:
- None of the consumable configurations have attributes. my main build.gradle
plugins {
id 'java'
id 'org.springframework.boot' version '3.1.5'
id 'io.spring.dependency-management' version '1.1.3'
id 'org.hibernate.orm' version '6.2.13.Final'
id 'org.graalvm.buildtools.native' version '0.9.27'
id 'org.asciidoctor.jvm.convert' version '3.3.2'
}

group = 'com.university'
version = '0.0.1-SNAPSHOT'

java {
sourceCompatibility = '17'
}

repositories {
mavenCentral()
}

ext {
set('snippetsDir', file("build/generated-snippets"))
set('springCloudVersion', "2022.0.4")
}

dependencies {
...
implementation project(':common')
}

dependencyManagement {
imports {
mavenBom "org.springframework.cloud:spring-cloud-dependencies:${springCloudVersion}"
}
}

tasks.named('bootBuildImage') {
builder = 'paketobuildpacks/builder-jammy-tiny:latest'
}

tasks.named('test') {
outputs.dir snippetsDir
useJUnitPlatform()
}

tasks.named('asciidoctor') {
inputs.dir snippetsDir
dependsOn test
}

hibernate {
enhancement {
enableAssociationManagement = true
}
}
plugins {
id 'java'
id 'org.springframework.boot' version '3.1.5'
id 'io.spring.dependency-management' version '1.1.3'
id 'org.hibernate.orm' version '6.2.13.Final'
id 'org.graalvm.buildtools.native' version '0.9.27'
id 'org.asciidoctor.jvm.convert' version '3.3.2'
}

group = 'com.university'
version = '0.0.1-SNAPSHOT'

java {
sourceCompatibility = '17'
}

repositories {
mavenCentral()
}

ext {
set('snippetsDir', file("build/generated-snippets"))
set('springCloudVersion', "2022.0.4")
}

dependencies {
...
implementation project(':common')
}

dependencyManagement {
imports {
mavenBom "org.springframework.cloud:spring-cloud-dependencies:${springCloudVersion}"
}
}

tasks.named('bootBuildImage') {
builder = 'paketobuildpacks/builder-jammy-tiny:latest'
}

tasks.named('test') {
outputs.dir snippetsDir
useJUnitPlatform()
}

tasks.named('asciidoctor') {
inputs.dir snippetsDir
dependsOn test
}

hibernate {
enhancement {
enableAssociationManagement = true
}
}
my settings.gradle
rootProject.name = 'mediasystem'
include 'common', 'media_engine_service', 'authentication_service'
rootProject.name = 'mediasystem'
include 'common', 'media_engine_service', 'authentication_service'
common's gradle
plugins {
id 'java'
}

group = 'com.university'
version = '0.0.1-SNAPSHOT'

java {
sourceCompatibility = '17'
}

repositories {
mavenCentral()
}
plugins {
id 'java'
}

group = 'com.university'
version = '0.0.1-SNAPSHOT'

java {
sourceCompatibility = '17'
}

repositories {
mavenCentral()
}
1 Reply
JavaBot
JavaBot12mo ago
This post has been reserved for your question.
Hey @shaan160! Please use /close or the Close Post button above when your problem is solved. Please remember to follow the help guidelines. This post will be automatically closed after 300 minutes of inactivity.
TIP: Narrow down your issue to simple and precise questions to maximize the chance that others will reply in here. 💤 Post marked as dormant
This post has been inactive for over 300 minutes, thus, it has been archived. If your question was not answered yet, feel free to re-open this post or create a new one. In case your post is not getting any attention, you can try to use /help ping. Warning: abusing this will result in moderative actions taken against you.
Want results from more Discord servers?
Add your server