DX Application Performance Management

Expand all | Collapse all

REST API for CA APM open alerts (APM SaaS for DXI)

  • 1.  REST API for CA APM open alerts (APM SaaS for DXI)

    Posted Sep 14, 2018 01:28 AM

    Hi all,

    I Want to get all open alerts(Danger and Caution) from CA APM using REST API.

    I have searched CA documentation but not able to find any.

    Please suggest me how can I do so.

    Thanks in advance.

    Arpan



  • 2.  Re: REST API for CA APM open alerts

    Broadcom Employee
    Posted Sep 14, 2018 02:59 AM

    Hi Arpan,

    I might be wrong but I don't think it is possible via REST API or SQL REST API

    You can do it with Command Line Workstation:

    java .... -jar CLWorkstation.jar query state of alerts matching (.*) in management modules matching (.*)

    More details here: CLW Command Reference - CA Application Performance Management - 10.7 - CA Technologies Documentation 

     

    Hope it helps.

     

    Regards,

     

    Lynn



  • 3.  Re: REST API for CA APM open alerts

    Posted Sep 14, 2018 03:06 AM

    Hi Lynn,

    thanks for quick response.

    I'm looking at the link, but can you tell me from where I can get "CLWorkstation.jar".



  • 4.  Re: REST API for CA APM open alerts

    Broadcom Employee
    Posted Sep 14, 2018 03:17 AM

    Hi,

     

    The alert status is stored as a metric value SuperDomain|Custom Metric Host|Custom Metric Process|Custom Metric Agent|Alerts|{MM name}|{Alert name} so you can query the status of an/all alerts using APM SQL but speicifying the time range may not be so simple to do though

     

    The CLWorkstation.jar should be found in the lib folder under the EM installation

     

    thanks

    Mike



  • 5.  Re: REST API for CA APM open alerts

    Broadcom Employee
    Posted Sep 14, 2018 03:29 AM

    Thanks Mike!

    So Arpan using the correct metric_path it should be possible with SQL REST API 

    SQL REST API - CA Application Performance Management - 10.7 - CA Technologies Documentation 

    The APMSQL Server uses the same API: APMSQL Cookbook - CA Application Performance Management - 10.7 - CA Technologies Documentation 



  • 6.  Re: REST API for CA APM open alerts

    Posted Sep 14, 2018 03:34 AM

    I  am monitoring java application so I installed APM  agent, but this agent contains only wily folder and inside this folder no lib folder is there. so can you please give me the exact location or process to find the lib folder under the EM installation. Is there any command or documentation for downloading EM because I can only find installation instruction(Install the Workstation - CA Application Performance Management - 10.0 - CA Technologies Documentation) but it is not specified from where I will get "IntroscopeWorkstation<version>linux.bin" file.

    Thanks

    Arpan



  • 7.  Re: REST API for CA APM open alerts

    Broadcom Employee
    Posted Sep 14, 2018 07:54 AM

    The command-line workstation (CLW) is a jarfile in the lib folder of the Enterprise Manager (EM) installation.

    If you have an agent installed, it must be reporting data to the Enterprise Manager, so I would assume that the Enterprise Manager has already been installed.

     

    This is the documentation on CLW

    https://docops.ca.com/ca-apm/10-5/en/using/apm-command-line-workstation

     

    We do not know your installation path, but you can search for CLWorkstation.jar on the machine where Enterprise Manager is installed and there should only be one of them.

     

    You can copy that jar file from the Enterprise Manager to another machine where it might be more convenient to run for you.

     

    Try to be as specific with any regular expressions you use for querying data as large queries can have large negative consequences on the Enterprise Manager.

     

    Trying not to confuse things, Introscope Workstation is a GUI that provides access to view metrics,dashboards (that you can configure), documentation on this here

    https://docops.ca.com/ca-apm/10-5/en/using/apm-workstation#APMWorkstation-TheWorkstation,JavaWebStart,andWebView

     

    The Workstation does not necessarily need to be installed, you can access the Java Web Start version. You can go to port 8081 (by default) of the Enterprise Manager with a browser, and click the link to "Start Introscope Workstation"



  • 8.  Re: REST API for CA APM open alerts

    Broadcom Employee
    Posted Sep 14, 2018 07:58 AM

    Hi Arpan,

     

    you can download the workstation installer from the Download management pages on support.ca.com for 10.7 the option is listed as INTROSCOPE WORKSTATION INSTALLER FOR LINUX R10.7.0.0. the following KB should help yo in navigating the download area

     

    Steps and Tips: Downloading APM Software from supp - CA Knowledge 

     

    thanks

    Mike



  • 9.  Re: REST API for CA APM open alerts

    Broadcom Employee
    Posted Sep 14, 2018 07:59 AM

    The workstation install does include the CLWorkstation.jar



  • 10.  Re: REST API for CA APM open alerts

    Posted Sep 17, 2018 05:27 AM

    Hi Mike,

    the document you mentioned saying that after sign-in I will get option for "Download Management" but I'm not getting any new option after sign-in.

    Thank you.It is the Screensort after sign-in.



  • 11.  Re: REST API for CA APM open alerts

    Broadcom Employee
    Posted Sep 17, 2018 03:50 PM

    Please mark sure you are logged .I see this with Vivaldi but not Google



  • 12.  Re: REST API for CA APM open alerts

    Posted Sep 18, 2018 12:14 AM

    Hi,

    I'm sure that I'm logged and I have tried Google and Mozilla but still not able to see any option.

    Thank you.



  • 13.  Re: REST API for CA APM open alerts

    Broadcom Employee
    Posted Sep 17, 2018 06:47 PM

    Hi Arpan,

    You should see DOWNLOAD MANAGEMENT under the Menu. If you don't per Hal's advice please try a different browser or sign out/sign in again.

    In you duplicate thread (Duplicate Thread Ignore: REST API for CA APM open alerts ) you stated:

    ===

    Let me explain everything from scratch. I have downloaded the APM agent (Java_v1.tar file) and extracted  this tar file then passed the path of the wily/Agent.jar file  which I got after extracting the tar file, to jvm argument and after that I am able to see the data for java application  on CA dash board and also able  to set alert. As I got the  information by Lynn Williams that we  can get all raw alerts by using SQL REST API , and to get alert information using SQL REST API , we need something called CLWorkstation.jar (suggested by one of the support guy) but since I have only willy folder and inside this willy only Agent.jar file is there. I have not installed Enterprise Manager or any other thing. So can you please tell me from start that how can I use this SQL REST API  to get raw alert information.

    ===

    Let me try to clarify.

    You said "I am able to see the data for java application  on CA dash board". Therefore somewhere in your environment there must be an Enterprise Manager (EM) already installed which is receiving data from the Java Agent to display on the dashboard.

    The SQL REST API and CLW (Command Line Workstation) are 2 different options for you to try to get the alert data:

    1. The SQL REST API is available in EM 10.7 SP2 (SQL REST API - CA Application Performance Management - 10.7 - CA Technologies Documentation ) and you can use the metric_path mike_cook suggested ("SuperDomain|Custom Metric Host|Custom Metric Process|Custom Metric Agent|Alerts|{MM name}|{Alert name}")

     

    2. Using CLW is an alternative option.

    java .... -jar CLWorkstation.jar query state of alerts matching (.*) in management modules matching (.*)

    CLW Command Reference - CA Application Performance Management - 10.7 - CA Technologies Documentation 

    The CLWorkstation.jar can be found in the lib directory under the Enterprise Manager install or Standalone Workstation install.

     

    Hope that helps understanding.

     

    Regards,

     

    Lynn



  • 14.  Re: REST API for CA APM open alerts

    Posted Sep 18, 2018 02:29 AM

    Hi Lynn_Williams,

    Thanks for clarification.

    But I haven't installed EM on my machine.I have just download APM agent which gave me a Java_v1.tar file and after extraction a wily folder with Agent.jar(with some other files as well but "not with lib folder")for monitoring my Java application. I just simply passed the path of wily/Agent.jar as JVM argument in my eclipse project and it started showing data on https://******.apm.cloud.ca.com/apm/appmap/ApmServer/#/dashboard....(my CA account).
    Can you tell me how can I check if EM is installed.

     

    I'm not able to download "Download Management" as well even after trying different browsers.

     

    Hope you get my problem and provide me right solution

     

    Thank you

     

    Arpan



  • 15.  Re: REST API for CA APM open alerts

    Broadcom Employee
    Posted Sep 18, 2018 02:46 AM

    Hi Arpan,

    Now I understand why you have no EM.

    You are not using APM on premise and instead you are using APM SaaS for DXI( Digital Experience Insights): CA Application Performance Management - CA Digital Experience Insights Application Performance Management - CA Technolog… 

     

    So we are hosting the EM for your agent. That probably also explains your lack of access to DOWNLOAD MANAGEMENT.

    You won't be able to use the CLW option.

    We will need to check if SQL REST API is available

     

    Regards,

     

    Lynn



  • 16.  Re: REST API for CA APM open alerts

    Posted Sep 18, 2018 02:57 AM

    Thank you  Lynn_Williams,

    Please check and suggest me if I cam make API/SQL API call for alerts or not.



  • 17.  Re: REST API for CA APM open alerts (APM SaaS for DXI)
    Best Answer

    Broadcom Employee
    Posted Sep 18, 2018 03:12 AM

    Hi Arpan,

    I changed the title of your thread to reflect APM SaaS for DXI

    Apparently the APM SaaS documentation for API Reference is not updated correctly to show SQL REST API:

    API Reference - CA Digital Experience Insights Application Performance Management - CA Technologies Documentation 

    However from internal threads I checked it does have the SQL REST API

    You can use the on premise documentation:

    SQL REST API - CA Application Performance Management - 10.7 - CA Technologies Documentation 

    For the API URL "http://<EM Host>:8081" just use your https://...apm.cloud.ca.com

    You can generate a Public API Token on the Security section of the UI (https://...apm.cloud.ca.com/apm/appmap/ApmServer/#/security)

     

    Regards,

     

    Lynn



  • 18.  Re: REST API for CA APM open alerts (APM SaaS for DXI)

    Posted Sep 19, 2018 03:18 AM

    Confirmed. This is the page you want: SQL REST API - CA Application Performance Management - 10.7 - CA Technologies Documentation 

     

    This content will be included in APM DXI doc as soon as possible.



  • 19.  Re: REST API for CA APM open alerts (APM SaaS for DXI)

    Posted Sep 21, 2018 04:48 AM

    Hi Arpan,

     

    The CA DXI Application Performance Management doc is now updated: SQL REST API - CA Digital Experience Insights Application Performance Management - CA Technologies Documentation 

     

    Thank you for bringing this to our attention. Let me know if there's anything else,

     

    Phil



  • 20.  Re: REST API for CA APM open alerts (APM SaaS for DXI)

    Posted Sep 18, 2018 06:13 AM

    Hi Lynn_Williams,

    As you said "we are hosting the EM for your agent" so can you please tell me when it will be ready so that I will proceed next.

    Thanks



  • 21.  Re: REST API for CA APM open alerts (APM SaaS for DXI)

    Broadcom Employee
    Posted Sep 18, 2018 10:56 AM

    Dear Arpan:

       The original question has been answered. Please consider creating a new thread to make this easier to follow



  • 22.  Re: REST API for CA APM open alerts (APM SaaS for DXI)

    Posted Sep 19, 2018 02:01 AM

    Hi Hal.

    I have asked a new question for EM ( EM Host of APM SaaS for DXI  ).

    Please reply there.

    Thank you



  • 23.  Re: REST API for CA APM open alerts

    Posted Sep 14, 2018 05:12 AM

    I think you can use the AlertPolling service with the operation 

    • getAllAlertsSnapshot
    • getAllAlertsSnapshotForManagementModule

    Depends on what you need. If you want you can filter up with the Management Module or you can ask allthe alarms.

    Than the result can be parsed for values (1,2,3) that should be the state (green,yellow or red)

     

    You can build a SOAP client in java or in PHP to get the result

     

    Hope it helps

     

    Luca

     

    http://mom_ip:8081/introscope-web-services/services/AlertPollingService