Menu
×
   ❮   
HTML CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C C++ C# BOOTSTRAP REACT MYSQL JQUERY EXCEL XML DJANGO NUMPY PANDAS NODEJS R TYPESCRIPT ANGULAR GIT POSTGRESQL MONGODB ASP AI GO KOTLIN SASS VUE DSA GEN AI SCIPY AWS CYBERSECURITY DATA SCIENCE
     ❯   

AWS Monitoring Serverless Applications


Monitoring Serverless Applications

Once you've begun testing and monitoring your apps in production, ask yourself these questions:

  • Is the information I'm gathering correct?
  • Is it necessary to expose custom metrics?
  • Am I logging the right information at the right level?
  • What more should my application traces include?

By answering these questions, you can create the most suitable monitoring for your case.

Monitoring, like every other AWS application or architecture, begins with CloudWatch.

What you rely on are CloudWatch metrics, CloudWatch Logs, and CloudWatch Logs Insights.

All of the AWS managed services discussed in this course provide built-in CloudWatch metrics and logging.

Tracing is also a crucial component of monitoring your distributed applications.

You may see trace data using AWS X-Ray to understand how your application is operating.

This assists you in identifying and correcting the cause of performance issues and errors.


Monitoring Serverless Applications Video

W3schools.com collaborates with Amazon Web Services to deliver digital training content to our students.


CloudWatch Metrics

CloudWatch metrics are generally used by developers to monitor service health.

They are also used to alert on error cases.

A statistic failure might be sent to SNS topic subscribers through a CloudWatch alert.

Examine the available CloudWatch metrics and their dimensions for each service.

It is how you can determine how to best exploit them before adding new measures.

Business Metrics

Business KPIs compare the performance of your application to business objectives.

Business KPI stands for Business Key Performance Indicators.

It is crucial to understand whether something is having a negative impact on your whole business.

Orders placed, debit/credit card transactions, and flights bought are some examples.


Customer experience Metrics

Customer experience data determines the general success of the UI/UX.

Examples include perceived latency and page load times.


System Metrics

Metrics from vendors and applications are critical for determining underlying causes.

System metrics may also inform you if your systems are in good health, at risk, or currently affecting your consumers.

Examples include HTTP error/success ratios, memory consumption, and latency.


Operational Metrics

Ops metrics are critical for understanding the sustainability and maintenance of a specific system.

They also help determine how stability has progressed/degraded through time.

Examples include deployments, availability, and analytics.


CloudWatch Logs

Logs allow you to investigate particular issues.

You may also generate business-level metrics with CloudWatch Logs metric filters.

It's critical to consider which logs and what amount of logging you want.

Logs can be utilized in both testing and production environment.

There is a cost to documenting everything that happens.

Your logs may suggest that you have illegal access but not enough information to do anything.

You can record nearly anything to CloudWatch Logs.

All requests processed by your function are logged by Lambda and stored in CloudWatch Logs.

This allows you to get details about each invocation of your Lambda function.

When creating custom logs, utilize a structured format to make reporting easier.


Lambda Logs

Lambda automatically logs all requests handled by your function.

It puts them in CloudWatch Logs.

This offers you access to information about each invocation of your Lambda function.


API Gateway Execution and Access Logs

API Gateway execution logs provide error information as well as execution traces.

The execution logs contain information about parameters, payload, used Lambda authorizers, and API keys.

You can log only errors or errors and information.

Logging is configured for each API level.

You may also build custom access logs to track API usage.


CloudWatch Log Insights

CloudWatch Log Insights allows you to run prebuilt or custom queries on your logs.

It can automatically detect the fields in your logs if you've developed structured custom logs.

It makes it easier to query and aggregate your log data.


Related reads:

Amazon API Gateway Metrics
AWS Lambda Metrics
Amazon SQS metrics
AWS Step Functions Metrics
Amazon SNS Metrics
Amazon Kinesis Data Streams Metrics

AWS Serverless Exercises

Test Yourself With Exercises

Exercise:

Which CloudWatch metrics determine the general success of the UI/UX?

  metrics

Start the Exercise