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

Linux Commands – top

1. Overview It's quite common to find ourselves in a situation where we need to know the resource usage of each process and thread in our system. For example, we might want to know which process is...

View Article


Causes & Avoidance of java.lang.VerifyError

1. Introduction In this tutorial, we'll look at the cause of java.lang.VerifyError errors and multiple ways to avoid it. 2. Cause The Java Virtual Machine (JVM) distrusts all loaded bytecode as a core...

View Article


Pipes and Redirection in Linux

1. Introduction Most shells offer the ability to alter the way that application input and output flows. This can direct output away from the terminal and into files or other applications, or otherwise...

View Article

Generating Random Dates in Java

1. Overview In this tutorial, we're going to see how to generate random dates and times in bounded and unbounded fashions. We'll be looking at how to generate these values using the legacy...

View Article

Java Weekly, Issue 305

1. Spring and Java >> Spring Cloud Stream – and Spring Integration. [spring.io] Find out how to combine these two to implement function-based streams. >> JVM numeric types – Integer types...

View Article


Image may be NSFW.
Clik here to view.

Practical Application of Test Pyramid in Spring-based Microservice

1. Overview In this tutorial, we'll understand the popular software-testing model called the test pyramid. We'll see how it's relevant in the world of microservices. In the process, we'll develop a...

View Article

Guide to ParameterMessageInterpolator

1. Overview One of the features of Java JSR 380 is allowing expressions while interpolating the validation messages with parameters. When we use Hibernate Validator, there is a requirement that we need...

View Article

Scanner nextLine() Method

1. Overview In this tutorial, we'll briefly look at the nextLine() method of java.util.Scanner class. Furthermore, we'll see an example of its usage. 2. Scanner.nextLine() The nextLine() method of the...

View Article


Hibernate Error “Not all named parameters have been set”

1. Introduction When working with Hibernate, we can use named parameters to safely pass data into an SQL query. We assign values to query parameters at runtime to make them dynamic. More importantly,...

View Article


A Guide to Spring’s Open Session In View

1. Overview Session per request is a transactional pattern to tie the persistence session and request life-cycles together. Not surprisingly, Spring comes with its own implementation of this pattern,...

View Article

Java Weekly, Issue 306

1. Spring and Java >> Azure Spring Cloud Is Now In Public Preview [spring.io] A quick look at the Azure runtime platform for Spring Boot and Spring Cloud, developed jointly by Microsoft and...

View Article

Reading HttpServletRequest Multiple Times in Spring

1. Introduction In this tutorial, we'll learn how to read the body from the HttpServletRequest multiple times using Spring. HttpServletRequest is an interface which exposes getInputStream()  method to...

View Article

Guide to Unix Swap

1. Introduction In this tutorial, we'll introduce the Unix swap space, its advantages, and a few simple commands to manage it. 2. The Unix Swap Space Swap or paging space is basically a portion of the...

View Article


Parsing Command-Line Parameters with JCommander

1. Overview In this tutorial, we'll learn how to use JCommander to parse command-line parameters. We'll explore several of its features as we build a simple command-line application. 2. Why JCommander?...

View Article

The strictfp Keyword in Java

1. Introduction By default, the floating-point computations in Java are platform-dependent. And so, the floating-point outcome's precision depends on the hardware in-use. In this tutorial, we'll learn...

View Article


Encrypting and Decrypting Files in Linux

1. Overview Encryption is the process of encoding data with the intent of keeping it safe from unauthorized access. In this quick tutorial, we'll learn how to encrypt and decrypt files in Linux systems...

View Article

Java Weekly, Issue 307

1. Spring and Java >> Static Data with Spring Boot [reflectoring.io] A good tutorial on externalizing application configuration with @ConfigurationProperties. >> The best way to fix the...

View Article


Image may be NSFW.
Clik here to view.

Determine the Execution Time of JUnit Tests

1. Overview Our builds often run a lot of automated test cases for our project. These include unit and integration tests. If the execution of the test suite takes a long time, we may wish to optimize...

View Article

What is a POJO Class?

1. Overview In this short tutorial, we'll investigate the definition of “Plain Old Java Object” or POJO for short. We'll look at how a POJO compares to a JavaBean, and how turning our POJOs into...

View Article

Image may be NSFW.
Clik here to view.

Is It a Bad Practice to Catch Throwable?

1. Overview In this tutorial, we'll look at the implications of catching Throwable. 2. The Throwable Class In the Java documentation, the Throwable class is defined as “the super-class of all errors...

View Article
Browsing all 3573 articles
Browse latest View live