sylvestersteele
Contributor
Contributor

Incorrect Metric data returned for Availability

Hi,
On a hunch I did: MetricDataResponse metricDataResponse= metricApi.getMetricData(ID, 1,100); which according to my understanding should return the metric value for the first 100 millis after epoch. Now, there shouldn't actually be any data but I was surprised to find that my platform was actually available! The availability was= 2.0. Looks like a bug to me. The data point list was:

100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0
100 2.0

which is 60 lines.

For the other metrics however I got no data as expected.

Any hints?

Thanks,
Sylvester
0 Kudos
2 Replies
admin
Immortal
Immortal

Hi Sylvester,

I've reproduced this and am investigating possible fixes. The value you are getting back is correct (2 == UNKNOWN), however it's misleading. Availability data in 4.x is only stored when a state changes, so we need to do some thinking on how to return data for availability when a range is requested. Currently it's giving the availability averaged out over 60 data points for the range requested, which is probably not what the developer would expect.

-Ryan
sylvestersteele
Contributor
Contributor


> Currently it's giving the availability averaged out over 60 data points for the range requested, which is probably not what the developer would expect
I think I asked for the availability in the first 100 milliseconds only.
There should be only one value right? Also, how come the time for all
data points is 100 and not some number between 1 and 100?

Thanks,
Sylvester

0 Kudos