OnlyJava is your source for Blog Aggregation in the Java industry

Factory Design Pattern: Introduction, Examples, and Key Points

 Mark As Read    

In the video below, we take a closer look at the factory design pattern and the abstract factory design pattern. We include an introduction, an example, and some key points to help your learning and coding journey. Let's get started!

60x Performance Improvement and Moving on Full-Stack - Day 7: Building DDTJ

 Mark As Read    

Read the previous parts here: Day 1 Day 2 Day 3 Day 4 Day 5 Day 6 Yesterday things started improving and today I'm fully recovered.

Where To Use the Underscore in Java

 Mark As Read    

This series of articles called Stranger things in Java, is inspired by the contents of my book Java for Aliens. These articles are dedicated to insights into the Java language. Deepening the topics we use every day will allow us to master Java coding even in the strangest scenario. In this article, we will try to clarify the use of the underscore s...

DOAG 2021 Conference Report

 Mark As Read    

The DOAG 2021 conference took place November 16-18. This is the long-running annual event organized by the German Oracle technology user community one of the largest in the world. Due to the pandemic, the 2021 event was virtual. There is always some Java-related content in the event, including on Jakarta EE, WebLogic, Coherence, and Helidon. I del...

Good News and Bad News, Pivot and Turn - Day 6: Building DDTJ

 Mark As Read    

Day 1 Day 2 Day 3 Day 4 Day 5 Last week I spent 5 days building and designing the DDTJ project. Hopefully, Ill complete the MVP by this weekend. As we left the series last week, I was stuck. This week theres a bit of an improvement. There are a lot of variations on the good news/bad news joke. Im sure you all know some form of it. Heres a prog...

NullPointerException in Java: Causes and Ways to Avoid It

 Mark As Read    

NullPointerException: the Most Common Exception NullPointerException (NPE) is the most common exception in Java. The cause of this exception is known but looks like that in most cases developers prefer to ignore it and don't take any action. I personally expect that reasons for such behavior are the following: Most of the developers don't see an...

Sentry in Spring Boot application reports uncaught exception while @RestControllerAdvice is handling exception

 Mark As Read    

IntroductionEven when you have a @RestControllerAdvice configured and you know it gets invoked, it can be that Sentry.io's monitoring library still reports it as an (uncaught) exception. Reason for this is that when you configure Sentry as specified without setting its order in the exception-handler-resolver chain, it's by default set as lowest, so...

Tech Team Lead News 823 days ago

How to Practice TDD With Kotlin?

 Mark As Read    

I will start this article by asking you two questions: 1. Do you like writing Tests?

Still Deep in Type Hierarchy Hell Code - Day 5: Building DDTJ

 Mark As Read    

Day 1 Day 2 Day 3 Day 4 Yesterday I was running into a roadblock which unfortunately I still didn't clear today. Theres a point in project development where you feel a bit like those war movie scenes. The hero is surrounded and is just fighting left and right; it seems hopeless, and its unclear how theyll survive. This is where I am right...

Why Does the Java Spring Framework Seem to be the Solution to All Complications?

 Mark As Read    

Java developers worldwide have embraced the Java spring framework because it makes programming Java applications quicker, easier, and safer. More than one million developers have downloaded the SpringSource Tool Suite, which contains the world's most popular enterprise Java framework. Java spring framework provides a consistent set of abstractions ...

End-to-End Debug Object Modeling - First Hard Problem in Building DDTJ: Day 4

 Mark As Read    

Day 1 Day 2 Day 3 Yesterday I got the second PR out of the door (and the 3rd although that was automated). Today wasn't as productive. Winter just started in full force around these parts, and yesterday, everything was flooded. This slowed down some of my work, especially after my son's kindergarten was flooded and he had to stay home. Still, I ...

High-Performance Java Serialization to Different Formats

 Mark As Read    

Java serialization is a popular mechanism where you are able to serialize and deserialize complex object graphs; for example where object A can contain a reference to object B, which in turn has a reference back to object A. The problem is that this rich functionality comes at a performance cost. However, if you do not need to serialize these types...

