Uploaded image for project: 'jBPM'
  1. jBPM
  2. JBPM-9747

Support springboot buildpack immutable images

    XMLWordPrintable

Description

    When building an image from buildpack (mvn spring-boot:build-image), this is executed over the unzipped jar (launching main class directly) but the current approach is only considering the execution over the fat-jar (java -jar .....jar).

    InJarArtifactResolver (when the jar is unpacked and run in an exploded form) finds resourceURL but it's a simple directory, not a jar as expected:

    resourceURL "file:/workspace/" (buildpack)

    vs.

    resourceURL "jar:file:/home/gmunozfe/git/quartz-cluster-springboot-kie-server/target/quartz-cluster-springboot-kie-server-1.0.0.jar!/BOOT-INF/classes!/" (local)

    Same with autoScan scenario:

    appHome.getSource()

    is a directory, so it throws this exception:

    Factory method 'buildAutoScanDeployments' threw exception; nested exception is java.io.FileNotFoundException: /workspace/BOOT-INF/classes (Is a directory)

     

    Reproducer project: https://github.com/gmunozfe/quartz-cluster-springboot-kie-server

     

    Attachments

      Activity

        People

          elguardian@gmail.com Enrique González Martínez (Inactive)
          gmunozfe@redhat.com Gonzalo Muñoz Fernández
          Votes:
          1 Vote for this issue
          Watchers:
          2 Start watching this issue

          Dates

            Created:
            Updated:
            Resolved: