> Markdown version of [/videos/383-kubernetes-native-java?t=234](https://www.wearedevelopers.com/videos/383-kubernetes-native-java?t=234). Every page supports `.md` or `Accept: text/markdown`. Links point to the HTML versions so they work for humans too. Agent guide: [/agents.md](https://www.wearedevelopers.com/agents.md). --- # Kubernetes Native Java Are bulky Java runtimes slowing down your Kubernetes deployments? Learn how to achieve millisecond startups and drastically reduce your memory footprint using Spring Boot, GraalVM, and Java 17. - **Speakers:** Josh Long - **Event:** World Congress 2022 - **Published:** June 15, 2022 - **Duration:** 45:03 - **URL:** https://www.wearedevelopers.com/videos/383-kubernetes-native-java ## Summary This session explores building production-ready, Kubernetes-native Java applications using modern Spring Boot methodologies. The journey begins with a strong advocacy for adopting Java 17 for its security, performance, and container-readiness—urging developers to "be the change you want to see in the world, do the right thing, use Java 17." The initial foundation utilizes Spring's reactive programming model to create a lightweight, scalable application that safely handles multi-threaded concurrency. This framework unifies data processing abstractions and natively supports reliability patterns like backpressure, rate limiting, and timeouts. Preparing an application for production requires deep observability and lifecycle management, which is achieved seamlessly using the Spring Boot Actuator. Exposing liveness and readiness health probes allows Kubernetes to cleanly manage pod states during deployment scaling or disruptions. Likewise, configuring a graceful shutdown period ensures that in-flight network requests are securely finalized before a container is terminated. Furthermore, utilizing Kubernetes config maps mounted as structural volumes allows the application to dynamically absorb environment-specific configuration values, minimizing friction when promoting code configurations across deployment environments. Moving beyond traditional runtime compilation, the GraalVM native image compiler is used to transform dynamic Spring applications into highly optimized, ahead-of-time compiled binaries. This securely removes the overhead of just-in-time adaptation, drastically slashing deployment memory footprint and enabling millisecond startup times that are ideal for efficient, containerized workflows managed via CNCF buildpacks. Finally, the narrative shifts to building smart edge ecosystems—utilizing Spring Cloud Gateway for proxying HTTP requests with tailored routing filters, and smoothly integrating Spring Boot's internal GraphQL support to surface flexible, client-optimized data querying interfaces. **Keywords:** kubernetes-native java, java 17 adoption, reactive programming patterns, spring boot actuator, kubernetes health probes, graceful shutdown configuration, kubernetes config maps, graalvm native compilation, ahead-of-time compilation, cloud-native buildpacks, spring cloud gateway, graphql api implementation, microservices observability, project loom concurrency, distributed systems routing ## Chapters 1. **Optimizing software development for production and Kubernetes** (01:44) — How structural patterns like microservices and continuous integration enable faster iteration in production. 1. **Choosing Java 17 for modern Spring Boot applications** (03:54) — Why long-term support and improved syntax make Java 17 superior for new enterprise projects. 1. **Building scalable applications with reactive programming** (07:32) — How reactive abstractions simplify concurrent multi-threaded code and standardize data stream manipulation. 1. **Initializing simple REST endpoints and database schemas** (09:35) — Configuring reactive data access and streaming basic query results through standard HTTP controllers. 1. **Exposing application telemetry with Spring Boot Actuator** (14:42) — Enabling managed HTTP endpoints to extract internal state, metrics, and health information safely. 1. **Capturing build provenance with git commit plugins** (17:08) — Exposing continuous integration build metadata via the Actuator info endpoint to aid debugging. 1. **Configuring Kubernetes liveness and readiness probes** (19:59) — Publishing application state changes to orchestrators to control traffic routing and pod lifecycles. 1. **Handling traffic signals with graceful pod shutdown** (22:18) — Tying Unix termination signals to internal timeouts to finish in-flight requests before container destruction. 1. **Applying platform-specific conditional configurations in YAML** (23:34) — Using structural document delimiters to dynamically load properties strictly within Kubernetes environments. 1. **Mounting Kubernetes ConfigMaps for runtime property overrides** (25:46) — Extracting environment-specific dictionaries directly into volumes to simplify container deployments. 1. **Comparing Java adaptive compilation with ahead-of-time builds** (27:53) — Understanding the trade-offs between dynamic just-in-time optimization and static native image generation. 1. **Packaging native executables with Spring Native and buildpacks** (34:33) — Feeding dynamic language characteristics into GraalVM and bypassing manual Dockerfiles via standard recipes. 1. **Evaluating memory footprints and startup times of native images** (38:18) — Measuring system-level resident memory usage to prove scaled architecture instances become significantly cheaper. 1. **Deploying logical API gateways using Spring Cloud Gateway** (39:37) — Establishing edge services to automatically filter and route incoming web traffic into underlying microservices. 1. **Aggregating underlying service data with a GraphQL schema** (41:04) — Exposing a non-blocking root query type to let downstream clients selectively fetch exact data shapes. 1. **Contrasting Project Loom virtual threads with reactive semantics** (44:09) — How lightweight threading solves blocking overhead but lacks the data flow capabilities of standard reactive paradigms. ## Related Moments - [Utilizing Quarkus for Kubernetes native Java](https://www.wearedevelopers.com/videos/123-get-started-with-securing-your-cloud-native-java-microservices-applications) (from "Get started with securing your cloud-native Java microservices applications") - [Deploying native Quarkus applications to a Knative cluster](https://www.wearedevelopers.com/videos/243-serverless-native-java-with-quarkus) (from "Serverless-Native Java with Quarkus") - [Optimizing Java startup processes for fast serverless workloads](https://www.wearedevelopers.com/videos/1008-serverless-java-in-action-cloud-agnostic-design-patterns-and-tips) (from "Serverless Java in Action: Cloud Agnostic Design Patterns and Tips") - [Building native executables to lower memory and startup times](https://www.wearedevelopers.com/videos/1591-developer-joy-with-quarkus) (from "Developer Joy with Quarkus") - [Demonstrating event-driven auto-scaling with native Quarkus and Kafka](https://www.wearedevelopers.com/videos/1008-serverless-java-in-action-cloud-agnostic-design-patterns-and-tips) (from "Serverless Java in Action: Cloud Agnostic Design Patterns and Tips") - [Why developers choose the Spring framework for enterprise APIs](https://www.wearedevelopers.com/videos/1141-building-ai-driven-spring-applications-with-spring-ai) (from "Building AI-Driven Spring Applications With Spring AI") ## Related Articles - [Top 10 Java Libraries](https://www.wearedevelopers.com/magazine/364-top-10-java-libraries) - [Using Java 17 latest features in real world projects](https://www.wearedevelopers.com/magazine/121-using-java-17-latest-features-in-real-world-projects) - [Native Web Apps: Are We There Yet?](https://www.wearedevelopers.com/magazine/83-native-web-apps-are-we-there-yet) - [Java Basics](https://www.wearedevelopers.com/magazine/122-java-basics) ## Related Jobs - [Senior Backend Engineer (Java)](https://www.wearedevelopers.com/jobs/ext/19369-senior-backend-engineer-java) at **Bonial International GmbH** - [Java Softwareentwickler - Spring Boot & Microservices](https://www.wearedevelopers.com/jobs/ext/1306817-java-softwareentwickler-spring-boot-microservices) at **Aok Systems Gmbh** - [Platform Engineer - Mercury Runtime Platform](https://www.wearedevelopers.com/jobs/ext/293235-platform-engineer-mercury-runtime-platform) at **Raiffeisen Bank International AG** - [Senior Software Developer Java (m/w/d)](https://www.wearedevelopers.com/jobs/39654-senior-software-developer-java-m-w-d) at **Sopra Steria Custom Software Solutions GmbH** - [Senior Software Engineer, Client Apps Platform](https://www.wearedevelopers.com/jobs/ext/1773893-senior-software-engineer-client-apps-platform) at **GitHub** - [Softwareentwickler Java](https://www.wearedevelopers.com/jobs/ext/1245896-softwareentwickler-java) at **Aok Systems Gmbh**