Code Coverage, Java Debugger API, and Full Integration - Day 3: Building DDJT

 Mark As Read    

Here are Day 1 and Day 2 Yesterday we got the first PR through and now I'm on the second PR.

Documenting the Architecture of Your Projects With the C4 Model

 Mark As Read    

One of the definitions used to approach software architecture is that it is responsible for defining the parts of a project and the technological strategy. And, like any strategy, there must be an ongoing process of review and update. That's why, here on the Zup Open Source team, we're using the C4 model. Having a view of your project's architectur...

The cost of cloud

 Mark As Read    

Putting your IT infrastructure into the cloud seems to be the "in" thing. It's been around for a while, of course. And, like most things related to IT, there are tradeoffs to be made.My rough estimate is that the unit cost of provisioning a service on AWS is about 3 times that of a competent IT organization providing a similar service in house. Oth...

Scaffolding Spring Boot, Freemarker, and JDI - Day 2: Building DDTJ

 Mark As Read    

Yesterday I discussed the first steps in building a new open source project from scratch (which also applies rather nicely to commercial undertakings). Today we continue in the first phase which is scaffolding the actual project and picking the tools. Spoiler, I picked the Spring Boot application framework.

Java: Why a Set Can Contain Duplicate Elements

 Mark As Read    

In low-latency applications, the creation of unnecessary objects is often avoided by reusing mutable objects to reduce memory pressure and thus the load on the garbage collector. This makes the application run much more deterministically and with much less jitter. However, care must be taken as to how these reused objects are used, or else unexpect...

Open Source Software Product Development Day 1: Building DDTJ

 Mark As Read    

Im on a two-week vacation from Lightrun and I have this urge to build something new. I also have a great product idea: DDT. In the past, I built many projects, both commercial and open source. I never documented the complete process. This is something Id like to change. So in this blog, Ill go over that process from concept development to product p...

Keeping Java alive on illumos

 Mark As Read    

Back in 2019, a new JEP (JDK Enhancement Proposal) appeared. JEP 362: Deprecate the Solaris and SPARC PortsOf course, for those of us running Solaris or illumos (which is the same platform as far as Java is concerned), this was a big deal. Losing support for a major language on the platform was potentially a problem.The stated reason for removal wa...

Beautify Third-Party APIs With Kotlin

 Mark As Read    

Scala has popularized the "Pimp my library" pattern: This is just a fancy expression to refer to the ability to supplement a library using implicit conversions.

Showcase 3D Museum Exhibits and Audio Guides

 Mark As Read    

3D technology is developing fast, and more and more museums rely on such technology to hold online exhibitions, opening up history to more people. Users can immerse themselves in online exhibitions through themed virtual environments, stunning lighting effects, and exhibit models that can be enlarged and shrunk, so that visitors can view every deta...

9 Popular React UI Component Libraries for Beginners in 2022

 Mark As Read    

Did you know that according to the survey, 40.14 percent of respondents reported using React.JS, while 34.43 percent were using jQuery? Needless to say, React.js is the most used framework among developers. React powers the user interfaces (UI) of approximately 10 million websites across the internet. Since the base library of React is rigid, ther...

Importance of Learning Java for Cybersecurity

 Mark As Read    

As a new generation of threats pop-up, Java has become one of the most-used programming languages for applications, including cybersecurity. If youre into application development, youll know that Java is ubiquitous for daily use. Knowing the language can be useful for a career in cybersecurity. With that said, its vital to learn not only how to r...

BFO and Log4J

 Mark As Read    

Everyone is asking us about Log4J. Here's a quick statement.

Auto Logging in Class and Method Level Using Custom Annotations in Spring Boot App

 Mark As Read    

It doesn't matter which type or size of software application we are developing, we all come to a point where we want to do a process over and over again but also don't want to re-implement or make a recall every time. This situation is not new nor it is valid for one case. There are many different variations for this situation and as a result many ...

Spring Boot - HATEOAS, Adding Links to API EndPoints | REST API - What is HATEOAS?

 Mark As Read    

In the video below, we are taking a closer look at Spring boot - HATEOAS about how to add links to API endpoints and what is HATEOAS in REST API. Let's get started! Thanks for watching!

