Book Image

Oracle JRockit: The Definitive Guide

Book Image

Oracle JRockit: The Definitive Guide

Overview of this book

Oracle JRockit is one of the industry’s highest performing Java Virtual Machines. Java developers are always on the lookout for better ways to analyze application behavior and gain performance. As we all know, this is not as easy as it looks. Welcome to JRockit: The Definitive Guide.This book helps you gain in-depth knowledge of Java from the JVM’s point of view. We will explain how to write code that works well with the JVM to gain performance and scalability. Starting with the inner workings of the JRockit JVM and finishing with a thorough walkthrough of the tools in the JRockit Mission Control suite, this book is for anyone who wants to know more about how the JVM executes your Java application and how to profile for better performance.
Table of Contents (23 chapters)
Oracle JRockit
Credits
Foreword
About the Authors
Acknowledgement
About the Reviewers
Preface
12
Using the JRockit Management APIs
Bibliography
Glossary
AST
CAS
HIR
IR
JFR
JMX
JRA
JSR
LIR
MD5
MIR
PDE
RCP
SWT
TLA
Index

JMAPI


The first API we will discuss is called JMAPI, short for the JRockit Management API. It is a lightweight Java-only API which provides in-process access to various management features. This API has existed since very early versions of JRockit. However, parts of the API were marked as deprecated in R28.0.0 and its future is uncertain.

JMAPI was the JVM-side API that enabled the functionality of the earliest versions of the JRockit Management Console. In fact, even today, if a connection is established to a 1.4 version of JRockit, a proprietary internal protocol called the Rockit Management Protocol (RMP) will be used. This protocol will, in turn, use JMAPI to gather data and change the various runtime parameters of the JVM.

The next few pages contain various examples of things that can be done using JMAPI. The easiest way to compile the examples is to use the JRockit JDK. This requires no special configuration, as the necessary classes are available in the JRockit rt.jar that is part...