Java
-
Mutual TLS (mTLS) between microservices
The role of identity in digital security is crucial, and this extends to microservices. Some security patterns in microservice architecture overly trust the network once a request has passed a certain point, allowing…
-
Serializing/Deserializing OffsetDateTime with Jackson
Serialization and deserialization of `OffsetDateTime` types in Java with Jackson involves converting an `OffsetDateTime` object to a JSON string and vice versa. Jackson provides built-in support for Java 8 date and time API,…
-
Java memory management
The most common memory in a computer is the RAM (Random Access Memory) which stores and accesses data while applications are running. The way in which computer memory works is very similar to…
-
Jackson for JSON marshalling/unmarshalling
What is Jackson? Jackson is a high-performance JSON processor for Java, widely recognized for its ease of use, efficiency, and extensive features. It provides a suite of tools for parsing and generating JSON,…
-
Spring Boot Actuator
Spring Actuator is a powerful tool within the Spring Boot ecosystem that enhances application observability and management by leveraging Micrometer, a vendor-neutral application façade. Here’s why it’s particularly beneficial: Exposing Metrics and Application…
-
Understanding the Spring bean lifecycle
In the Spring Framework, the lifecycle of a Spring bean is orchestrated by the Inversion of Control (IoC) container. This lifecycle is important to understand for any Java developer working with Spring, as…
-
Enumerated Types
Enumerated types, also known as enums, in Java are a special data type that enables a variable to be in a restricted set of named values. The enum keyword offers a way to…
-
Search Algorithms
Linear Search Given an array of n elements, find a specific element (x) in the array and return it’s position. Binary Search Binary search tackles the problem of locating a specific element within…
-
Avoid NullPointerExceptions with Optional
Optionals are commonly used to prevent null references and NullPointerExceptions in Java code. An Optional is a container object which may or may not have a value. To verify if a value exists,…
-
Working with Queues in the Collections Framework
The queue data structure can be useful in algorithms where you need to process data in a sequential order. A queue contains the elements in the order they were added, that is, elements…