diff --git a/.github/workflows/java-cd.yml b/.github/workflows/java-cd.yml index 58e69ed851..e46bbd8375 100644 --- a/.github/workflows/java-cd.yml +++ b/.github/workflows/java-cd.yml @@ -58,7 +58,7 @@ jobs: uses: actions/setup-java@v4 with: distribution: "temurin" - java-version: "11" + java-version: ${{ env.JAVA_VERSION }} - name: Install shared software dependencies uses: ./.github/workflows/install-shared-dependencies @@ -76,6 +76,9 @@ jobs: - name: Test deployment working-directory: java run: | + export ORG_GRADLE_PROJECT_centralManualTestingAuthHeaderName="Authorization" + export ORG_GRADLE_PROJECT_centralManualTestingAuthHeaderValue="Bearer $(echo "${{ secrets.CENTRAL_TOKEN_USERNAME }}:${{ secrets.CENTRAL_TOKEN_PASSWORD }}" | base64)" + export GLIDE_RELEASE_VERSION=${{ env.RELEASE_VERSION }} ./gradlew :benchmarks:run --args="--minimal --clients glide" # diff --git a/java/benchmarks/build.gradle b/java/benchmarks/build.gradle index fc779ee778..665ab49cba 100644 --- a/java/benchmarks/build.gradle +++ b/java/benchmarks/build.gradle @@ -1,6 +1,7 @@ plugins { // Apply the application plugin to add support for building a CLI application in Java. id 'application' + id "com.google.osdetector" version "1.7.3" } repositories { @@ -11,11 +12,11 @@ repositories { dependencies { def releaseVersion = System.getenv("GLIDE_RELEASE_VERSION"); -// if (releaseVersion) { - implementation "io.valkey:valkey-glide:1.0.1" -// } else { -// implementation project(':client') -// } + if (releaseVersion) { + implementation "io.valkey:valkey-glide:"+ releaseVersion + "${osdetector.classifier}" + } else { + implementation project(':client') + } // This dependency is used internally, and not exposed to consumers on their own compile classpath. implementation 'com.google.guava:guava:32.1.1-jre' @@ -25,12 +26,6 @@ dependencies { implementation group: 'org.apache.commons', name: 'commons-lang3', version: '3.13.0' implementation group: 'org.apache.commons', name: 'commons-math3', version: '3.5' implementation group: 'com.google.code.gson', name: 'gson', version: '2.10.1' - - implementation group: 'io.netty', name: 'netty-transport-native-epoll', version: '4.1.100.Final', classifier: 'linux-x86_64' - implementation group: 'io.netty', name: 'netty-transport-native-epoll', version: '4.1.100.Final', classifier: 'linux-aarch_64' - implementation group: 'io.netty', name: 'netty-transport-native-kqueue', version: '4.1.100.Final', classifier: 'osx-x86_64' - implementation group: 'io.netty', name: 'netty-transport-native-kqueue', version: '4.1.100.Final', classifier: 'osx-aarch_64' - } run.dependsOn ':client:buildRustRelease' @@ -40,7 +35,10 @@ application { mainClass = 'glide.benchmarks.BenchmarkingApp' // Runs for GITHUB_ACTIONS for testing release Maven deployment. Force benchmarks to use glide-rs from Maven Central // deployments. -// if (!System.getenv("ORG_GRADLE_PROJECT_centralManualTestingAuthHeaderName")) { -// applicationDefaultJvmArgs = ['-Djava.library.path=../target/release'] -// } + if (!System.getenv("ORG_GRADLE_PROJECT_centralManualTestingAuthHeaderName")) { + applicationDefaultJvmArgs = ['-Djava.library.path=../target/release'] + } } + + + diff --git a/java/client/build.gradle b/java/client/build.gradle index 0178f311ea..d1780bca8f 100644 --- a/java/client/build.gradle +++ b/java/client/build.gradle @@ -14,7 +14,7 @@ repositories { } dependencies { - implementation group: 'com.google.protobuf', name: 'protobuf-java', version: '4.27.1' + implementation group: 'com.google.protobuf', name: 'protobuf-java', version: '4.27.3' implementation group: 'org.apache.commons', name: 'commons-lang3', version: '3.13.0' implementation group: 'io.netty', name: 'netty-handler', version: '4.1.100.Final'