- [Narrator] In this video tutorial,
I'll walk you through creating a workbook
using Azure Monitor data.
We'll show the relationship
between application performance
and infrastructure metrics in one integrated view.
Workbooks allow you to combine data from various Azure data
sources and data types and enable you
to visualize the data in a single interactive report.
One of the ways you can access workbooks is
to navigate to Azure Monitor and click on workbooks
to get to the workbooks gallery.
This is a collection of predefined workbook templates
that you can take advantage of as is,
or edit them customized
to meet your requirements.
Let's look at a couple of examples
of templates before we create a new workbook ourselves.
Here's a workbook for virtual machine performance.
There shows common performance metrics such
as CPU memory,
and this usage across several VMs
and multiple subscriptions
for a big picture at scale type of view.
Includes tables with trending charts for easy sorting.
And if I switched tabs here,
there are line charts below for easy visual comparison.
Now here's the application failure analysis workbook.
Which lists application requests, failures, success rates
and the number of affected users.
For up to three different application resources
all at the same time.
In general workbooks allow you
to query data from multiple sources in Azure,
create custom visualizations for reporting and analysis
and combine multiple UX elements,
such as tax visualizations, parameters, links,
and more into a single interactive experience.
For this demonstration I'll be starting
with an empty workbook.
So you'll see how to add content
to the workbook from scratch.
One of the use cases for workbooks is
to provide a comprehensive view that tells the story
about the performance and availability
of multiple related resources.
Additionally, you can also provide
different monitoring perspectives
on the same resource set.
And this is exactly what I'll be doing here.
I'll start by adding some text
that describes what the workbook does.
This is done using markdown.
So you can easily add some basic formatting
for things like headings and links.
In this example, we'll build a workbook
that shows the availability
and performance at the application layer,
but then goes on to compare those,
the infrastructure metrics from the VM on
which the app is running.
Next I'll add a line chart showing application availability
using metrics.
First by selecting the resource type
and my application insights resource,
but I'll leave the default simple line chart visualization.
Once those choices have been made,
I can move on to selecting the metric
and aggregation type.
Remember to click on run metrics,
to actually create the chart
and preview the results.
It's also good practice here
that at least add a title to each
of your charts, tables and graphs.
Now click on done editing
and there we have it.
My first visualization in the workbook.
For a second visualization, I wanted
to display the response time
of each application request by its name.
That is the duration
of each request by operation name.
I'll do this using Azure Monitor logs.
So I'll click on add query
to get started.
If you're already familiar with the query language,
KQL.
You can go ahead and get started editing right
here in the workbook,
or jump over to the Azure Monitor logs UI
to test out more complicated queries.
I'll start with a very simple query
to pull back the request table I'll then summarize
these requests by average duration and then sort them
in descending order in the table.
And now with a quick update to change
how my columns rendered.
And again, I'll point out,
we should follow good naming convention
and added descriptive title here.
So here's a final table showing application response times
with another interesting visualization technique,
that highlight the differences in duration.
Maybe I'm also interested in seeing the
overall response time in a time series chart,
similar to the availability line chart
that we created above.
So I'll quickly put that together
with another metric chart, using the same process.
Selecting the resource types, selecting the resource metric
and aggregation.
Next I'll move on to previewing the chart
to ensure that we see the data that we want.
And I'll also take a moment
to update the title
to app server response time.
Lastly, I'd like to compare
the application performance views
that we created to the
most basic infrastructure metrics,
percentage CPU, and memory usage.
Again, I'll use metrics starting
with selecting the resource type subscription
and the resource of interest.
In this case, I'll select the VM, the retail VM,
and that's where my app is running.
And with these selections made,
I can move on to selecting the relevant metrics
and I'll use average as magnification type.
The first metric that I use will be percentage CPU
from the standard metrics namespace.
And the second one will be memory committed bites percentage
from the custom metrics namespace.
Just like we've been doing with all of graphs.
I'll add a title here as well.
I'll introduce one new setting here.
By changing the visualization from line chart to tiles.
This will aggregate all
of the values collected during the time period down
to a single one per metric.
So now we have a report
that highlights application availability
and performance in comparison to server side CPU and memory.
Of course, this demonstration just scratched the surface
of what can be done with workbooks.
You can expand on what you've seen
here to include parameters
that make your workbooks more interactive.
You can add more complex queries
or you can use more sophisticated visualizations.
For me all I need to do at this point
is save the workbook before returning
to the workbooks gallery.
Although I've demonstrated creating a workbook from scratch
and showing some of the workbook templates
that are available earlier,
I should also point out that several Azure Monitor insights
are also based on workbooks and can be customized just
as easily as you've seen today.
Let's look at Azure Monitor for storage as an example.
This gives an at-scale
view at the performance and capacity
of all storage accounts across multiple subscriptions.
This would be a great starting point
for our custom storage workbook.
Thanks watching this short tutorial,
hopefully this helps you get started on your journey
with workbooks in Azure.