Home » Archives for Mary Zheng » Page 13

Author Archives: 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.

Apache ActiveMQ Failover Example

Apache ActiveMQ is an open source messaging server written in Java, which implements JMS 1.1 specifications. In this example, I will demonstrate how to configure a group of AMQ brokers to make the system fault-tolerant.                 Table Of Contents 1. Introduction 2. Apache ActiveMQ Server Installation 3. Apache ActiveMQ Server Configuration 3.1 Two ...

Read More »

Apache ActiveMQ Load Balancing Example

1. Introduction Apache ActiveMQ (AMQ) is a message broker which transfers the message from the sender to the receiver. Load Balancing is the process of distributing data across services for better performance. In this example, we will demonstrate how to build a load-balanced AMQ client application.           2. The Component Diagram In this example, we will demonstrate two forms of load ...

Read More »

Apache ActiveMQ Best Practices Tutorial

Apache ActiveMQ is an open source messaging server written in Java which implements JMS 1.1 specifications. In this tutorial, you will learn how to develop a few Java applications which integrate ActiveMQ to send and receive messages to and from destinations. If you already know how to install and configure ActiveMQ, you can skip the first four chapters.       ...

Read More »

Java Quartz vs Spring Batch Example

1. Introduction This example shows how to build a Quartz scheduler and Spring Batch application. Both applications execute a business task repeatedly in a different way. Quartz is an open source library designed to schedule a job for enterprises. Quartz application repeatedly executes the job based on the scheduled time. Spring Batch is an open source framework designed to enable the development ...

Read More »

Java Quartz Scheduler vs Java Timer Example

1.Introduction This example builds two java scheduler applications: one utilizes Quartz scheduler and the other uses java built-in Timer library. Quartz – an open source library, enables enterprise to schedule a job/task at a specific date and time.  It provides operations to scheduling/unscheduling jobs, starting/stopping/pausing the scheduler. JDK built-in Timer library enables an application to run the task in a ...

Read More »

Multithreading in Java Tutorial

In this post, we feature a comprehensive Multithreading in Java Tutorial. Multithreading is the ability of a program to manage its use by more than one user and even to manage multiple requests by the same user. In the Java programming language, concurrent programming is the execution of processes and threads. Java has supported java.lang.Thread since JDK 1.0. The java.util.concurrent ...

Read More »

Java Treemap – java.util.TreeMap Example

1. Introduction In this example we will see how and when to use the Java Treemap class java.util.TreeMap. A TreeMap is a Red-Black tree based NavigableMap implementation which has log(n) time cost for the basic operations: add, remove, and contains. A TreeMap guarantees that the elements inserted remains sorted on the order of keys. The elements are ordered using the ...

Read More »

Java Annotations Example

1. Introduction Java Annotations are special metadata instructions included in the source code of a program which starts with the @ symbol and can be applied to a class, method, field, parameter, variable, constructor, and package. They were introduced in Java 5 under JSR-175 to reduce the XML usage for metadata, which tends to become complicated and cumbersome. It was ...

Read More »

StringBuilder Java Example

In this post, we feature a comprehensive StringBuilder Java Example. StringBuffer in Java is the same as StringBuilder, but the first is thread-safe. At the end of this article, we will create an abstract TestBase class which shows StringBuffer ‘s common methods. 1. Introduction StringBuilder object seems like a String object but with the characteristics of an array. Every object ...

Read More »

2D Array Java Example

In this post, we feature a comprehensive 2D Array Java Example. Java support one dimensional, two dimensional and generally multidimensional arrays. 1. Introduction An array is a container object that holds a fixed number of values of a single type. The length of an array is established when the array is created. Java gives us the opportunity of using arrays with ...

Read More »