Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for Spring Boot Native Image #2138

Closed
2 tasks
rohanKanojia opened this issue Apr 18, 2023 · 6 comments · Fixed by #2320
Closed
2 tasks

Support for Spring Boot Native Image #2138

rohanKanojia opened this issue Apr 18, 2023 · 6 comments · Fixed by #2320
Assignees
Milestone

Comments

@rohanKanojia
Copy link
Member

Component

JKube Kit

Task description

Description

SpringBoot 3 introduces the support for creating GraalVM native images. SpringBootGenerator should detect whether it's a native build and create a native assembly based on some minimal image.

SpringBootGenerator should detect the presence of org.graalvm.buildtools:native-maven-plugin plugin in project to detect whether it's a native build or not. See Spring Boot documentation[0] for more details.

[0] https://docs.spring.io/spring-boot/docs/current/reference/html/native-image.html

Expected Behavior

Just like QuarkusGenerator, SpringBootGenerator should create a native container image using the generated native artifact.

Acceptance Criteria

  • SpringBootGenerator should detect whether it's a normal JDK build or native build
  • SpringBootGenerator should build a container image including native executable
@anurag-rajawat
Copy link
Contributor

Hi @rohanKanojia
Can I try this one?

@rohanKanojia
Copy link
Member Author

@anurag-rajawat : Umm, not sure. This issue requires refactoring SpringBootGenerator in order to support legacy jar, layered jar and native mode assembly types.

@rohanKanojia rohanKanojia self-assigned this Aug 2, 2023
rohanKanojia added a commit to rohanKanojia/jkube that referenced this issue Aug 2, 2023
rohanKanojia added a commit to rohanKanojia/jkube that referenced this issue Aug 3, 2023
rohanKanojia added a commit to rohanKanojia/jkube that referenced this issue Aug 8, 2023
rohanKanojia added a commit to rohanKanojia/jkube that referenced this issue Aug 8, 2023
…ring Boot 3.x (eclipse-jkube#2138)

+ Change SpringBootConfigurationHelper's constructor argument to String
  from Optional
+ Add Spring Boot 3 properties to SpringBootConfigurationHelper

Signed-off-by: Rohan Kumar <rohaan@redhat.com>
rohanKanojia added a commit to rohanKanojia/jkube that referenced this issue Aug 9, 2023
…ring Boot 3.x (eclipse-jkube#2138)

+ Change SpringBootConfigurationHelper's constructor argument to String
  from Optional
+ Add Spring Boot 3 properties to SpringBootConfigurationHelper

Signed-off-by: Rohan Kumar <rohaan@redhat.com>
rohanKanojia added a commit to rohanKanojia/jkube that referenced this issue Aug 23, 2023
…ring Boot 3.x (eclipse-jkube#2138)

+ Change SpringBootConfigurationHelper's constructor argument to String
  from Optional
+ Add Spring Boot 3 properties to SpringBootConfigurationHelper

Signed-off-by: Rohan Kumar <rohaan@redhat.com>
manusa pushed a commit that referenced this issue Aug 25, 2023
…ring Boot 3.x (#2138)

+ Change SpringBootConfigurationHelper's constructor argument to String
  from Optional
+ Add Spring Boot 3 properties to SpringBootConfigurationHelper

Signed-off-by: Rohan Kumar <rohaan@redhat.com>
rohanKanojia added a commit to rohanKanojia/jkube that referenced this issue Aug 30, 2023
rohanKanojia added a commit to rohanKanojia/jkube that referenced this issue Aug 31, 2023
@manusa manusa added this to the 1.15.0 milestone Sep 7, 2023
manusa pushed a commit to rohanKanojia/jkube that referenced this issue Sep 7, 2023
manusa pushed a commit that referenced this issue Sep 8, 2023
@ArnauAregall
Copy link

Congrats for this one! 👏 @rohanKanojia

@rohanKanojia
Copy link
Member Author

@ArnauAregall : Thanks, Were you waiting for this one to get merged?

Could you please try out whether the feature is working for your pipeline on 1.15-SNAPSHOT? You would need to add this to your pom.xml in order to enable SNAPSHOTs:

  <pluginRepositories>
    <pluginRepository>
      <id>oss.sonatype.org</id>
      <url>https://oss.sonatype.org/content/repositories/snapshots</url>
      <snapshots>
        <enabled>true</enabled>
        <updatePolicy>always</updatePolicy>
      </snapshots>
    </pluginRepository>
  </pluginRepositories>

@ArnauAregall
Copy link

@ArnauAregall : Thanks, Were you waiting for this one to get merged?

I had the notifications turned on for this issue since on my company we are extensive users of jkube to deploy our Spring Boot apps.

Currently we are on our way migrating our apps to SB 3.x and I just wanted to be aware when jkube was ready to be compatible with GraalVM native images.

Right now I am still not able to try out the SNAPSHOT, our SB upgrades are still in progress, but without a doubt I will try it out once I have the occasion. 👍

Cheers!

@manusa
Copy link
Member

manusa commented Sep 8, 2023

That's sounds awesome. Thanks, Arnau!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants