Hourly average usage in Azure Application Insights - azure-application-insights

I can get Application Insights to display a running hourly log of usage, but is there a way to display average usage on an hourly basis to see what times of the day a site is must used?

on the overview blade your resource, isn't there a metrics explorer that shows exactly that? the last 24 hours by hour? if that isn't what you mean, you could make an analytics query to get whatever you want, something like
requests
| where timestamp > ago(7d)
| extend hour = datetime_part("hour", timestamp)
| summarize sum(itemCount)/7 by hour
| order by hour asc
| render barchart
which would show you requests over the last 7 days split by each of the 24 hours, divided by 7 to show you average per day.
if you just want "today's" version of that its even simpler:
requests
| where timestamp > ago(1d)
| summarize sum(itemCount) by bin(timestamp, 1h)
| render timechart
anything you can query in the analytics website you can then pin as a tile on your azure dashboard.

Related

Firebase real time database by time period

I would like to ask about firebase Google Analytics (GA)
Can real-time firebase see the data by last 3 hours or more ( Currently, it is limited to last 30 minutes).
How to see the reports filtered by hours? ( I would like to find which period has more active users, let says 6:00PM-7:00PM)

Regarding custom metrics application insights

I have a scenario where I'm getting custom metrics thru an application. I want to create alerts based on thresholds and days of the week. Is there any way I can integrate the metadata in some storage and compare the metrics based on that? For example, I have message count metrics in the application, and if on Monday the message count is less than 100 or more than 200 I should get an alert. It varies on the day of the week. I have to monitor almost 250 custom metrics.
I tried implementing custom logs in Log analytics but I have a challenge in case if I want to change the thresholds then I need to drop the custom table and recreate it.
Thank you AnuragSingh-MSFT | Microsoft Docs. Posting your suggestion as an answer to help other community members.
Using a combination of both dayofweek() and case() functions, the resultant query itself can contain the threshold based on the day-of-week. Therefore, in future if the threshold changes, you will only have to edit the case statement and this solution also does not require additional storage/custom table.
let day = dayofweek(now());
let threshold = case(day == 1d, 5m, //threshold for Monday is 5 minutes
day == 2d, 2m, //threshold for Tuesday is 2 minutes
day == 3d, 5s, //threshold for Wednesday is 5 seconds
10m); //threshold for any other day is 10 minutes.
Heartbeat
| summarize LastHeartbeat=max(TimeGenerated) by Computer
| where LastHeartbeat < ago(threshold)
Reference: Regarding custom metrics application insights - Microsoft Q&A

I want to get absolute value for my Google Analytics metrics. Currently I'm getting all values of DAU,MAU and session time in terms of percentage

I am getting the average engagement time in my analytics dashboard. I want the session time to be displayed in categories based on time:
Sessions less than 1 min
Sessions with 1-3 mins of engagement time.
2 options to accomplish that:
Create Segments for each Session length
Under Segments > Behaviour "Session length" > 3
Aggregate your Data in Excel or Google Data Studio

Multi-Channel Funnels response per day not total

I'm doing this request in Python / Postman:
https://www.googleapis.com/analytics/v3/data/mcf?
ids=ga:xxxx&metrics=
mcf:assistedConversions&
dimensions=&
start-date=2011-10-01&
end-date=2011-10-31
But I only seem to be able to get the total number of results.
1/ Can I get it on a daily granularity? I know that GA API has the ga:date optional parameter, but this does not work in combination with the MCF API and I couldn't find anything similar for MCF.
Do I have to iterate through each day to get the results at a daily granularity?
2/ Is the 30 days lookback applied to API calls? If just put the end date 4 years ahead, will it give me the full results?
Daily granularity: You should add the mcf:nthDay dimension to break the results down into individual days within the specified range:
Index for each day in the specified date range. Index for the first
day (i.e., start-date) in the date range is 0, 1 for the second day,
and so on.
Loopback time: yes it's 30 days and can'be be changed:
Note: The Multi-Channel Funnels Reporting API uses a non-adjustable
30-day lookback window.
If just put the end date 4 years ahead, will it give me the full results?
Why don't you test to find out and let us know :) ?

Application insight

I have created a powerBI dashboard for my application insight but it's only showing last 7 days data.
I am able see 30 days when I check in overview of appinsight but it's only showing last 7 days when I do browser search from overview view.
I'm not sure how you are exporting you Application Insights telemetry to PowerBI, but you can export the data using Application Insights Analytics queries. This way, you have full control on the timestamp range in the Analytics query.
For example, for finding the average request duration in the last 30 days in a daily bin, you can use the following query:
request
| where timestamp >= ago(30d)
| summarize avg(duration) by bin(timestamp, 1d)
Asaf

Resources