Get the Schema From an Avro File
1. Introduction In this tutorial, we’ll explore how to extract the schema from an Apache Avro file in Java. Furthermore, we’ll cover how to read data from Avro files. This is a common requirement in...
View ArticleJava Weekly, Issue 565
1. Spring and Java >> Exploring New Features in JDK 23: Just-Write-And-Run prototyping with JEP-477 not only for beginners [foojay.io] Quick prototyping made much easier with JDK 23. A long time...
View ArticleValidation Using Yavi
1. Introduction Yavi is a Java validation library that allows us to easily and cleanly ensure that our objects are in a valid state. Yavi is an excellent lightweight choice for object validation within...
View ArticleInvoke a GoLang Function from Java
1. Introduction As we know, Java and Go are two prominent programming languages, each excelling in different domains. Java is renowned for its portability and extensive ecosystem, while Go is...
View ArticleIntroduction to Apache Iceberg
1. Introduction This tutorial will discuss Apache Iceberg, a popular open table format in today’s big data landscape. We’ll explore Iceberg’s architecture and some of its important features through a...
View ArticleHow to Mock Multiple Responses for the Same Request
1. Overview In this article, we’ll explore how to mock multiple responses for the same request using MockServer. A MockServer simulates real APIs by mimicking their behavior, allowing us to test...
View ArticleGuide to Prometheus Java Client
1. Introduction As distributed systems become more complex, monitoring becomes crucial to maintaining application performance and quickly identifying issues. One of the best tools for this is...
View ArticleAspectJ Pointcut For All Methods Inside Package
1. Overview AspectJ is a powerful tool for handling cross-cutting concerns like logging, security, and transaction management in Java applications. A common use case is applying an aspect to all...
View ArticleIntroduction to Jakarta Persistence 3.2
1. Introduction Jakarta Persistence (formerly JPA) is the standard API for object-relational mapping in Java. It enables developers to manage relational data in Java applications and simplifies...
View ArticleIntroduction to S3proxy
1. Overview Amazon S3 has cemented itself as the most widely used cloud storage backend due to its scalability, durability, and extensive feature set. This is evident by the fact that many other...
View ArticleHow to Tear Down or Empty HSQLDB Database After Test
1. Overview When writing integration tests, maintaining a clean database state between tests is crucial for ensuring reproducible results and avoiding unintended side effects. HSQLDB (HyperSQL...
View ArticleHow to Convert OpenAPI 2.0 to OpenAPI 3.0 in Java
1. Introduction Although the OpenAPI 3.x Specification has been available since 2017 and has gone through several updates, many APIs continue using older versions. In this tutorial, we’ll explore the...
View ArticleJava Weekly, Issue 566
1. Spring and Java >> Let’s use OpenTelemetry with Spring [spring.io] A solid look at how Spring integrates the OpenTelemetry protocol in the strong observability track within the Spring...
View ArticleHow to Handle “MysqlDataTruncation: Data truncation: Data too long for column”
1. Overview The Java Database Connectivity (JDBC) Application Programming Interface (API) provides a set of classes and interfaces. We can use these to connect to data sources such as relational...
View ArticleConnecting to Remote MySQL Database Through SSH Using Java
1. Overview Secure Shell (SSH) allows us to securely access and manage remote systems, including executing commands, transferring files, and tunneling services. We can establish a connection to a...
View ArticleComparison of HSSFWorkbook, XSSFWorkbook, and SXSSFWorkbook in Apache POI
1. Overview Apache POI is an open-source library that allows us to work programmatically with Microsoft Office documents, including Excel. Apache POI has three different classes that can be used to...
View ArticleSign CSR Using Bouncy Castle
1. Overview Signing a Certificate Signing Request (CSR) is a common operation in cryptography. In this tutorial, we’ll learn how to sign a CSR using the Bouncy Castle library. 2. Signing a CSR Signing...
View ArticleFinding IP Address of a URL in Java
1. Overview The Internet Protocol address – IP – is a unique identifier assigned to each device connected to a computer network. It allows devices to communicate with each other over the Internet. In...
View ArticlePass Collection as Varargs Argument
1. Overview In this tutorial, we’ll explore different approaches to supply a Collection as an argument for a varargs parameter. 2. What’s a Varargs Parameter? Variable arguments, or varargs for short,...
View ArticleHow to use virtual threads with ScheduledExecutorService
1. Introduction Virtual threads are a useful feature officially introduced in JDK 21 as a solution to improve the performance of high-throughput applications. However, the JDK has no built-in...
View Article