This page applies to an earlier version of the AppDynamics App IQ Platform.
For documentation on the latest version, see the 4.4 Documentation.


Skip to end of metadata
Go to start of metadata

On this page:

Related pages:

Watch the video: 

Getting Started: AppDynamics for Java

Your Rating:
Results:
PatheticBadOKGoodOutstanding!
58 rates

To monitor Java applications in the Controller, you need to install the AppDynamics Java Agent on each server that hosts applications to be monitored. You then add the Java Agent binary to the Java application process, typically by passing the agent JAR file as a startup argument to the application. This enables the agent to instrument your application and report performance data to the AppDynamics Controller.

This page describes how to install the Java Agent using the Agent Download Wizard in the Controller. If you downloaded the agent from the AppDynamics Download Center, see Install the Java Agent

Before You Begin

  1. Confirm you have access to a controller, the web application where you monitor your application performance:
    • If you use a SaaS controller, AppDynamics sent you the controller host in your Welcome Email.
    • If you use the on-premise controller, you supplied the host and port at install time.
  2. Verify you have root access to run the install on the machine.
  3. Verify support for your environment at Java Supported Environments

Overview of Instrumenting Your Java Application

To instrument your JVM and begin monitoring:

  1. Setup: Use the Agent Download Wizard to set up and download the agent.
  2. Install and configure: Unzip the agent on your server and add it to your JVM startup script.
  3. Apply load and view data: Restart your application and apply load to activate instrumentation.

The following steps provide an overview of how to install that agent. For details, see Install the Java Agent.

Configure and Download the Java Agent

The Agent Download Wizard walks you through steps for configuring and downloading the Java Agent. The wizard presents a few choices, including the type of JVM type (Sun or JRockit or IBM JVMs) of the application you want to monitor and whether it needs to connect to the Controller with SSL. For SSL, enter the SSL port to use (AppDynamics SaaS instances uses port 443 for SSL). 

The wizard takes you through a slightly different flow for a self-service trial edition of the Controller versus a non-trial edition:  

  • If you are using a self-service Pro Trial edition of AppDynamics Pro, the application and tier names are generated for you and not shown as entries in the wizard. This helps you get started quickly. You can always change these values after you understand how you want to model your environment in AppDynamics. See the following section for the automatic-naming format. 
  • If using a non-trial edition, you can configure the application to which the agent will report data and the tier to which the node belongs in the wizard. A node name, the value that identifies an individual JVM in the monitored environment, is generated and inserted into the agent configuration automatically. 

When specifying an application name, keep in mind that this value identifies the business application in the AppDynamics model of your environment to which this agent will report data. Conceptually, an AppDynamics business application does not necessarily correspond to the notion of an application in the monitored environment, where the application is usually thought of, for example, as a WAR file deployed to an application server. A single business application in AppDynamics may contain multiple applications in the monitored environment. For more information about modeling your environment in AppDynamics, see AppDynamics Concepts. 

Each monitored JVM must have a unique node name in AppDynamics. This means that you need to run the wizard for each JVM to monitor, or, after downloading the agent, edit the configuration file that specifies the agent naming properties, controller-info.xml, to at least change the node name value before copying it to other nodes. 

Automatic Naming in a Self-Service Pro Trial

If you are using a self-service trial edition of AppDynamics Pro, AppDynamics names your application, tier, and node dynamically. AppDynamics uses the following naming scheme to identify agents that do not otherwise identify themselves in controller-info.xml or using startup arguments to the JVM:  

  • Application name: MyApp
  • Tier name: MyTier
  • Node name: <app_server_type>@<hostname>:<port> (for example: JBoss@appserver1.example.com:8080)

The automatically generated node name includes the port number that the server listens on. By using the listening port number in the node name, automatic naming ensures that when there are multiple instances of an application server on a single machine, all instances have unique node names.  

Note that the port number used in the node name may not be the primary listening port for the server. If a server listens on multiple ports, automatic naming uses the lowest numbered port in the node name. For example, if a server uses port 8080 as a primary HTTP port but listens for shutdown requests on port 8005, the node will be named with the 8005 port.

For tiers, the Controller automatically recognizes distinct logical tiers based on traffic flow between the nodes and associates the nodes to individual tiers accordingly. All tiers belong to a single business application, MyApp. As you learn more about how you want to organize your applications in AppDynamics, you can change the names of nodes, tiers, or business applications in the Controller UI or in the configuration. 

Install the Agent on the App Server

After you download the agent, install it to your app server. The final window of the Agent Download Wizard includes brief instructions for installing the agent.

  1. Log on as an administrator to the machine running your Java application. Unzip the AppServerAgent.zip file.
    For example, on Linux unzip the agent to home/appdynamics. This is the <agent home> directory.

    unzip AppServerAgent.zip -d /opt/appdynamics/appagent
  2. Edit your startup configuration file to include the Java Agent. 

     Show more information on startup scripts...

View Application Activity in the Controller

Now you're ready to restart your application and view data in the Controller UI:

  1. Restart the JVM.
  2. Apply load to your application.
  3. Log on to the Controller to see your application in action.
     

The agent instruments the application code and reports metrics back to the Controller.

From here, you can install more agents or you can begin monitoring your application environment.

 

  • No labels