cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Capturing Webpage variable on synthetic monitor step

mpdotcom
Visitor

Do we have a way where I can capture webpage variables upon synthetic script execution?

I have been getting frequent alerts but unable to identify which webserver node is failing. I'm thinking of capturing the webpage variable so we can directly isolate it from the web cluster. Do you think it's possible?

5 REPLIES 5

HannahM
Dynatrace Leader
Dynatrace Leader

Is this information available somewhere on the page? If so, you could use a JavaScript event to grab the value and then either print it in the logs using, api.info etc or you could fail the monitor with api.fail and print the information in event shown the WebUI. You can find information on JavaScript events here

Synthetic SME and community advocate.

I tried the api.info and it works if I want to run manually.

 

Is there a way that I can view the details on script analysis page?

HannahM
Dynatrace Leader
Dynatrace Leader

No, for HTTP Monitors you can't currently add information there. If it's a monitor being run on a private location, you can see messages in the vuc-http-custom.log. Otherwise for a public monitor you could fail the test as you can see the failure message in the Events section on the HTTP Monitor details page. 

Otherwise, you could use the events API to send an event to the tenant for this monitor 

 

Synthetic SME and community advocate.

do we have document on how to do this?

HannahM
Dynatrace Leader
Dynatrace Leader

Api.fail is documented here and the events API is documented here

Synthetic SME and community advocate.

Featured Posts