Product editions Cloud services editions
Fully managed in the public cloud of your choice
- Red Hat OpenShift Service on AWS
Jointly managed and supported by Red Hat and AWS
- Microsoft Azure Red Hat OpenShift
Jointly managed and supported by Red Hat and Microsoft
- Red Hat OpenShift Dedicated
Managed offering available on AWS or Google Cloud
- Red Hat OpenShift on IBM Cloud
Jointly supported by Red Hat and IBM; managed by IBM
Self-managed editions
Granular control on your own infrastructure
- Red Hat OpenShift Platform Plus
A complete platform for accelerating application development and application modernizations
- Red Hat OpenShift Container Platform
A full set of operations and developer services and tools
- Red Hat OpenShift Kubernetes Engine
Basic functionality of enterprise Kubernetes
- Red Hat OpenShift Virtualization Engine
A streamlined solution focused exclusively on virtual machine workloads
Services & add-ons
A portfolio of managed cloud services and tools for Red Hat OpenShift
- Red Hat OpenShift AI
- Red Hat OpenShift Lightspeed
- Red Hat OpenShift Virtualization
- Red Hat Quay
- Red Hat Advanced Cluster Management for Kubernetes
- Red Hat Advanced Cluster Security for Kubernetes
- Red Hat Advanced Developer Suite
- Red Hat OpenShift Consulting
Documentation Cloud services editions
Explore Why Red Hat OpenShift?
Learn Guided offerings
Hands-on training and experiences to develop knowledge and skills for using OpenShift
- Red Hat OpenShift Virtualization training and certification
- Containers, Kubernetes and Red Hat OpenShift Technical Overview
- Red Hat OpenShift Administration I: Operating a Production Cluster
- Red Hat OpenShift Administration II: Operating a Production Kubernetes Cluster with exam
- Developing Applications with Red Hat OpenShift Serverless and Knative
- Modern Application Development Roadshow
Learning hubs
Learning materials and tools organized by top tasks for key OpenShift services
On-demand
- Interactive labs
Scenario-based, preconfigured OpenShift environments in your web browser
- OpenShift learning paths
Resources for beginners or experts, dev or ops
- Red Hat OpenShift Library
Materials divided into chapters for self-managed and managed OpenShift customers
- Ask an OpenShift Admin
Livestream episodes on OpenShift topics and cloud-native tooling
Get started Try Red Hat OpenShift
- Red Hat OpenShift Service on AWS hands-on experience
Get access to a free 8 hour hands-on experience of ROSA in a Red Hat owned demo environment
- Red Hat OpenShift Container Platform
Self-managed on OpenShift Container Platform, in the cloud, on your computer, or in your datacenter
- Red Hat OpenShift Dedicated
Fully managed OpenShift Dedicated trial cluster with self-service sign-up and cluster provisioning in your Google Cloud account
- Developer sandbox
Instant access to your own minimal, preconfigured environment for development and testing
Buy Red Hat OpenShift
- Red Hat OpenShift Service on AWS
A pay-as-you-go, fully managed turnkey application platform which allows organizations to quickly build, deploy, and scale applications in a native AWS environment
- Azure Red Hat OpenShift
A pay-as-you-go, turnkey application platform that provides highly available, fully managed OpenShift clusters on demand
- Red Hat OpenShift Service on AWS hands-on experience
- Products
- Red Hat OpenShift
- Spring on Kubernetes with Red Hat OpenShift
Spring on Kubernetes with Red Hat OpenShift
Overview
Red Hat® OpenShift® allows you to develop and run Kubernetes-native Spring and Spring Boot applications.
What is Spring?
The Spring Framework is one of the most popularJava frameworks for building applications based on a distributedmicroservices architecture. Spring’s programming and configuration model for Java-based applications focuses on the “plumbing” so that developers can focus on application-level business logic, without unnecessary ties to specific deployment environments. Spring Boot then enables easy packaging and configuration of the application into a self-contained executable application which can be easily deployed as acontainer toKubernetes.
Kubernetes-native Spring
Spring, like many traditional Java frameworks, does not inherently “know” that it is running in a container on a platform like Kubernetes. The Spring Framework includes many components that make building and deploying distributed applications easier, such as Spring Boot, Spring Cloud, Spring Web, and a host of other components to do service discovery, load balancing, request routing, and more. With Kubernetes, many of these concerns can be delegated to the underlying container platform to produce an application that integrates more efficiently with the platform it’s running on. Building Spring apps using these optimized code paths is key to unlocking the power of Spring + Kubernetes.
Red Hat resources
Kubernetes support for Spring developers
Spring apps can rely on Kubernetes and capabilities deployed to it to provide the needed cloud services that enable efficient development on Kubernetes. This includes services like message queues, databases, persistence storage, and caching, among others.
Service registry
Microservice architectures often imply dynamic scaling of individual services, in a private, hybrid or public cloud where the number and address of hosts cannot always be predicted or statically configured in advance. In Kubernetes, service replication and scaling is a core feature. This means that the client does not need to keep a cache and account for the failure of the service registry itself. For example, Netflix Ribbon (often used with Spring apps) can be declaratively configured to use Kubernetes instead of a service registry, without any code changes.
Load balancing
For client calls to stateless services in Spring apps,high availability (HA) translates to a need to look up the service from a service registry, and load balance among available instances. Kubernetes provides a singleservice address where calls will be load balanced and redirected to an appropriate instance. Within aKubernetes cluster, the service name resolves to this cluster IP address and can be used to reach the load balancer. For calls from outside and when going through the router is not desirable, an external IP address can be configured for the service.
Fault tolerance
The highly distributed nature of microservices implies a higher risk of failure of a remote call, as the number of such remote calls increases. Historically, the burden of implementing fault tolerance patterns like a circuit breaker has fallen to the developer. However, projects likeIstio that implement aservice mesh can alleviate this burden and provide much greater operational control over Spring services running in the cluster.
Externalized configuration
Externalized configuration management solutions can provide an elegant alternative to the typical combination of configuration files, command line arguments, and environment variables that are used to make applications more portable and less rigid in response to outside changes.Kubernetes ConfigMaps can be used to store fine-grained information like individual properties, or coarse-grained information like entire configuration files or JSON blobs. They provide mechanisms to inject containers with configuration data, keeping configuration separate from but accessible to Spring apps using annotations like @ConfigProperty.
Distributed tracing and application metrics
For all its advantages, amicroservice architecture can be difficult to analyze and troubleshoot. Each business request spawns multiple calls to, and between, individual services at various layers. Distributed tracing ties all individual service calls together, and associates them with a business request through a unique generated ID. Going further, metrics enable Spring apps to expose application-level data to enable fine-grained examination of the state of an application. Tracing tools likeJaeger, combined with a metrics stack withPrometheus andGrafana provide a solid foundation for monitoring and troubleshooting Spring apps on Kubernetes.
Optimizing Spring for Kubernetes
As Spring applications evolve into collections of decentralized services, managing communications and security between those services becomes more difficult.Red Hat OpenShift combined withRed Hat Runtimes provides Spring developers with the tooling, frameworks and native Kubernetes integrations necessary to build and manage Spring applications at scale on the industry's leading container and Kubernetes hybrid cloud platform.
Benefits of Red Hat OpenShift for Spring developers
There are many benefits for Spring developers using Red Hat OpenShift. These include:
Optimized for Kubernetes and DevOps
Using Spring Boot on OpenShift provides a natural “Spring Boot on Kubernetes” developer experience for both existing and net-new Spring apps.
- Support for buildingcloud-native applications with Spring and Spring Boot
- Integrates Kubernetes features that replace traditional standalone backing services
- Externalized Configuration: Kubernetes ConfigMap and integration with Spring Cloud Kubernetes
- Service Discovery: Kubernetes Services
- Load Balancing: Kubernetes Replication Controller
- Auto-Restart: Kubernetes Health Probes and integration with Spring Actuator
- Metrics: Prometheus, Grafana, and integration with Spring Cloud Sleuth
- Distributed Tracing withIstio & Jaeger Tracing
- Developer tooling throughRed Hat OpenShift to quickly scaffold new Spring projects, gain access to familiar Spring APIs in your favoriteIDE, and deploy to Red Hat OpenShift
Pre-integrated across the stack
Use familiar Spring APIs and gain the benefits of the underlying Kubernetes platform and services inRed Hat OpenShift andRed Hat Application Services.
- Red Hat build of OpenJDK optimized for running Java apps in a container environment
- Kubernetes-native services through Red Hat Application Services that integrate withSpring Cloud Kubernetes, Spring Security (withRed Hat SSO), Spring Caching (withRed Hat Data Grid), Spring Messaging (withRed Hat AMQ), Spring Web, Spring Data, and more
- Implement common enterprise integration patterns across your application services using Spring Boot and Red Hat Build ofApache Camel (available with aRed Hat Application Foundations subscription)
Supports modern applications
Use Spring knowledge to develop modern apps using the latest in technology.
- Serverless Spring apps withCamel-K andKafka
- Use familiar Spring APIs to build container-native Java apps withQuarkus
- Native Kubernetes Business Processes withKogito
- UseKubernetes Operators to provide a natural way to create and link Spring apps together using nativeKubernetes APIs viaHalkyon
The official Red Hat blog
Get the latest information about our ecosystem of customers, partners, and communities.
All Red Hat product trials
Keep reading
What is DevOps?
What is serverless?
Stateful vs stateless applications
Red Hat OpenShift resources
Featured products
Red Hat OpenShift
A unified application development platform that lets you build, modernize, and deploy applications at scale on your choice of hybrid cloud infrastructure.
Red Hat Application Foundations
A set of components engineered to help build, deploy, and operate applications. Includes Red Hat 3scale API Management, Red Hat Data Grid, Red Hat JBoss Web Server, Red Hat AMQ, Red Hat builds of open source technologies, and a migration toolkit for applications.
Related content
Related articles
- What is DevOps?
- What is GitOps?
- What is a Golden Path for software development?
- What is serverless?
- Stateful vs stateless applications
- Platform engineering vs. DevOps
- What is Kubernetes?
- How to migrate VMs from VMware to Red Hat OpenShift Virtualization
- Why use Red Hat Ansible Automation Platform with Red Hat OpenShift?
- Red Hat OpenShift for developers
- Red Hat OpenShift for platform engineers
- Edge computing with Red Hat OpenShift
- Red Hat OpenShift vs. OKD
- Red Hat OpenShift vs. Kubernetes: What's the difference?
- Why run Apache Kafka on Kubernetes?
- Why choose Red Hat for middleware?
- What are Red Hat OpenShift Operators?
- Using Helm with Red Hat OpenShift
- Orchestrating Windows containers on Red Hat OpenShift
- Red Hat OpenShift application services
- High performance computing with Red Hat OpenShift
- Red Hat OpenShift for business leaders
- Cost management for Kubernetes on Red Hat OpenShift
- How to deploy Red Hat OpenShift
- What is enterprise Kubernetes?
- Kubernetes-native Java development with Quarkus
- Why choose Red Hat for Kubernetes?
- What makes Red Hat OpenShift the right choice for IT operations?
- What was CoreOS and CoreOS container Linux
- Why Red Hat for APIs?
- Why choose Red Hat for integration?
- Why choose Red Hat for containers?