Do you want to know how to develop your skillset to become a Java Rockstar?

Subscribe to our newsletter to start Rocking right now!

To get you started we give you our best selling eBooks for FREE!

 

1. JPA Mini Book

2. JVM Troubleshooting Guide

3. JUnit Tutorial for Unit Testing

4. Java Annotations Tutorial

5. Java Interview Questions

 

and many more ....

 

Receive Java & Developer job alerts in your Area

I have read and agree to the terms & conditions

 

Java 8 Comparator Example

Bipartite Graph

Hello readers, this tutorial explains how to use Lambda expressions in order to improve the boilerplate code of the Comparator written for sorting the list collections.                     1. Introduction The comparator interface has undergone a major overhaul in Java8 while still retaining its essence which is to compare and sort objects ...

Read More »

Spring Boot JDBC Example

Do you want to learn about using Spring Boot with JDBC? Yes? Then you have come to the right place. This example is very straight forward and simple, even a 12 year old can understand. Let’s begin with our Spring Boot JDBC example. 1. Tools Apache Maven Mars Eclipse Spring Boot H2 Database Engine 2. Assumptions This article assumes that ...

Read More »

Apache ActiveMQ File Transfer Example

1. Introduction Apache ActiveMQ (AMQ) is a message broker which transfers messages from sender to receiver. In this example, I will build two simple AMQ applications which will transfer files from one location to another: A producer sends a file via BytesMessage or BlobMessage A consumer receives the BytesMessage or BlobMessage and saves it as a file     2. JMS Message Type JMS ...

Read More »

Java 8 Consumer and Supplier Example

Bipartite Graph

Hello readers, this tutorial explains the in-built functional interfaces (i.e. Consumer<T> and Supplier<T>) introduced in Java8. 1. Introduction These features are the functional interfaces (i.e. an interface with only one abstract method) which belongs to the java.util.function package.           1.1 What is Consumer? Consumer<T> is an in-built functional interface introduced in Java8 in the java.util.function package. ...

Read More »

Java 8 Convert a Stream to List Example

Bipartite Graph

Hello readers, this tutorial explains how to convert a Stream to a List with the help of the following examples. 1. Introduction One of the common problem while working with the Stream API in Java 8 is how to convert a Stream to List in Java because there is no toList() method present in the Stream class. When developers are ...

Read More »

Java 8 Streams: allMatch(), anyMatch(), noneMatch() Example

Bipartite Graph

Hello readers, Java 8 Matching with Streams tutorial explains how to match the elements in a stream using the allMatch(), anyMatch() and noneMatch() methods provided by the Streams API.                 Table Of Contents 1. Introduction 1.1 Stream.allMatch() method 1.2 Stream.anyMatch() method 1.3 Stream.noneMatch() method 2. Java 8 Streams Example 2.1 Tools Used 2.2 ...

Read More »

Apache ActiveMQ Distributed Queue Tutorial

Apache ActiveMQ (AMQ) is an open source messaging server written in Java, which implements JMS 1.1 specifications. In this article, I will demonstrate how to utilize a distributed queue within a group of AMQ brokers.                   Table Of Contents 1. Introduction 2. Apache ActiveMQ Server Installation 3. Producer Java Application 3.1. MessageProducerApp ...

Read More »

Java Servlet Container Example

In this article we will demonstrate deploying and running a simple web application via a servlet container. In addition to demonstrating how to run the sample web application using a servlet container will also show how to run the sample web application using maven from the command line. For this article we will make use of Tomcat 8.5.x both for ...

Read More »

Log4j Rotation Example

This article is a tutorial about log rotation in Log4j. In this tutorial, we are going to configure log4j via property files. 1. Introduction Log4J(Java) is widely used logging framework for Java. It continues to grow continuously with recent upgrade of Log4j2. We want to rotate log files to avoid log file accumulation and easily segregate logs under the log ...

Read More »

Java 8 Predicate Example

Bipartite Graph

Hello readers, this tutorial explains Java 8 predicate example, which has been newly introduced in the java.util.function package. This package describes the Predicate’s usage with the help of multiple examples. 1. Introduction java.util.function.Predicate is the new functional interface defined in the java.util.function package. The Predicate is used in all the contexts where an object needs to be evaluated for a given ...

Read More »