Quantcast
Channel: Baeldung
Browsing all 3605 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

Quarkus Testcontainers for Dependent Services

1. Overview In this article, we’ll see the power of using Testcontainers to help test a Quarkus application using ‘live’ service-to-service testing. Testing in a microservices architecture is important...

View Article


Image may be NSFW.
Clik here to view.

Literal Syntax for byte[] Arrays Using Hex Notation

1. Introduction Java provides various ways to work with byte[] arrays, which are essential for handling binary data. While initializing a byte[] array with decimal values is straightforward, using...

View Article


Image may be NSFW.
Clik here to view.

Checking if a File is an Image in Java

1. Overview When working with file uploads in Java, it’s crucial to ensure that the uploaded files are indeed images, especially when filenames and extensions can be misleading. In this tutorial, we’ll...

View Article

Image may be NSFW.
Clik here to view.

How to Convert Gson JsonArray to HashMap

1. Introduction In this tutorial, we’ll explore how to convert a Gson JsonArray to a HashMap in Java. By the end of this tutorial, we’ll understand the process of iterating over a JsonArray, extracting...

View Article

Image may be NSFW.
Clik here to view.

Introduction to Milvus

1. Overview In this tutorial, we’ll explore Milvus, a highly scalable open-source vector database. It’s designed to store and index massive vector embeddings from deep neural networks and other...

View Article


Image may be NSFW.
Clik here to view.

Convert Between org.joda.time.DateTime and java.sql.Timestamp in Java

1. Overview Handling timestamps in Java is a common task that allows us to manipulate and display date and time information more еffеctivеly еspеcially when we’re dealing with databases or global...

View Article

Image may be NSFW.
Clik here to view.

Java Weekly, Issue 552

1. Spring and Java >> JFR Event to Detect Invocations of Deprecated Methods [inside.java] New in JDK 22, a JFR event to detect invoked deprecated methods — useful for finding the deprecated...

View Article

Image may be NSFW.
Clik here to view.

Difference Between M2_HOME, MAVEN_HOME and using the PATH variable

1. Overview As part of the Apache Maven installation process, we need to configure various environment variables to ensure our Maven installation works smoothly. In this tutorial, we’ll look at three...

View Article


Image may be NSFW.
Clik here to view.

Add Jar Files to Java Project Using Visual Studio Code

1. Overview The Visual Studio Code (VSCode) editor is gaining popularity among Java developers. According to a survey by Baeldung, VSCode ranks third among Integrated Development Environments (IDEs)...

View Article


Image may be NSFW.
Clik here to view.

How to Add String Arrays to ArrayList in Java

1. Overview In Java, ArrayList is a commonly used List implementation. There are scenarios when we might need to add elements from multiple String arrays to an ArrayList. In this quick tutorial, let’s...

View Article

Image may be NSFW.
Clik here to view.

How to Sort Map Value List by Element Field Using Java Streams

1. Overview In this tutorial, we’ll explore the benefits of Streams API in sorting elements in a List stored within a Map. In the process, we’ll also compare it with the more traditional approach of...

View Article

Image may be NSFW.
Clik here to view.

@ExtensionMethod Annotation in Lombok

1. Overview Lombok is a popular Java library that simplifies code writing by reducing boilerplate code. One of its powerful features is the @ExtensionMethod annotation, which enhances the readability...

View Article

Image may be NSFW.
Clik here to view.

Forcing Jackson to Deserialize to Specific Type

1. Overview In this tutorial, we’ll explore how to force Jackson to deserialize a JSON value to a specific type. By default, Jackson deserializes JSON values to a type specified by the target field....

View Article


Image may be NSFW.
Clik here to view.

Find the Substring After the Last Pattern in Java

1. Overview In Java, there are many situations where we need to extract a substring that appears after the last occurrence of a specific pattern in a given String. This can be particularly useful when...

View Article

Image may be NSFW.
Clik here to view.

Sort an Array of Strings According to String Lengths

1. Overview In this tutorial, we’ll explore different approaches to sorting a string array according to the element’s length. 2. Comparator When we work on sorting in Java, we often define a Comparator...

View Article


Image may be NSFW.
Clik here to view.

Generate a Random Hexadecimal Value in Java

1. Introduction Random hexadecimal values in applications can serve as unique identifiers for various purposes like database entries, session tokens, or game mechanics. They can also contribute to...

View Article

Image may be NSFW.
Clik here to view.

PSQLException: The Server Requested Password-Based Authentication

1. Introduction A common pitfall when configuring a Datasource for our Spring Boot project with a PostgreSQL database is providing the wrong password for the database connection or even forgetting the...

View Article


Image may be NSFW.
Clik here to view.

Getting Started with MongoDB and Quarkus

1. Introduction Quarkus is a popular Java framework optimized for creating applications with minimal memory footprint and fast startup times. When paired with MongoDB, a popular NoSQL database, Quarkus...

View Article

Image may be NSFW.
Clik here to view.

Setup MySQL DB in Eclipse

1. Overview Connecting to a MySQL database from Eclipse can offer several benefits, especially if we’re working on database-driven applications. For example, we can use a local MySQL database to test...

View Article

Image may be NSFW.
Clik here to view.

Returning Errors Using ProblemDetail in Spring Boot

1. Overview In this article, we’ll explore using ProblemDetail to return errors in Spring Boot applications. Whether we’re handling REST APIs or reactive streams, it offers a standardized way to...

View Article
Browsing all 3605 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>