Skip to content
This repository was archived by the owner on May 14, 2025. It is now read-only.
This repository was archived by the owner on May 14, 2025. It is now read-only.

Weird behavior when running Spring Cloud Task applications with Spring Boot Native support #5886

Open
@klopfdreh

Description

@klopfdreh

Description:
Because of the startup time we are currenty evaluating to migrate our Spring Cloud Task applications to Spring Boot Native.

We managed to get the native application running and uploading files to the s3 bucket, but there is a weird behavior of the native application compared to the java application in the Spring Cloud Data Flow UI.

Setup

  1. We created an application with type task and Spring Boot version Spring Boot 3.x and URI docker://...../<imagename>:<version> (the docker image is a native image)
    image

  2. We created a task which just points towards the application
    image

  3. We did the same for a Java docker image. So there are two applications s3-uploader-native-app and s3-uploader-app and two tasks s3-uploader-native-task and s3-uploader-task

  4. We launched the task of the native application like the task of the java application

Outcome

  1. Java Application: It runs like expected and if you click on the execution id everything is fine. (The task is listed at the side of the information)
    image

  2. Native Application: The application executed without any errors, but if you click on the execution id some information are missing (The task is NOT listed at the side of the information)
    image

  3. There is also a difference in the task executions view: The java application finished with the execution name s3-uploader-task. The native application finished with the execution name s3-uploader-native-app
    image

  4. During the runtime however, the native task is executing with the correct name s3-uploader-native-task - it is switched to s3-uploader-native-app when completed:
    image

  5. If you click on the name of the native task execution in the task executions view (not on the execution id) an error occurs and you are redirected to the task view
    image

  6. Also an error occurs if you click on the execution id and after this on the job execution id (I guess it is because the UI can't resolve the task execution for the job execution)
    image

Release versions:

Custom apps:
N/A

Steps to reproduce:

  • Create a simple Spring Cloud Task application with one Spring Batch job configuration and one Spring Batch step
  • Use native-image of Liberica NIK or spring-boot-maven-plugin with packeto buildpacks to create a native image of the Spring Cloud Task application
  • Register the application like explained in the description

Screenshots:
See description

Additional context:
When I manually change the name of any task execution in the database from s3-uploader-native-app to s3-uploader-native-task everthing is like it should be.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions