Hi,
I'm trying to instrument a POJO and split the transaction on one of it's parameters. I don't seem to be getting any success with this feature unfortunately.
The tested transaction initially comes from a servlet (/technical-adapter/reservation) and makes in turn a webservice call (backend).
Here's the java method I'm trying to instrument, it belongs to class "ReservationClient" and is called subsequently when the servlet is called. I'd like to pick up the vName String parameter either in the BT name or at least in the Drill-Down view when the method is involved.
public String reserveSchadennummer(String adresse, String gbstag, String vName, String vOrt, String vPLZ, String unfallZPKT, String vVorname)
In the screenshot I've attached, you can see how I've configured the BT POJO Match Rule. And you can also see that the POJO doesn't show up in the Business Transaction overview, nor does the split parameter show in the Drill Down view.
I've restarted the agent and tried issuing new transactions multiple times. I've also checked that POJO was enabled in the BT Identification configuration.
I've figured that maybe the automatic Servlet Identification was interfering with the detection of my POJO and tried to turn it off, with no better results.
Do you have any suggestions?
--
EDIT : Forgot to add the following lines from the Agent's logs. It seems to have picked up the class but not the method :
[Wed Aug 21 09:57:08 GMT+01:00 2013] Matching class name step/adapters/reservation/ReservationClient [ClassLoader]org.apache.catalina.loader.WebappClassLoader[hashcode]6335685 : Class match found.
[Wed Aug 21 09:57:08 GMT+01:00 2013] Matching class name step/adapters/reservation/ReservationClient Matching class bytecode. : No class match found.
Thanks in advance
Dorian
Hi Dorian,
Thanks for writing to appspshere community forum. We see that you are using class name equals option, but we observed that you have not provided fully qualified class name for "class name (equals)" option, please provide full qualifies classname with complete package name and if you still see the issue, let us enabling servlet filter checkbox or disabling servlet and other entry points apart from pojo entry helps
change class-name (equals) "ReservationClient" to "step.adapators.reservation.ReservationClient" or use contains options instead eqauls option
Also provide the toString() as value in the field "getter chain to run on method parameter" field
Let us know how it goes.
Thanks,
Arun
Hi Arun,
I fixed those mistakes and tried again. Now the BTs are correctly split. Thank you.
Is there a way to also see the parameter in the node name within a snapshot?
----
EDIT: If you don't mind I have a couple of additional questions :
1- If I use the criterion "that extends a Super Class that" or "that implements an Interface that", will I only get classes which directly extend/implement that class/interface, or does it also work in a situation where the target is indirectly extended/implemented (C extends B which extends A, I instrument all classes which extend A, do I see C show up in my BT name?)
2- In that same situation, if A is an abstract class and holds a non-abstract method "m1()", and someone calls C.m1(), which name will I see in my BT / Snaphot : A or C?
Thanks a lot in advance
Dorian
Hi Dorian,
Glad to hear that the pojo splitting is working fine now. Can you please eloborate the query "Is there a way to also see the parameter in the node name within a snapshot?", If you are referring the node name, no we could not see as Lite version can only monitor one jvm/node, and if you are referring to http parameter of the business transaction in snapshot, Lite version does not support diagnostic data collectors config , However in pro version of the product we have feature to collect http parameter values as part of snapshot, let us know if you are interested in our pro version of product.
Regarding the other queries:
Q1: Answer: Yes, that should work when C indirectly extends A as well, let us know if you see any issues.
Q2: Answer: You will see class details of the C as the object is referenced class C.
Hope that clarifies your queries. Do write back to us for further assistance, We will be glad to assist you further.
Thanks,
Arun
Hi Arun,
I was refering to the value passed as parameter of the aforementioned method (reserveSchadennummer), and which is used to discriminate the BT name.
I'm just preparing a set of configuration rules which will soon be deployed in an environment where Pro licenses are deployed. I don't have access to such an environment just yet, so yeah I was just practising a bit on the Lite version.
Thanks for your complementary answers.
Dorian
Hi Dorian,
Thanks for posting back. In lite version of the product we could not collect values passed to method parameters and this is current limitation in lite version of the product. However we are glad to inform that we have feature in our Pro version of product where you can configure custom method invocation data collectors to capture parameters or return value for a particular method. The captured data appears in panels of the snapshot viewer under "User data" section. (refer sample config screenshots how you configure and section expected to see the expected data in pro version of product)
Let us know if that clarifies your query. Do write back to us for further assistance,
Thanks,
Arun