Java (Java Agent, Installation, JVM, and Controller Installation)

cancel
Showing results for 
Search instead for 
Did you mean: 

How to configure Appdynamics with SpringBoot Application

Adventurer

How to configure Appdynamics with SpringBoot Application

Hi Team, Please provide the steps to configure Appdynamic with SpringBoot application in local machine.

 

I got 15 days Apdynamicsportatl  free , 

I created springboot rest Appliciaton and it is workign fine

Login to Appdynamic portal and went to gettingstarted , downloaded java agent .  I couldnt find much steps in appdynamic documentation.

 

I need steps to further integration with SpringBoot Applicaiton. Please help on this.

 

Thanks,

Ashok

How to configure Appdynamics with SpringBoot Application
10 REPLIES 10
Moderator

Re: How to configure Appdynamics with SpringBoot Application

Ashok,

 

Your first step will be to introduce the AppDynamics java agent into the JVM running your Spring Boot application.

 

This process is described here.

 

Warm regards,
Peter

 



Found something helpful? Click the Accept as Solution button to help others find answers faster.
Liked something? Click the Thumbs Up button.
New Poster

Re: How to configure Appdynamics with SpringBoot Application

Explorer

Re: How to configure Appdynamics with SpringBoot Application

I added the javaagent path in the VM argument of spring boot application in eclipse like below. But when I start my application, application gets start and I am not seeing any message related to java agent starting also I am not seeing any connection established from agent to controller on controller UI. Cloud you please help to identify the issue here.

 

-Djavaagent:D:/Applogs/appagent/javaagent.jar


@Peter.Holditch wrote:

Ashok,

 

Your first step will be to introduce the AppDynamics java agent into the JVM running your Spring Boot application.

 

This process is described here.

 

Warm regards,
Peter

 


 

Moderator

Re: How to configure Appdynamics with SpringBoot Application

The correct option to load an agent into the JVM is "-javaagent", not "-Djavaagent"

 

I hope that helps.  If not, please post full detail of your command line.



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

Re: How to configure Appdynamics with SpringBoot Application

I tried that as well but didn't work. Below is the exact parameter I have added as VM arguments in eclipse. Agent is not getting start

 

appdynamicsagentConf.JPG

I have started the spring boot in command line using below command still didn't work. 

java -javaagent:D:/Applogs/appagent/javaagent.jar -jar loan-origination-0.0.1-SNAPSHOT.jar

 

Appreciate if your help to resolve this issue.

Moderator

Re: How to configure Appdynamics with SpringBoot Application

Do you see any agent logs written under D:/Applogs/appagent/ver4.x.y.x/logs/<nodename>?

 

What happens if you run

"java -version -javaagent:D:/Applogs/appagent/javaagent.jar" 

from the command line?



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

Re: How to configure Appdynamics with SpringBoot Application

I don't see any log file generated under D:/Applogs/appagent/ver4.x.y.x/logs/

 

When I did java -version -javaagent:D:/Applogs/appagent/javaagent.jar" it printed below,

java -version D:\Applogs\AppServerAgent-4.5.9.25648\javaagent.jar
openjdk version "1.8.0_202"
OpenJDK Runtime Environment (build 1.8.0_202-b08)
Eclipse OpenJ9 VM (build openj9-0.12.1, JRE 1.8.0 Windows 10 amd64-64-Bit Compressed References 20190205_265 (JIT enabled, AOT enabled)
OpenJ9 - 90dd8cb40
OMR - d2f4534b
JCL - d002501a90 based on jdk8u202-b08)

Moderator

Re: How to configure Appdynamics with SpringBoot Application

Sorry, my mistake, I reversed the options.

 

What happens when you run:

 

"java -javaagent:D:/Applogs/appagent/javaagent.jar -version"



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

Re: How to configure Appdynamics with SpringBoot Application

after issuing the above command below is the result.

>java -javaagent:D:\Applogs\AppServerAgent-4.5.9.25648\javaagent.jar -version
Full Agent Registration Info Resolver using selfService [true]
Full Agent Registration Info Resolver using selfService [true]
Full Agent Registration Info Resolver using application name [LoanApplication]
Full Agent Registration Info Resolver using tier name [ApplicationTier]
Full Agent Registration Info Resolver using node name [SurajLocalNode]
Install Directory resolved to[D:\Applogs\AppServerAgent-4.5.9.25648]
Agent conf directory set to [D:\Applogs\AppServerAgent-4.5.9.25648\ver4.5.9.25648\conf]
[Thread-0] Tue Jun 11 17:29:00 IST 2019[DEBUG]: AgentInstallManager - Full Agent Registration Info Resolver is running
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: AgentInstallManager - Full Agent Registration Info Resolver using selfService [true]
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: AgentInstallManager - Full Agent Registration Info Resolver using selfService [true]
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: AgentInstallManager - Full Agent Registration Info Resolver using application name [LoanApplication]
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: AgentInstallManager - Full Agent Registration Info Resolver using tier name [ApplicationTier]
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: AgentInstallManager - Full Agent Registration Info Resolver using node name [SurajLocalNode]
[Thread-0] Tue Jun 11 17:29:00 IST 2019[DEBUG]: AgentInstallManager - Full Agent Registration Info Resolver finished running
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: AgentInstallManager - Agent runtime directory set to [D:\Applogs\AppServerAgent-4.5.9.25648\ver4.5.9.25648]
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: AgentInstallManager - Agent node directory set to [SurajLocalNode]
Agent runtime conf directory set to D:\Applogs\AppServerAgent-4.5.9.25648\ver4.5.9.25648\conf
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: AgentInstallManager - Agent runtime conf directory set to D:\Applogs\AppServerAgent-4.5.9.25648\ver4.5.9.25648\conf
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: JavaAgent - Using Java Agent Version [Server Agent #4.5.9.25648 v4.5.9 GA compatible with 4.4.1.0 r24edb4ba5d4cc80793b2d5806ddf9cf8044e87b0 pull-requests/2158]
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: JavaAgent - Running IBM Java Agent [No]
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: JavaAgent - Java Agent Directory [D:\Applogs\AppServerAgent-4.5.9.25648\ver4.5.9.25648]
[Thread-0] Tue Jun 11 17:29:00 IST 2019[INFO]: JavaAgent - Java Agent AppAgent directory [D:\Applogs\AppServerAgent-4.5.9.25648\ver4.5.9.25648]
Agent logging directory set to [D:\Applogs\AppServerAgent-4.5.9.25648\ver4.5.9.25648\logs]
2019-06-11 17:29:00,793 INFO Log4j appears to be running in a Servlet environment, but there's no log4j-web module available. If you want better web container support, please add the log4j-web JAR to your web archive or server lib directory.
Running obfuscated agent
Started AppDynamics Java Agent Successfully.
java version "1.8.0_141"
Java(TM) SE Runtime Environment (build 1.8.0_141-b15)
Java HotSpot(TM) 64-Bit Server VM (build 25.141-b15, mixed mode)

 

Logs are created now but when I issue the below command I don't see agent started message

java -javaagent:D:\Applogs\AppServerAgent-4.5.9.25648\javaagent.jar -Dappdynamics.http.proxyHost=10.74.91.103 -Dappdynamics.http.proxyPort=80 -jar loan-origination-0.0.1-SNAPSHOT.jar