cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Java Agent JAR Location

Hi everyone!

 

Recently, I'm trying to standardize our instrumentation process. I was checking the folder directory of AppDynamics Java Agent and found out that there are two javaagent.jar. One on the root directory, and another one inside the version folder. 

 
  1. What's the difference between the top-level javaagent.jar and the one inside the version folder?
  2. Thinking of the long term, there might be times that we need to update the java agent on the target host. When updating the java agent, we might need to update environment variables, config files, and other critical metrics. With this, is there a possible way to point to the java agent using a standard (non-changing) directory? 
2 REPLIES 2

Ryan.Paredez
Community Manager

Hi @Bryan James.Ilaga,

 

Thanks for posting your question on the Community. I found this AppD Docs page that discusses the Java Agent Directory structure https://docs.appdynamics.com/display/PRO45/Java+Agent+Directory+Structure

 

Note: Be sure to look at the sidebar navigation when viewing this documentation as there could be other useful pages nested.

 

If you gain any insight from that documentation, can you please share what you learned back on this post. This helps keep the knowledge sharing alive in the community. 


Thanks,

Ryan, Cisco AppDynamics Community Manager




Found something helpful? Click the Accept as Solution button to help others find answers faster.

Liked something? Click the Thumbs Up button.



Check out Observabiity in Action

new deep dive videos weekly in the Knowledge Base.

Hi @Ryan.Paredez !

 

Thank you for your reply! I have checked the link you gave and found out the following:

  • conf: Common configuration files. The configuration files in this directory are used by an agent if a more specific version of the configuration file does not exist in the version-specific conf directory, ver<version_number>/conf. 
  • javaagent.jar: The common JAR file used to bootstrap the Java Agent. To enable the agent, pass the fully qualified location of this file as the --javaagent argument value to the JVM at startup.
  • readme.txt: Instructions and notes for installing the Java Agent. 
  • utils: Binary files for utilities shared across versions of the agent.  
  • ver<version_number>: The javaagent.jar file, configuration files, and other resources specific for this version of the Java Agent. This directory is named to reflect the Java Agent version number, such as ver4.4.0.5.
    Among other things, the directory contains: 
    • conf: The configuration files used by this version of the Java agent, including controller-info.xml, app-agent-config.xml, and more. These settings in these files take precedence over the configuration file in the <agent_home>/conf directory. 
    • external-services: Dynamically loaded modules that extend the agent, such as the Analytics Data Sources dynamic service.
    • javaagent.jar: A version-specific JAR file that serves as the Java agent binary. Do not use this Java agent JAR when configuring instrumenting directly. Use javaagent.jar in the root directory instead. 
    • lib: Libraries that support the operation of this version of the Java agent.  
    • logs: Log files written by the agent.
    • sdk: Samples, APIs, and Javadoc for extending the capabilities of the AppDynamics Java Agent.
    • utils: Binary files for utilities that are specific to this version of the agent.

 

So to answer my previous questions:

1. What's the difference between the top-level javaagent.jar and the one inside the version folder?

The top-level javaagent.jar "bootstraps" the one inside the version folder.

 

2. Thinking of the long term, there might be times that we need to update the java agent on the target host. When updating the java agent, we might need to update environment variables, config files, and other critical metrics. With this, is there a possible way to point to the java agent using a standard (non-changing) directory? 

 

It might be possible to just point to the javaagent.jar on root directory.

 

To further validate my understanding, by term "bootstraps", does it mean it calls the java agent inside the version folder? Also on this statement: "The configuration files in this directory are used by an agent if a more specific version of the configuration file does not exist in the version-specific conf directory"; going back to my question number 2. I can still point to the root javaagent.jar, then use the configuration folder on the root directory?