You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "dongjoon-hyun (via GitHub)" <gi...@apache.org> on 2026/03/21 19:45:01 UTC

[PR] [SPARK-56128] Use Java `21-jre` instead of `21` image in K8s Dockerfile [spark]

dongjoon-hyun opened a new pull request, #54940:
URL: https://github.com/apache/spark/pull/54940

   ### What changes were proposed in this pull request?
   
   This PR changes the default Java base image tag from `21` (full JDK) to `21-jre` (JRE only) in the Spark Kubernetes Dockerfile for Apache Spark 4.2.0.
   
   ### Why are the changes needed?
   
   Since Apache Spark 3.5, SPARK-44153 starts to use `jmap` for UI.
   - https://github.com/apache/spark/pull/41709
   
   Since Apache Spark 4.0, we used `21` by default.
   - #45761
   
   Since Apache Spark 4.2, we can use `21-jre` back by default because we removed `jmap` dependency.
   - #54919
   
   The JRE image is significantly smaller than the full JDK image since it excludes development tools (compiler, debugger, etc.) that are not needed at runtime. This reduces the Spark container image size for Kubernetes deployments.
   
   ```
   $ docker images
   IMAGE                                              ID             DISK USAGE   CONTENT SIZE   EXTRA
   azul/zulu-openjdk:21                               4cfeb0cae1b1        651MB          203MB
   azul/zulu-openjdk:21-jre                           27894d1c0e9d        461MB          114MB
   ```
   
   ### Does this PR introduce _any_ user-facing change?
   
   No behavior change. In addition, users who need the full JDK can still override via `--build-arg java_image_tag=21`.
   
   ### How was this patch tested?
   
   Pass the CIs and manual review of the Dockerfile change.
   
   ### Was this patch authored or co-authored using generative AI tooling?
   
   Generated-by: Claude Code (claude-opus-4-6)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org


Re: [PR] [SPARK-56128][K8S] Use Java `21-jre` instead of `21` image in K8s Dockerfile [spark]

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun commented on PR #54940:
URL: https://github.com/apache/spark/pull/54940#issuecomment-4104262669

   Could you review this PR, too, @peter-toth ?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org


Re: [PR] [SPARK-56128][K8S] Use Java `21-jre` instead of `21` image in K8s Dockerfile [spark]

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun commented on PR #54940:
URL: https://github.com/apache/spark/pull/54940#issuecomment-4104377851

   Merged to master for Apache Spark 4.2.0.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org


Re: [PR] [SPARK-56128][K8S] Use Java `21-jre` instead of `21` image in K8s Dockerfile [spark]

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun closed pull request #54940: [SPARK-56128][K8S] Use Java `21-jre` instead of `21` image in K8s Dockerfile
URL: https://github.com/apache/spark/pull/54940


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org


Re: [PR] [SPARK-56128][K8S] Use Java `21-jre` instead of `21` image in K8s Dockerfile [spark]

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun commented on PR #54940:
URL: https://github.com/apache/spark/pull/54940#issuecomment-4107771576

   Thank you, @pan3793 !


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org


Re: [PR] [SPARK-56128] Use Java `21-jre` instead of `21` image in K8s Dockerfile [spark]

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun commented on PR #54940:
URL: https://github.com/apache/spark/pull/54940#issuecomment-4104148448

   cc @pan3793 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org


Re: [PR] [SPARK-56128][K8S] Use Java `21-jre` instead of `21` image in K8s Dockerfile [spark]

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun commented on PR #54940:
URL: https://github.com/apache/spark/pull/54940#issuecomment-4104322268

   Thank you, @peter-toth ! 😄 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org


Re: [PR] [SPARK-56128][K8S] Use Java `21-jre` instead of `21` image in K8s Dockerfile [spark]

Posted by "pan3793 (via GitHub)" <gi...@apache.org>.
pan3793 commented on PR #54940:
URL: https://github.com/apache/spark/pull/54940#issuecomment-4107695309

   late lgtm


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org