Class GradleGraalPlugin

java.lang.Object
com.palantir.gradle.graal.GradleGraalPlugin
All Implemented Interfaces:
org.gradle.api.Plugin<org.gradle.api.Project>

public class GradleGraalPlugin extends Object implements org.gradle.api.Plugin<org.gradle.api.Project>
Adds tasks to download, extract and interact with GraalVM tooling.

All tooling execution (e.g. nativeImage) will cause GraalVM tooling to download and cache if not already present. Currently, GraalVM CE only supports MacOS and Linux, and, as a result, this plugin will only correctly function on MacOS and Linux. The plugin will automatically select the correct architecture and error clearly if the runtime architecture is not supported.

Downloads are stored in ~/.gradle/caches/com.palantir.graal using the following structure:

 ~/.gradle/caches/com.palantir.graal/
 └── [version]/
     ├── graalvm-ce-[version]/
     │   └── [local architecture-specific GraalVM tooling]
     └── graalvm-ce-[version]-amd64.tar.gz
 
  • Constructor Details

    • GradleGraalPlugin

      public GradleGraalPlugin()
  • Method Details

    • apply

      public final void apply(org.gradle.api.Project project)
      Specified by:
      apply in interface org.gradle.api.Plugin<org.gradle.api.Project>