Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 33 additions & 22 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
import com.expediagroup.graphql.plugin.gradle.config.GraphQLSerializer

plugins {
id 'com.github.johnrengelman.shadow' version '7.1.2'
id 'com.github.johnrengelman.shadow' version '8.1.1'
id "java"
id 'org.jetbrains.kotlin.jvm' version '1.9.21'
id 'org.jetbrains.kotlin.jvm' version '2.1.10'
id "signing"
id "maven-publish"
id "io.github.gradle-nexus.publish-plugin" version "1.0.0"
id 'com.expediagroup.graphql' version '5.2.0'
id "org.jetbrains.dokka" version "1.9.0"
id "io.github.gradle-nexus.publish-plugin" version "2.0.0"
id 'com.expediagroup.graphql' version '7.0.0'
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GraphQL plugin and runtime dependency version mismatch

High Severity

The com.expediagroup.graphql Gradle plugin was upgraded from 5.2.0 to 7.0.0, but the runtime dependencies graphql-kotlin-ktor-client and graphql-kotlin-client-jackson remain at 6.5.3. The GraphQL Kotlin project releases plugin and runtime libraries in lockstep — the plugin at 7.0.0 generates client code expecting 7.x APIs. This mismatch will likely cause compilation or runtime failures when the generated code references classes or methods that don't exist in the 6.5.3 runtime.

Additional Locations (1)

Fix in Cursor Fix in Web

id "org.jetbrains.dokka" version "2.0.0"
}

group 'com.indico'
Expand All @@ -17,19 +17,21 @@ repositories {
mavenCentral()
}

archivesBaseName = "indico-client-java"
base {
archivesName = "indico-client-java"
}
version = "6.0.0"

test.onlyIf { project.hasProperty('runTests') }

tasks.register('sourceJar', Jar) {
classifier "sources"
from sourceSets.main.allJava
archiveClassifier.set("sources")
from sourceSets.main.allSource
}

tasks.register('javadocJar', Jar) {
dependsOn javadoc
classifier "javadoc"
archiveClassifier.set("javadoc")
from javadoc.destinationDir
}

Expand All @@ -43,19 +45,19 @@ publishing {


dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:1.9.21"
implementation "org.jetbrains.kotlin:kotlin-reflect:1.9.21"
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.7.0'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.7.0'
implementation("io.ktor:ktor-client-okhttp:2.3.2")
testImplementation('org.junit.jupiter:junit-jupiter:5.5.2')
implementation "org.jetbrains.kotlin:kotlin-stdlib:2.1.10"
implementation "org.jetbrains.kotlin:kotlin-reflect:2.1.10"
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.10.2'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.10.2'
implementation("io.ktor:ktor-client-okhttp:2.3.12")
testImplementation('org.junit.jupiter:junit-jupiter:5.10.2')
implementation("com.expediagroup:graphql-kotlin-ktor-client:6.5.3")
implementation("com.expediagroup:graphql-kotlin-client-jackson:6.5.3")
implementation("com.squareup.okhttp3:okhttp:4.10.0")
implementation('org.apache.logging.log4j:log4j-1.2-api:2.15.0')
implementation("com.squareup.okhttp3:okhttp:4.12.0")
implementation('org.apache.logging.log4j:log4j-1.2-api:2.23.1')
api('org.json:json:20231013')
compileOnly("org.jetbrains:annotations:13.0")
testCompileOnly("org.jetbrains:annotations:13.0")
compileOnly("org.jetbrains:annotations:24.1.0")
testCompileOnly("org.jetbrains:annotations:24.1.0")
}


Expand All @@ -76,17 +78,26 @@ graphqlGenerateClient {

}

compileKotlin {
kotlinOptions.jvmTarget = "1.8"
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).configureEach {
kotlinOptions.jvmTarget = "1.8"
}


// ossrh requires javadoc and sources https://central.sonatype.org/pages/requirements.html
java {
toolchain {
languageVersion = JavaLanguageVersion.of(21)
}
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
withJavadocJar()
withSourcesJar()
}

kotlin {
jvmToolchain(21)
}


void sign(Project project) {
project.signing {
Expand Down Expand Up @@ -159,4 +170,4 @@ publishing {

test {
useJUnitPlatform()
}
}
17 changes: 9 additions & 8 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
java:
build: .
env_file: .env
command: ./build.sh
services:
java:
build: .
env_file: .env
command: ./build.sh

test:
build: .
env_file: .env
command: ./test.sh
test:
build: .
env_file: .env
command: ./test.sh
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading
Loading