An example of creating and using BackendMarker.
search cancel

An example of creating and using BackendMarker.

book

Article ID: 10309

calendar_today

Updated On:

Products

CA Application Performance Management Agent (APM / Wily / Introscope) INTROSCOPE

Issue/Introduction

 This document describes creating a dummy application to simulate a backend metric.



Environment

Any Introscope Java Agent.

Resolution

 1. Create a HelloWorld Dummy application:

import java.util.*;

import java.text.*;

public class ProbedHelloWorld {   

    SimpleDateFormat sdf_ = new SimpleDateFormat();

    Date date_ = new Date();   

    public ProbedHelloWorld() throws Exception {

        Thread.sleep(1000);       

        Properties prop = System.getProperties();

        prop.list(System.out);               

        while (true) {

            callA(1000);

        }

    }  

    public void callA(long time) throws Exception {

        date_.setTime(System.currentTimeMillis());       

        System.out.println(sdf_.format(date_) + " Still running...");       

        Thread.sleep(time);

    }

 

    public static void main(String args[]) throws Exception {

        new ProbedHelloWorld();

    }

}

 

 2. Create a custom PBD: HW.pbd

TurnOn: MyCustomTracerGroup

SetFlag: MyCustomTracerGroup

IdentifyClassAs: ProbedHelloWorld MyCustomTracerGroup

IdentifyInheritedAs: ProbedHellowWorld MyCustomTracerGroup

TraceOneMethodOfClass: ProbedHelloWorld callA BackendMarker "{classname}|{method}"

 

 3. Add HW.pbd to the IntroscopeAgent.profile:

introscope.autoprobe.directivesFile=default-typical-legacy.pbl,hotdeploy,HW.pbd


4. Restart the JVM to instrument the backend metric.


5. See the result in the Investigator:

Additional Information

 

 This document was created to help you with your customization. If any further help is needed relating to this Knowledge Document, please contact your Sales representative for further assistance.

https://techdocs.broadcom.com/us/en/ca-enterprise-software/it-operations-management/application-performance-management/10-7/getting-started/customizations.html

Attachments

1558704369908000010309_sktwi1f5rjvs16qhv.jpeg get_app