DX Application Performance Management

Expand all | Collapse all

CA App Synthetic Monitor API

Jump to Best Answer
  • 1.  CA App Synthetic Monitor API

    Posted 03-22-2016 12:16 PM

    Dear colleagues,

    does anybody have experience with the App Synthetic Monitor API or can point to a detailed documentation beyond this one?

    In particular, I am trying to understand the semantics of the parameters and fields for creating or reading a rule (methods rule_add and rule_get). For type=script, the field "post" should contain an encoded JMeter script, however I am unable to figure out the encoding (it is not base64).

    Any help is greatly appreciated.

    Thanks,

    Frank



  • 2.  Re: CA App Synthetic Monitor API

    Posted 03-22-2016 01:30 PM

    Hi Frank:

        I asked my colleagues @musma03 Tom_Wyszomierski eigda01  to provide an answer

     

    Thanks

    Hal German



  • 3.  Re: CA App Synthetic Monitor API

    Posted 03-22-2016 01:40 PM

    Unfortunately I don't think this documented anywhere. I believe the data type is specific to the backend database we use for ASM. Though I tried running rule_get on an existing monitor to presumably get a valid value and then tried to create a new monitor using the value returned. This also failed with the error:

    error>illegal parameter value</error>

      <info>could not determine script type</info>

     

    I'll discuss this with our internal ASM team and see if we can get a better answer as to what encoding is used and why the error occurs.



  • 4.  Re: CA App Synthetic Monitor API
    Best Answer

    Posted 03-23-2016 11:39 AM

    Heard back from our internal team. For rule_add,  the expected (decoded) value of the "post" parameter  is the actual JMX script (XML). The data should be sent with Content-Type: application/x-www-form-urlencoded. That means each individual parameter needs to be URL Encoded (see https://en.wikipedia.org/wiki/Percent-encoding) and the raw POST data is then formed as follows:

    param1=<urlencoded_param1_value>&param2=<urlencoded_param2_value>...

     

     

    As for the rule_get, unfortunately this is inconsistent. The output value of the post parameter is gzip-compressed and BASE64 encoded.