EclipseCon 2021 Conference Report

 Mark As Read    

EclipseCon 2021 took place October 25-28. EclipseCon has long been a world-class conference for all things Eclipse. With the Java EE transition to the Eclipse Foundation, EclipseCon has become a truly significant event for Jakarta EE and MicroProfile developers. Due to the pandemic, the 2021 event was virtual (and free!). Jakarta EE unsurprisingly ...

The Full-stack Dev Is Bent Out of T-shape

 Mark As Read    

There are still plenty of openings for full-stack developers. If the stack is the gamut of programming languages, protocols, and middleware to build and maintain a serious internet application, then a full stack developer is the digital Jack of all trades who, contrary to the saying, has mastered them all. I once called myself such, and in 2001 it ...

Spring Boot - RESTful Web Service Endpoint to Delete User and Addresses - @OneToMany Relationship

 Mark As Read    

In the video below, we will take a closer look at Spring Boot - RESTful web service endpoint to delete user and addresses @OneToMany relationship. Let's get started! Thanks for watching!

Java Media Player: Web Browser-Based Approach

 Mark As Read    

If you need to embed a media player into your Java desktop application, there are several options for this: You can use JavaFX Media API to implement all the required media player functionality as shown in this example. A bit outdated but still functional Java Media Framework can be a solution. You can integrate a third-party Java library like ...

Java Web Crawler: Web Browser-Based Approach

 Mark As Read    

There is a lot of data on the Internet now. Often, it needs to be extracted and analyzed for various marketing research and business decision-making purposes. When needed, it should be done quickly and efficiently. Why does one need to collect and analyze data? It may be necessary for a variety of reasons:

WebFlux and Spring Data Example for Java Records

 Mark As Read    

Traditionally, Java developers have depended on constructors, accessors, equals(), hashCode(), and toString() to define classes for basic aggregation of values. However, this is an error-prone approach that adds little value and diverts attention away from modeling immutable data. Java records were initially offered as a preview in JDK 14 to simpl...

Spring Boot - RESTful Web Service Endpoint to Update User and Addresses - @OneToMany Relationship

 Mark As Read    

In the video below, we will take a closer look at Spring Boot - RESTful web service endpoint to update users and addresses @OneToMany relationship. Let's get started! Thanks for watching!

Native-Image With Quarkus

 Mark As Read    

So far, we have looked at how well Spring Boot and Micronaut integrate GraalVM native image extension. In this post, I'll focus on Quarkus: A Kubernetes Native Java stack tailored for OpenJDK HotSpot and GraalVM, crafted from the best of breed Java libraries and standards.

Spring Boot - RESTful Web Service Endpoint to Create User and Addresses @OneToMany Relationship

 Mark As Read    

In the video below, we will take a closer look at Spring Boot - RESTful web service endpoint for creating users and addresses @OneToMany relationship. Let's get started! Thanks for watching!

Java: Migrating From Java 8 to Java 17

 Mark As Read    

This article focuses on the features to use when moving directly from Java 8 to Java 17. If your application is still running on Java 8 in production, then Its difficult to track the features developed after version 8 onwards but there are quite a few easy to use and extremely important features available which can be learned and implemented quickl...

JCON 2021 Conference Report

 Mark As Read    

JCON 2021 took place October 5 to 8. This is a world-class conference run by the German JAVAPRO magazine. Due to the pandemic, the 2021 event was virtual. Jakarta EE had a strong presence at the conference with talks on the Jakarta EE Core Profile, Jakarta EE Security, Jakarta NoSQL, MicroProfile 4, Quarkus, Helidon, and Open Liberty from speakers...

Visualize your Apache Kafka Streams using the Quarkus Dev UI

 Mark As Read    

This article shows how you can visualize Apache Kafka Streams with reactive applications using the Dev UI in Quarkus. Quarkus, a Java framework, provides an extension to utilize the Kafka Streams API and also lets you implement stream processing applications based directly on Kafka. Reactive messaging and Apache Kafka With the rise of event-driven ...

Spring Boot - RESTful Web Service Endpoint for Getting All the Users and Each User Addresses

 Mark As Read    

