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

Set custom value in synthetic and show it in dashboards

george_azzam
Newcomer

Hello,

I would like to be able to set a key-value inside a synthetic script, and then be able to see this value inside a dashboard.

This should be a custom key-value that I can calculate during the synthetic script run, set it as a (maybe global) key-value, and when opening a dashboard the up-to-date value should be shown.

Is this possible?

We work with NewRelic, and we consider moving to Dynatrace, In NewRelic we could easily do this operation by using $util.insights.set(Key, Value); and then read the value inside the dashboard.

 

Thanks very much.

3 REPLIES 3

Yosi_Neuman
DynaMight Guru
DynaMight Guru

Hi @george_azzam 

Check the Pre-execution script methods request.addHeader(key,value)

HTH

Yos 

dynatrace certificated professional - dynatrace master partner - Matrix Soft Ware Division - Israel

But how can I fetch this data to a Metric inside the dashboard ?!

For example I used:

 

 

request.addHeader("ScansCount", "8765");

 

 

How can  I show the "ScansCount" value/avg/sum/etc inside a metric in a dashboard?

 

-- EDIT --

We work on Clickpath scripts

@Yosi_Neuman 

For that you will need to collect the information from server side with request attribute and calculated metrics then you will be able to chart your metrics with data explorer.

dynatrace certificated professional - dynatrace master partner - Matrix Soft Ware Division - Israel

Featured Posts