JELENA MIJUSKOVIC: Hi, everyone.
I'm Jelena.
DEOK FILHO: And I'm Deok.
And we're both customer engineers at Google Cloud.
JELENA MIJUSKOVIC: Welcome back to the technical series
for startups, where we're creating a series of videos
for technical enablement to help startups to start, build,
and grow their businesses successfully and sustainably
in Google Cloud.
DEOK FILHO: In the previous video,
we deep dived into automating your development lifecycle
with CI and CD pipelines.
And now, we'll talk about how to improve the performance
and reliability of your applications
with Cloud operations.
JELENA MIJUSKOVIC: In this video,
we're going to cover introduction
to the Cloud operation suite, formerly known
as Tech Driver, Operation tools as means to have observability
over your Google Cloud resources,
application performance management
tools to improve performance and reliability
of your applications.
Finally, we'll share a customer success story
to demonstrate the value of the Google Cloud Operation Suite.
If you've ever worked with on-premises environment,
you know that, if your application becomes
unresponsive, somebody could walk in, physically check why,
and resolve the issue.
In the cloud, though, how do you know
what's happening with your server, database,
or application?
The answer is simple, with the tools that we
will show you in this video.
Capturing of telemetry, login, and trace data
is done from the hardware layer and app for Google products.
From these products, signal data flows into Cloud Operation
tools, where it can be visualized
in dashboards and through the metrics explorer.
Automated and custom logs can be ingested and analyzed
in the log viewer.
Services can be monitored for compliance
with the service-level objectives.
And error budgets can be tracked.
Health checks can be used to check uptime and latency
for external-facing sites and services.
And running applications can be debugged and profiled.
When incident is secure, single data
can generate automated alerts that
can notify personnel through various notification channels.
Error reporting can help operation and developer teams
to spot, count, and analyze crashes
in your cloud-based services.
Finally, all the visualization and analysis tools
can help to troubleshoot what is happening in your Google Cloud
environment.
Let's start first with exploring the products that
tend to be of interest for the operation folks.
Cloud Logging provides a centralized Cloud Logging
system that you can use to store, search, analyze,
monitor, and alert log data and events from all Google Cloud
resources but also to collect data
from multicloud environments with Anthos integration.
Cloud Logging also provides integration
into third-party systems through the API and Cloud Pub/Sub.
The export functionality allows you
to perform aggregated analytics in BigQuery
and store your logs in Google Cloud Storage.
As you can see from this quick demo,
with features like histogram, Logs Field Explorer,
you can quickly gain insights into trends across your logs.
Error reporting provides insights into your errors
by collecting and grouping your application errors.
There are three key log categories,
audit logs, agent logs, and network logs.
Audit logs help answer the question, who did what,
where, and when?
And those are admin activity logs, data access logs,
system event, and data transparency logs.
Agent logs use a Google customized and packaged Fluentd
agent that can be installed on any Google Cloud or AWS VM
instance and ingest logs from Google Cloud or AWS EC2
instance.
Finally, network logs provide in-depth network telemetry
with PPC flow logs, firewall rules, NAT gateway,
and load balancer types.
Cloud Monitoring allows you to collect metrics
from multicloud and hybrid infrastructure in real time.
By using cloud monitoring, you can
answer important questions like, what is the load on my service?
Is my website responding correctly?
Is my service performing well?
To understand the current load on a service
or to view performance data of your service
for the past month, use the charts and dashboard tools.
If you're interested in being notified
if your deployed service isn't accessible
or responding correctly, then configure an uptime check
and attach an alerting policy.
This is an example of Metrics Explorer, where
you can explore metric lists for all GCP services
and add them to different chart types.
Monitoring has many predefined metric types
and monitored resources available.
But you can also create custom metrics.
If you don't want to save the chart to a custom dashboard
but you want to keep a reference to the chart,
then save the chart URL.
Dashboards are one way for you to view and analyze
metric data.
The Cloud Console provides 15 predefined dashboards
that require no setup or configuration.
Your Google Cloud project resources
determine the dashboards available for you.
For example, if your project contains Compute Engine
instances, then your project includes dashboards
for VM instances and for disks.
DEOK FILHO: Hey, everyone.
The next step is for us to check out
some tools to help you manage your application's performance.
At the heart of measuring application performance
in Google Cloud lies Cloud Debugger.
It lets you inspect the state of a running application
in real time without stopping your application
or slowing it down, all at no cost.
With Cloud Debugger, you can examine your code's function
and performance under actual production conditions.
How convenient is that?
In addition to real-time app debugging,
Cloud Debugger allows you to capture
the state of your application in production at a specific line
location with snapshots.
You can see this on the right.
I first set up a snapshot at line 73.
You can see, in the snapshot column,
that it's waiting for a change.
I then go to my application and provoke a state change
by clicking the Add to Cart button.
You can immediately see the state capture by the snapshot,
specifically, that the cost ID variable, set at line 73,
has the value undefined.
Moving on from snapshots, you can also use log points
to inject a new logging statement on demand
at a specific line location, as well as capture a snapshot
or write a log point message only
when you need it using a simple conditional expression written
in your application's language.
The ease of use of Cloud Debugger
is further extended by its integration
with existing developer workflows and popular IDEs.
You can easily collaborate with other teams
by sharing your debug session.
In this demo, I can simply share my console URL
with a team member.
And they'll be able to see the snapshot I created.
Debugger also knows how to display the correct version
of your source code because it easily
integrates with the version control
systems such as cloud source repositories, GitHub,
Bitbucket, or GitLab.
Now that we've seen how easy and convenient
it is to work with Debugger, let me tell you
what Cloud Trace is.
Based on the tools that Google itself uses on its production
services, Cloud Trace is a tracing system that collects,
analyzes, and displays latency data
from your distributed applications and displays
that in the Google Cloud console.
Cloud Trace can capture traces from applications deployed
on App Engine, Compute Engine VMs, and Kubernetes Engine
containers.
It generates performance insights near real time
and automatically generates in-depth latency reports.
Finally, Cloud Trace also continuously gathers
and analyzes trace data to automatically identify
recent changes to your application's performance.
Let me show you a quick demo of Cloud Trace.
First, when opening Cloud Trace in the Google Cloud console,
I immediately see an overview of previous traces
and report of latency.
Let's navigate to the trace list page.
I'll create some filters to see calls
to a currency service of my application
that are only getting get requests
which took at least 1,000 milliseconds from request
to response.
I then select a trace from the graph.
And below, in the trace waterfall view,
I can explore the spans, which are suboperations
of this particular trace.
Finally, under the Details panel,
I select to View Logs, which takes me to the Cloud Logging
page, where I can see detailed log entries associated
with the request that initiated this trace.
In summary, this allows you to see
how requests propagate through services in separate projects
and helps you to identify sources of poor performance
across your entire stack.
On to error reporting, error reporting counts, analyzes,
and aggregates the crashes in your running cloud services.
A dedicated view shows the error details, time chart,
occurrences, affected user count, first
and last seen dates, and a cleaned exception stack trace.
You can opt in to receive email and mobile alerts
on new errors.
Finally, the last major component
of measuring your application's performance is Cloud Profiler.
Poorly performing code increases the latency and cost
of applications in web services every day without anyone
knowing or doing anything about it.
To solve it, Cloud Profiler continuously
analyzes the performance of CPU-intensive and
memory-intensive functions across an application
Cloud Profiler does this by using statistical techniques
and extremely low-impact instrumentation
that runs across all production application instances
to provide a complete CPU and heat picture of an application
without slowing it down.
To set up Cloud profiler, you first
include a language-specific profiling agent
in your application.
Whether it is running in GC EVMs, App Engine, or GKE,
the agent then collects profiling data as the app runs.
As you can see from the image on the right,
Cloud Profiler presents the call hierarchy and resource
consumption of the relevant function
and an interactive flame graph that
helps developers understand which paths consume the most
resources and the different ways in which their code is actually
called.
Now that you've seen many operations in application
performance management tools, how
should you use them to bring your ideas to market faster
and to be more responsive to your customers?
Well, Google's Site Reliability Engineering, or SRE,
is the answer.
SRE is how operations at Google adopted DevOps.
The five SRE design principles redefine reliability,
reduce oil, balance speed and risk, make small changes
and create the right culture, help
you accomplish these goals.
The tools we introduced were designed
based on Google's own operations experience and development
of SRE practices.
A key area of practice for SRE is monitoring.
Cloud Monitoring, which pulls data from multiple sources,
not only gives you the visibility you
need to quickly determine service health
and diagnose your applications when things go wrong, but also
addresses the fundamental monitoring needs of SRE,
with components such as SLO monitoring,
dashboards, and its analytics capabilities through default
and custom metrics.
Let me tell you about a customer success story.
Krikey is a gaming company, which
aims to bring the excitement of interacting with characters
through augmented reality by leveraging
stories that are rarely told in mainstream gaming.
With four separate games, all requiring multiple video
feeds, they rely on Cloud Operations
to monitor, troubleshoot, and improve their application's
performance.
In particular, the Cloud Monitoring dashboard
gives them deep visibility into latency, downtime,
and the overall health of their applications.
Here is a joint quote from Krikey's CEO and CTO.
"Having one integrated view of alerts, SLOs, events, and logs
via the dashboard, which allows us to quickly identify
which container has the problem, fix the container,
and redeploy."
JELENA MIJUSKOVIC: In this episode today,
you got to see the fundamental components
in making your application perform better
with a consistent and effortless observability and monitoring
of your resources.
Thank you for joining us on this episode about Cloud Operations.
To continue exploring, check out our suggestions
on the links in the description.
We'll see you next time for an overview
of billing, a critical component of your Google Cloud presence.
You will learn about different discounting options,
how billing works, and how to manage your costs.
Don't forget to subscribe to our YouTube channel
and to click on the bell icon to get notified each time we
post a new video.
See you next time.
DEOK FILHO: Bye, bye.
See you next time.
[MUSIC PLAYING]