Book Image

Oracle Coherence 3.5

By : Aleksandar Seovic
Book Image

Oracle Coherence 3.5

By: Aleksandar Seovic

Overview of this book

Scalability, performance, and reliability have to be designed into an application from the very beginning, as there may be substantial cost or implementation consequences if they need to be added down the line. This indispensible book will teach you how to achieve these things using Oracle Coherence, a leading data grid product on the market.Authored by leading Oracle Coherence authorities, this essential book will teach you how to use Oracle Coherence to build high-performance applications that scale to hundreds of machines and have no single points of failure. You will learn when and how to use Coherence features such as distributed caching, parallel processing, and real-time events within your application, and understand how Coherence fits into the overall application architecture. Oracle Coherence provides a solid architectural foundation for scalable, high-performance and highly available enterprise applications, through features such as distributed caching, parallel processing, distributed queries and aggregations, real-time events, and the elimination of single points of failure.However, in order to take full advantage of these features, you need to design your application for Coherence from the beginning. Based on the authors' extensive knowledge of Oracle Coherence, and how to use it in the real world, this book will provide you with all the information you need in order to leverage various Coherence features properly. It contains a collection of best practice-based solutions and mini-frameworks that will allow you to be more productive from the very beginning.The early chapters cover basics like installation guidelines and caching topologies, before moving on to the domain model implementation guidelines, distributed queries and aggregations, parallel processing, and real-time events. Towards the end, you learn how to integrate Coherence with different persistence technologies, how to access Coherence from platforms other than Java, and how to test and debug classes and applications that depend on Coherence.
Table of Contents (22 chapters)
Oracle Coherence 3.5
Credits
Foreword
About the author
Acknowledgements
About the co-authors
About the reviewers
Preface
12
The Right Tool for the Job
Index

Shutting everything down


Shutting down the .NET application is easy (simply close the application window), and the C++ application is even easier—it terminates automatically after each execution, so there is nothing you need to do.

However, shutting down all server-side components is a bit trickier, especially if you started multiple cache servers. At the very least you will need to shut down the web server, Extend proxy server, and database server.

What makes this even more complicated is that all these processes were started in the background using the Ant script, making them almost invisible. However, if you open Task Manager, you will see a number of java.exe processes running:

So, in order to shut down everything on the server, you can kill java.exe processes one by one in Task Manager.

However, there is an easier way, at least for all processes that are part of the Coherence cluster, which includes the web server, proxy server, and all cache servers you have started.

The Ant build file contains a stop-cluster target, which will send an invocable agent (see Chapter 6, Parallel and In-Place Processing, if you don't remember what that is) that executes System.exit() to all cluster members, effectively shutting them down gracefully.

> ant stop-cluster

However, before you run this task, make sure that your sample application cluster is fully isolated from any other clusters you might have on your network. Otherwise, there is a possibility that the stop-cluster task might decide to send the shutdown agent to your production cluster as well! If you are not sure, be safe and kill the processes from the Task Manager instead.

The last thing you need to do is to shut down the database server as well. You can try to do so by running this Ant task:

> ant stop-db-server

However, my experience so far has been that this task rarely succeeds, so you might need to kill the last remaining java.exe process using Task Manager (or if you have multiple java.exe processes running even after you have shut down the cluster, look for one that uses approximately 30 MB of memory).