fabric-samples/asset-transfer-ledger-queries/application-java/build.gradle
Mark S. Lewis 62f51d3efb
Support Java 25 (#1352)
- Update Gradle to 9.1.0.
- Update shadow plugin to 9.2.2.
- Requires a minimum of Java 17 to run Gradle.
- Chaincode and applications still target Java 11.
- Use release option instead of Gradle toolchain since the toolchain
  download can cause issues when building Docker images.

Signed-off-by: Mark S. Lewis <Mark.S.Lewis@outlook.com>
2025-10-06 12:26:52 -04:00

42 lines
1.2 KiB
Groovy

/*
* This file was generated by the Gradle 'init' task.
*
* This generated file contains a sample Java project to get you started.
* For more details take a look at the Java Quickstart chapter in the Gradle
* User Manual available at https://docs.gradle.org/6.5/userguide/tutorial_java_projects.html
*/
plugins {
// Apply the java plugin to add support for Java
id 'java'
// Apply the application plugin to add support for building a CLI application.
id 'application'
}
ext {
javaMainClass = "application.java.App"
}
repositories {
// You can declare any Maven/Ivy/file repository here.
mavenCentral()
}
dependencies {
// This dependency is used by the application.
implementation 'com.google.guava:guava:29.0-jre'
implementation 'org.hyperledger.fabric:fabric-gateway-java:2.1.1'
}
application {
// Define the main class for the application.
mainClass = 'application.java.App'
}
// task for running the app after building dependencies
task runApp(type: Exec) {
dependsOn build
group = "Execution"
description = "Run the main class with ExecTask"
commandLine "java", "-classpath", sourceSets.main.runtimeClasspath.getAsPath(), javaMainClass
}