sitespeed.io icon indicating copy to clipboard operation
sitespeed.io copied to clipboard

Not seeing "Total Transfer Size" in InfluxDB/Grafana but it is available in Sitespeed Report

Open 2343909 opened this issue 1 year ago • 5 comments

Your question

"Total Transfer Size" does not look like it is saved to InfluxDB to view it in Grafana or I am not seeing it:

image

It is available in Sitespeed HTML report: image

2343909 avatar Apr 22 '24 13:04 2343909

Try check origin and _measurement == transferSize

Amerousful avatar Apr 25 '24 12:04 Amerousful

I see that you use InfluxDB 1.x, but here you're the query from InfluxDB 2.x

from(bucket: "sitespeed")
  |> range(start: 2024-04-24T12:27:31.499Z, stop: 2024-04-25T12:27:31.499Z)
     |> filter(fn: (r) =>
      r.category == "default" and
      r.testName == "....." and
      r.group == "....." and
      r.page == "_" and
      r.browser == "chrome" and
      r.connectivity == "native" and
      r._field == "value"
    )
  |> filter(fn: (r) => 
    r._measurement == "transferSize" and
    r.origin == "pagexray" and
    not exists r.contentType and 
    not exists r.party
  )
  |> aggregateWindow(every: 10s, fn: median, createEmpty: false)
  |> set(key: "_field", value: "Transfer Size")
  |> drop(columns: ["_measurement", "runId"])  

Amerousful avatar Apr 25 '24 12:04 Amerousful

@Amerousful It does not match with the HTML Report for some reason: image image

2343909 avatar Apr 25 '24 13:04 2343909

Add also not exists r.contentType and not exists r.party

Amerousful avatar Apr 25 '24 14:04 Amerousful

@Amerousful Thanks; yeah I was trying to figure out how to do that in Grafana and there are not that many options to enter "not exists" in the Grafana query.... Still working on it... I can do "contentType" != to provided options but non of the provided options result in the accurate matching data between the report and Grafana.

Thanks a lot for the quick responses above.

2343909 avatar Apr 25 '24 18:04 2343909