Skip to content

How to download GraalVM faster? #74

@catfishlty

Description

@catfishlty

Description

When start build spring-native image by Maven, the process will wait for downloading GrallVM for a very long time.
Maybe it's a network problem, but i want to know is there any other ways to speedup this step.

Maven Config

<plugin>
  <groupId>org.springframework.boot</groupId>
  <artifactId>spring-boot-maven-plugin</artifactId>
  <configuration>
    <image>
      <builder>paketobuildpacks/builder:tiny</builder>
      <env>
        <BP_NATIVE_IMAGE>true</BP_NATIVE_IMAGE>
      </env>
    </image>
  </configuration>
</plugin>

Build Cmd

mvn spring-boot:build-image

Docker Builder Container Logs

===> DETECTING

4 of 11 buildpacks participating

paketo-buildpacks/graalvm 6.0.0

paketo-buildpacks/executable-jar 5.0.0

paketo-buildpacks/spring-boot 4.2.0

paketo-buildpacks/native-image 4.0.0

===> ANALYZING

Previous image with name "docker.io/library/spring-native-build-docker-demo:0.0.1-SNAPSHOT" not found

===> RESTORING

===> BUILDING



Paketo GraalVM Buildpack 6.0.0

https://github.com/paketo-buildpacks/graalvm

Build Configuration:

$BP_JVM_VERSION 8.* the Java version

Launch Configuration:

$BPL_JVM_HEAD_ROOM 0 the headroom in memory calculation

$BPL_JVM_LOADED_CLASS_COUNT 35% of classes the number of loaded classes in memory calculation

$BPL_JVM_THREAD_COUNT 250 the number of threads in memory calculation

$JAVA_TOOL_OPTIONS the JVM launch flags

GraalVM JDK 8.0.282: Contributing to layer

Downloading from https://github.com/graalvm/graalvm-ce-builds/releases/download/vm-21.0.0.2/graalvm-ce-java8-linux-amd64-21.0.0.2.tar.gz

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions