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

cancel
Showing results for 
Search instead for 
Did you mean: 

AppdynamicsAgent.startTransaction/endTransaction never shows in BT list

Gabor.Liptak
Wanderer

AppdynamicsAgent.startTransaction/endTransaction never shows in BT list

I followed coding snippets at

https://docs.appdynamics.com/display/PRO45/Java+Agent+API+User+Guide

 

marking business transactions and they don't show up in the BT list for the application.

 

With basic code

 

public String checkout(List<ItemOrders> orders) {
   try (Transaction transaction = AppdynamicsAgent.startTransaction("Checkout", null, EntryTypes.POJO, false)) {
        /*******************
         * Method Body Here
         *******************/
    }
}
 

I also reviewed https://community.appdynamics.com/t5/Knowledge-Base/Why-aren-t-business-transactions-appearing-in-th... but that page doesn't address API created transactions.

 

Any pointers on how this can be debugged?

AppdynamicsAgent.startTransaction/endTransaction never shows in BT list
5 REPLIES 5
Peter.Holditch
Moderator

Re: AppdynamicsAgent.startTransaction/endTransaction never shows in BT list

2 thing to check:

  1. Are there any error or informational messages written in the agent log?
  2. Have you hit the node or application level BT limit?

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.
Gabor.Liptak
Wanderer

Re: AppdynamicsAgent.startTransaction/endTransaction never shows in BT list

Peter, thank you for the pointers.

 

I didn't see related messages in the logs. I did put in log statements into the code to validate that the code is called.

 

I see about ~15 BTs listed so with default limit of ~40(?) BTs it is under.

Peter.Holditch
Moderator

Re: AppdynamicsAgent.startTransaction/endTransaction never shows in BT list

Hm, OK.

 

Your code does. not show you calling endTransaction, but you do mention that in the subject.

 

Are you certain your code is calling endTransaction?

 

Also, how many times in the transaction you have instrumented being executed?

 

Do you see it referenced if you remove the (default) filter for Transactions with performance data?

 

 
 


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

Re: AppdynamicsAgent.startTransaction/endTransaction never shows in BT list

Peter, I coded both direct startTransaction()/endTransaction() and just try/startTransaction() to no avail. After further experiments, I do see some transactions displayed after cleanup and restart (of my client).

 

The listed code is from AppD documentation and it calls closeTransaction() during completion of the "try" section.

 

I have to manually create load on my current setup.

Peter.Holditch
Moderator

Re: AppdynamicsAgent.startTransaction/endTransaction never shows in BT list

Gabor,

 

My bad, I missed the local-to-the-try-catch-block constructed Transaction object when I looked at your code.

 

From your latest comments, it sounds as if this is working as expected.  The 1st time your entry is called within a new process, the BT will register with the controller.  Once that is done, subsequent invocations handled in the same process will be measured, and as those measurements are reported by the agent (once per minute) the data will become visible in the controller.

 

I suspect you eventually amassed enough post-registration invocations and elapsed time for that to happen.

 

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.