The video below explains Spring Boot - RESTful web service endpoint for getting all the users and each user's addresses. Let's get started! Thanks for watching!

Our Experience Migrating From Dagger to Koin

 Mark As Read    

Note: This was assembled with Koin version 2.0.1. More recent versions have changed some things. Refer to the official documentation for more information. Context Our team has a legacy project, started by a team from another company, with other standards, practices, experiences, and so on. This project was initially set up with Dagger as a dependen...

Circuit Breaker And Retry with Spring Cloud Resiliance4j

 Mark As Read    

Introduction With the growing number of services, services might need to communicate with other servers synchronously and hence become dependent on the upstream service. Any problems while communicating with the upstream services, will propagate to the downstream services. To protect the services from such problems, we can use some of the patterns...

What Is a Functor? Basic Theory for Java Developers

 Mark As Read    

In general, a Functor is a concept originating from mathematics, to be exact from a part of mathematics called category theory. In my very first article, I described in detail a similar concept known as Monad. Here I want to continue that thread, so I will try to give you some more insight into Functors what they are, how they work, and what the t...

Why General Inheritance Is Flawed and How to Finally Fix It!

 Mark As Read    

General inheritance, whereby a public class is extended over package boundaries, provides a number of challenges and drawbacks and should be avoided in almost all cases. Classes and methods can be made final meaning that subclassing is disallowed which effectively prevents inheritance. While this may sound like a strange thing to do in an object-or...

Spring Boot - RESTful Web Service Endpoint for Getting List of Addresses for a Specific User

 Mark As Read    

In the video below, we take a closer look at Spring Boot - RESTful web service endpoint for getting a list of addresses for a specific user. Let's get started! Thanks for watching!

Fail-Fast Reliable Software Strategy: Debug Failures Effectively

 Mark As Read    

I love cooking and use my Thermomix a lot. If you hadnt heard about that amazing innovation, it's a kitchen robot Well, its a magical super cooking machine. When designing the Thermomix, its designers took the approach of fail-safe instead of fail-fast. This is a smart choice in this case, but it has its drawbacks. E.g. my machine tried to recover...

Spring Boot - RESTful Web Service Endpoint for Getting a Single Address Details for a Specific User

 Mark As Read    

In this video tutorial, we will take a closer look at Spring Boot - RESTful web service endpoint for getting a single address detail for a specific user. Let's get started! Thanks for watching!

JDK 17 - Switch Case Performance

 Mark As Read    

Switch statements in Java have evolved over time. Switch statements supported primitive types at the beginning, then came along String, now JDK17 stable release is out and we have pattern matching which allows us to pass different object types to the switch statement. We can now have switch statements like this: (example taken from Oracle JavaSE 1...

Spring Boot: HATEOAS Introduction

 Mark As Read    

In this video tutorial, we will take a closer look at HATEOAS in Spring Boot. We will also look at REST API and answer questions such as, "What is HATEOAS in REST?" Let's get started! Thanks for watching!

Multiple Spring Boot Applications in the Same Project

 Mark As Read    

I frequently use the Spring Boot framework in my demos. The latest one is no different. It shows how to achieve CQRS using two different code paths: the command part is implemented via Spring Data JPA the query part via jOOQ My use case is a banking application that offers a REST layer allowing clients to call any parts. Demoing the query part ...

Java: Creating Terabyte Sized Queues with Low-Latency

 Mark As Read    

Queues are often fundamental components in software design patterns. But, what if there are millions of messages received every second and multi-process consumer need to be able to read the complete ledger of all messages? Java can only hold so much information before the heap becomes a limiting factor with high-impacting garbage collections as a r...

Java
Welcome!
OnlyJava aggregates blogs for the Java industry.
Custom Feeds
Add any RSS feed to the information you read daily.
Blocked Feeds
Block feeds to remove blogs you’re not interested in.
Account Settings
Customize the site by adding or removing feeds.

About Us

OnlyJava is your source for all your Java news.

Have a Suggestion for Us?
Know of a Java blog that we're missing? Let us know!

Share OnlyJava.com