Home » Archives for Mary Zheng

Author Archives: Mary Zheng

Mary Zheng
Mary has graduated from Mechanical Engineering department at ShangHai JiaoTong University. She also holds a Master degree in Computer Science from Webster University. During her studies she has been involved with a large number of projects ranging from programming and software engineering. She works as a senior Software Engineer in the telecommunications sector where she acts as a leader and works with others to design, implement, and monitor the software solution.

Java Virtual Machine Tutorial

1. Introduction Java Virtual Machine (JVM) is a type of process virtual machine which designs to execute Java computer programs in a platform-independent environment. It was first released by Sun Microsystems in 1994 and then split into JVM specification and implementation in 2006. The JVM specification is maintained by Java Community Process (JCP). Click here for a list of JVM ...

Read More »

Java Swagger Tutorial

In this article, we will explain Java Swagger through a tutorial with examples. 1. Introduction Swagger was first released in 2011 to ease the Restful API documentation and client SDK generation during the development of Wordnik‘s products. In 2015, SmartBear software company donated the Swagger specification to open source which is sponsored by Linux Foundation, Google, IBM, and Microsoft. The ...

Read More »

The Difference Between map() and flatMap() Methods in Java

In this article, we are going to see the difference between map and flatMap methods in Java. 1. Introduction Java has provided Stream interface since version 8. The map() and flatMap() are two intermediate operations. Here are the method signatures: /* Returns a stream consisting of the results of applying the given function to the elements of this stream. Type ...

Read More »

Docker vs Kubernetes: The most important differences

In this article, we will introduce you to Docker vs Kubernetes and their most important differences. 1. Introduction Docker and Kubernetes are two open-source tools that work together to ensure that an application works anywhere and runs at the desired state all the time. The following diagram outlines developing, packaging, and deploying steps utilizing Docker and Kubernetes. Figure 1 Application ...

Read More »

What is Kubernetes

1. Introduction Kubernetes(k8s) is an open-source container-orchestration management tool that ensures that containers run in the “desired state” all the time. It was developed by Google and released as an open-source project in 2015. The word Kubernetes means “helmsman” in ancient Greek. Kubernetes is a tool that manages containers with easy deployment, monitoring, scalability, and auto-recovery. According to Kubernetes architecture, ...

Read More »

Hello World Docker Image

In this article, we will show how to build and run a Hello World Docker Image. 1. Introduction A Docker container image is a lightweight, standalone, and executable software package that includes everything needed to run an application. It uses the underlying operating system resources. In this example, I will use “Docker Desktop for Windows” to demonstrate: Build a “Hello ...

Read More »

Java POJO and Java Bean Example

1. Introduction POJO stands for a Plain Old Java Object. It’s a term coined by Martin Fowler, Rebecca Parsons, and Josh MacKenzie while preparing for a conference in September 2000. POJO is an ordinary Java object which doesn’t tie to any framework or external reference. It has no naming rule for its methods nor data members. Java Bean is a ...

Read More »

Java Array Contains Example

1. Introduction An array is a container object that holds a fixed number of elements with a single type. Java not only provides Arrays to copy, sort, and search elements, it also provides the collection framework to check if a certain value in a collection with the contains method. In this example, I will demonstrate: Find an element in a ...

Read More »

Serializable Java Example – How to serialize and deserialize objects

In this article, we will discuss what is Serializable in Java using examples and how to serialize and deserialize objects. 1. Introduction Serialization is the process of converting an object into a stream of bytes. De-serialization is the reverse process which converts a stream of bytes into an object. Java provides a Serializable marker interface, ObjectInputStream, and ObjectOutputStream classes to ...

Read More »

Default Constructor Java Example

In this post, we feature an example of the Default Constructor in Java. 1. Introduction When the Java compiler compiles the Java source code (.java) into the Java byte code (.class), it will create a public no-argument constructor for the class if it has no constructor defined. This public no-argument constructor is called a default constructor. Its implementation body only ...

Read More »