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 ....



How to Create and Run Your First Java Program

1. Introduction This is an in-depth article on how to create and run your first java program. Java compiler is used to compile java code. Java class is the output of the compilation. To execute the program you need java runtime virtual machine. 2. Run Your First Java Program 2.1 Prerequisites Java 7 or 8 is required on the linux, ...

Read More »

Java HashMap vs TreeMap Example

1. Introduction A very important data structure in programming is the Map which is used for extremely fast lookups. In this post, we will take a look at two implementations of the Map data structure in Java, the HashMap and TreeMap classes. The main difference between those two implementations is that the HashMap offers better lookup and insertion times but ...

Read More »

Java Generate Random Integers Example

1. Introduction Java JDK has provided the following utility classes to generate random integers over time: The java.util.Random class from version 1.0, java.util.concurrent.ThreadLocalRandom class from version 1.7, and java.util.SplittableRandom class from version 1.8. These classes provide the nextInt method to generate a random integer and ints method to generate a stream of random integers. Here are the syntax details: /** ...

Read More »

Spring JDBC StoredProcedure Class Example

Stored Procedures are a set of compiled SQL statements residing in the database. In this tutorial, we will explore how to create a simple stored procedure in the MySQL database and call it in a spring boot application. 1. Introduction Spring Boot is a module that provides rapid application development feature to the spring framework including auto-configuration, standalone-code, and production-ready ...

Read More »

Spring Boot JPA MySQL Example

In this example, we will demonstrate how to build a CRUD application using Spring Boot, JPA, and MySQL. 1. Introduction If you worked on enterprise applications in the past, you probably wrote SQL for querying a relational database.  If you are a Java developer, you also had to use JDBC for connecting to the database and executing queries.  (Java Database ...

Read More »

Java 8 Optional In Depth Example

1. Introduction This is an in-depth article about Java 8 Optional. A new class Optional was introduced in Java 8. The optional class is part of java.util package. Optional is used to represent a value. It can be present or absent. No more null checks and NullPointerException are needed. Optional helps in avoiding any runtime NullPointerExceptions. It helps in developing clean ...

Read More »

WebLogic Maven Plugin Example

This article discusses Weblogic(J2EE application server) plugin for Maven, a robust build and dependency manager. 1. Introduction WebLogic is a J2EE application server and also an HTTP web server for Unix, Linux, Microsoft Windows, and other platforms. WebLogic supports Oracle, DB2, Microsoft SQL Server, and other JDBC-compliant databases. It provides a standard set of APIs for creating distributed Java applications ...

Read More »

Java ArrayList vs LinkedList Example

1. Introduction One of the most commonly used data structures in programming is the Array. Java comes with two implementations of the Array data structure, the ArrayList and LinkedList classes. In a nutshell, the ArrayList is a resizable-array implementation, whereas the LinkedList is a doubly-linked list implementation. In this post, we will cover the differences between the methods and time ...

Read More »

JSF Backing Bean Example

With this example, we are going to demonstrate how to use Backing Bean in JavaServer Faces (JSF) to develop a Web Application by using three programs. 1. What is JavaServer Faces (JSF)? JavaServer Faces (JSF) is used as a Component-based web framework that implements a Model-View-Controller design pattern for developing web applications. 2. Overview of JavaServer Faces (JSF) It uses ...

Read More »

Java Copy Array Example

1. Introduction Java array is an object which represents a data structure that contains elements of a similar data type. Array in java is index-based, the first element of the array is stored at the 0 index. Java has provided several ways to copy an array over time: System.arraycopy – provided since version 1.0. It copies an array from a ...

Read More »