javacodegeeks.com javacodegeeks.com

Hot-deploying into Kubernetes using Telepresence & WAD

When you’re testing your enterprise application in a Kubernetes environment, the turnaround for changing, re-packaging, and re-deploying your application can become quite high. Telepresence aims to mitigate this, by proxying a locally running process into our Kubernetes cluster, as if the local process were part of the cluster. If we combine that approach with a hot-redeploy tool such as WAD we can vastly improve our development...

javacodegeeks.com javacodegeeks.com

Spring Bean Scopes

Introduction:Spring core container instantiates beans and manages their life-cycle. While defining a bean, we can provide its scope. Unless explicitly provided, singleton is the default scope of beans in a Spring container.We have five types of bean scopes available in Spring. In this tutorial, we’ll explore each of them.1. singleton:The singleton scope ensures that there exists only a single instance of that bean per Spring IoC...

javacodegeeks.com javacodegeeks.com

Spring Boot YAML Configuration

In this quick tutorial, we’ll learn how to use a YAML file to configure properties of a Spring Boot application.What is YAML File?Instead of having an application.properties in Spring, we can use the application.yml as our configuration file. YAML is a superset of JSON and we can use it for configuring data. The YAML files are more human-readable, especially when we have a lot of hierarchical configurations in place.Let’s see...

javacodegeeks.com javacodegeeks.com

Jakarta EE without javax: the world won’t end this time either

If you missed the news, Oracle is donating the Java EE specification to the Eclipse foundation. This decisions has followed a rather long period of hibernation in the specification process where people rightfully suspected a loss of strategic interest in Java EE by Oracle. At first, the decision to donate the specification was well-met by the Java EE and broader Java community. Without Oracle slowing down the process, those involved in...

javacodegeeks.com javacodegeeks.com

Spring Dependency Injection

Introduction:In a well-designed Java application, the classes should be as independent as possible. Such a design promotes reusability of components. It also makes it easier to unit test the various components.The concept of dependency injection promotes loose coupling among Java objects.In this tutorial, we’ll talk about the dependency injection in Spring framework.Inversion Of Control(IoC):Inversion of Control is a software...

javacodegeeks.com javacodegeeks.com

Spring Boot Exit Codes – Create Custom Exit Code

When running a Spring Boot application, we get a system exit code of 0, when everything goes fine.  For any unhandled exceptions, the application returns with an exit code 1.It’s possible for us to return a custom exit code from our Spring Boot application. In this tutorial, we’ll learn to do so.Implementing ExitCodeGenerator:Let’s start by creating a class that implements the ExitCodeGenerator...