SlideShare a Scribd company logo
1 of 73
Download to read offline
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
AWS re:INVENT
Debugging Modern Applications:
Introduction to AWS X-Ray
A b h i s h e k S i n g h ( A W S )
A l a i n N i c o l e t ( C h i c k - f i l - A )
D E V 2 0 4
N o v e m b e r 2 8 , 2 0 1 7
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
What to Expect from the Session
 Overview
 Concepts
 Use cases
 Getting started
 Customer story
 Q&A
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Debugging Applications
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Traditional Debugging
Developer Local Test
Developer
Add
Breakpoints
Add Log
Statements
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Monolithic vs. Service-Oriented Architecture
Service-Oriented
Architecture
Monolithic
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
The traditional process of debugging doesn’t scale well for
production applications or those built using a service-
oriented, microservice, or serverless architecture
It’s tedious, repetitive, and time consuming
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Challenges
Services such as AWS Lambda, Amazon EC2 Container Service, AWS Elastic
Beanstalk, AWS CloudFormation, etc., make it easier to deploy and manage
applications consisting of hundreds of services
Deploying and managing service-oriented applications can be more work
compared to monolithic applications
Still hard to debug application issues in production applications due to:
 Cross-service interactions
 Varying log formats across services
 Collecting, aggregating, and collating logs from services
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Log-Centric Approach
service 1 logs
service 2 logs
service 3 logs
user
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
User-Centric Approach
user
Amazon
DynamoDB
Amazon
SQS queue
Frontend API
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Identify Performance
Bottlenecks
How Does AWS X-Ray help?
Pinpoint Specific
Service Issues
Identify Errors Identify Impact to
Users
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Concepts
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
X-Ray Concepts
user
Amazon
DynamoDB
table
Amazon
SQS queue
Frontend API
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
X-Ray Concepts
Trace End-to-end data related a single request across services
Segments Portions of the trace that correspond to a single service
Sub-segments Remote call or local compute sections within a service
Annotations Business data that can be used to filter traces
Metadata Business data that can be added to the trace but not used for filtering traces
Errors Normalized error message and stack trace
Sampling Percentage of requests to your application to capture as traces
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Use Cases
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Visualize Service Call Graph
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Identify Impact
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Pinpoint Issues
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Pinpoint Issues
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Pinpoint Issues
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Identify Performance Bottlenecks
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Identify Performance Bottlenecks
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Identify Performance Bottlenecks
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Identify Performance Bottlenecks
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
AWS Lambda (Initialization)
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
AWS Lambda (Existing Container)
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
AWS Lambda (Exceptions)
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
AWS Lambda (Exception Details)
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Advanced Use Cases
Use Off-Cloud Custom Payload Deep Linking Custom Apps
via API
Filter
Expressions
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Interested in building custom apps?
DEV402: Deep-Dive for AWS X-Ray
Thursday (11/30) @ 1:00 p.m.
Venetian, Level 2, Titian 2204
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
How Does AWS X-Ray Work?
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
X-Ray SDK
Enables you to get started quickly without having to manually instrument your
application code to log metadata about requests
Source on GitHub under https://www.github.com/aws/
Available for Java, .NET, Python, Go, and Node.js
Adds filters to automatically capture metadata for calls to:
 AWS services using the AWS SDK
 Non-AWS services over HTTP and HTTPS
 Databases (MySQL, PostgreSQL, and Amazon DynamoDB)
 Queues (Amazon SQS)
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
X-Ray Daemon
Receives data from the SDK over UDP and acts as a local buffer;
data is flushed to the backend every second or when the local
buffer fills
Available for Amazon Linux AMI, RHEL, Ubuntu, OS X, and Windows
Pre-installed on AWS Lambda
Can be run anywhere as long as AWS credentials are provided (for
example, EC2, ECS, on-premises, developer machine, and others)
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
X-Ray Service
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Trace ID & Propagation
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Trace ID & Propagation
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Trace ID & Propagation
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Trace ID & Propagation
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Trace ID & Propagation
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Trace ID & Propagation
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Trace ID & Propagation
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Trace ID & Propagation
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Trace ID & Propagation
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
App & X-Ray
SDK
EC2 Instance
X-Ray
Daemon
Localhost
UDP
X-Ray API
HTTPS
HTTPS
X-Ray Console
App & X-Ray
SDK
Server
X-Ray
Daemon
Localhost
UDP
EC2 Role
AWS
Credentials
DevOps Team
HTTPS
X-Ray Workflow
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Sampling Configuration
{
"rules": {
“payment": {
"id": 1,
"service_name": "*",
"http_method": "*",
"url_path": "/api/payment/*",
"fixed_target": 0,
"rate": 1.00
},
"base": {
"id": 2,
"service_name": "*",
"http_method": "*",
"url_path": "*",
"fixed_target": 1,
"rate": 0.1
}
}
}
This example defines two rules:
The first rule applies a 100% sampling rate with
no minimum number of requests to trace to
requests with paths under /api/payment
The second overrides the default sampling rule
with a rule that traces the first request each
second and 10% of additional requests
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
APIs
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
X-Ray API
X-Ray provides a set of APIs to enable you to send, filter, and
retrieve trace data
You can send trace data directly to the service without having to
use our SDKs (that is, you can write your own SDKs for languages
not currently supported)
Raw trace data is available using batch get APIs
You can build your own data analysis applications on top of the
data collected by X-Ray
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
X-Ray API
PutTraceSegments Uploads segment documents to AWS X-Ray
BatchGetTraces Retrieves a list of traces specified by ID
GetServiceGraph Retrieves a document that describes services in your application and
their connections
GetTraceSummaries Retrieves IDs and metadata for traces available for a specified time
frame using an optional filter
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Segment Document
Minimal example
{
"name" : "example.com",
"id" : "70de5b6f19ff9a0a",
"start_time" : 1.478293361271E9,
"trace_id" : "1-581cf771-a006649127e371903a2de979",
"end_time" : 1.478293361449E9
}
Example showing an in-progress segment
{
"name" : "example.com",
"id" : "70de5b6f19ff9a0b",
"start_time" : 1.478293361271E9,
"trace_id" : "1-581cf771-a006649127e371903a2de979",
“in_progress”: true
}
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Getting Started
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Agent Installation (Amazon EC2 Linux)
#!/bin/bash
curl https://s3.dualstack.us-east-1.amazonaws.com/aws-xray-assets.us-east-1/xray-daemon/aws-xray-
daemon-1.x.rpm -o /home/ec2-user/xray.rpm
yum install -y /home/ec2-user/xray.rpm
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Agent Installation (Amazon EC2 Windows)
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Agent Installation (Amazon ECS)
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
App Instrumentation (Node.js)
//Add aws-xray-sdk package to package.json
var XRay = require('aws-xray-sdk');
var AWS = captureAWS(require('aws-sdk'));
…
XRay.config([XRay.plugins.EC2]);
XRay.captureHTTPs(http);
XRay.setDefaultName('myfrontend-dev');
…
app.use(XRay.express.openSegment());
app.get('/', function(req, res)
…
app.get('/blog', function(req, res)
…
app.use(XRay.express.closeSegment());
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Customer Story
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Introduction
Alain Nicolet
Enterprise Architect for Operator and Restaurant facing systems
Atlanta, Georgia
Chick-fil-A
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Cloud
+
DevOps
+
Microservices
Journey
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Spring Boot
Operator Mobile App
• Sales Metrics API
• Labor API
• Truck Tracking API
• User Preferences API
• News API
• And More
Use Case
AWS
Lambda
AWS
Elastic
Beanstalk
Amazon
DynamoDB
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Successful, Not Perfect!
 Made a big impact
 Positive feedback from operators!
 Microservices are awesome!
X Debugging is log-based, annoying, and slow
Need application-level tracing and performance monitoring
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Enter X-Ray
• Evaluated APM options including X-Ray
• It had the features we needed
• Participated in beta
• Used it for the past year
AWS X-Ray
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Trace Everything? Yes
Cloud Pricing
AWS X-Ray
Standard: Always have application-level performance monitoring
turned on for everything we build/deploy
Three reasons we chose X-Ray
Before X-Ray, cost more for tracing than compute (3X to 10X)
Focus on strategic initiatives, not infrastructureTracing as a Service
1) Check box at deploy
2) Add to POM
3) Common integration points
4) Custom measurements
Easy Integration
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
X-Ray Impact
Changed Our Team
• 2 minutes in X-Ray saves hours
• Encourages curiosity and ownership
of performance
• Graphical peer reviews
• Data-driven decisions
Enables Analytics
• URL-level performance metrics
• Export data and track changes over
time
• Track against error budgets
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Real-World Use Case
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Thanks!
“Don’t dismiss the importance of making fun a priority.”
- Truett Cathy
Contact information:
Alain Nicolet
www.linkedin.com/in/alainnicolet
Atlanta, GA
Chick-fil-A
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Additional Information
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
X-Ray Pricing
Free tier
 The first 100,000 traces recorded are free
 The first 1,000,000 traces retrieved or scanned are free
Additional charges
 Beyond the free tier, traces recorded cost $5.00 per million traces
 Beyond the free tier, traces retrieved or scanned cost $0.50 per million traces
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Helpful Links
Go to https://aws.amazon.com/xray to learn more
Documentation: http://docs.aws.amazon.com/xray/latest/devguide/aws-
xray.html
Samples:
 .NET: https://github.com/awslabs/aws-xray-dotnet-webapp
 Java: https://github.com/awslabs/eb-java-scorekeep/tree/xray
 Node.js: https://github.com/awslabs/eb-node-express-sample/tree/xray
 Python: https://github.com/awslabs/eb-py-flask-signup/tree/xray
 Lambda: https://github.com/awslabs/aws-xray-rekognition-lambda-sample
 Alarms & Alerts: https://github.com/aws-samples/aws-xray-cloudwatch-event
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Q&A
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Thank you!

More Related Content

What's hot

Enterprise Governance: Build Your AWS Landing Zone (ENT351-R1) - AWS re:Inven...
Enterprise Governance: Build Your AWS Landing Zone (ENT351-R1) - AWS re:Inven...Enterprise Governance: Build Your AWS Landing Zone (ENT351-R1) - AWS re:Inven...
Enterprise Governance: Build Your AWS Landing Zone (ENT351-R1) - AWS re:Inven...Amazon Web Services
 
[2017 Windows on AWS] AWS 를 활용한 Active Directory 연동 및 이관 방안
[2017 Windows on AWS] AWS 를 활용한 Active Directory 연동 및 이관 방안[2017 Windows on AWS] AWS 를 활용한 Active Directory 연동 및 이관 방안
[2017 Windows on AWS] AWS 를 활용한 Active Directory 연동 및 이관 방안Amazon Web Services Korea
 
Amazon Detective를 활용하여 AWS 환경에서 보안사고 원인 분석하기 – 임기성, AWS 보안 담당 솔루션즈 아키텍트:: AWS...
Amazon Detective를 활용하여 AWS 환경에서 보안사고 원인 분석하기 – 임기성, AWS 보안 담당 솔루션즈 아키텍트:: AWS...Amazon Detective를 활용하여 AWS 환경에서 보안사고 원인 분석하기 – 임기성, AWS 보안 담당 솔루션즈 아키텍트:: AWS...
Amazon Detective를 활용하여 AWS 환경에서 보안사고 원인 분석하기 – 임기성, AWS 보안 담당 솔루션즈 아키텍트:: AWS...Amazon Web Services Korea
 
Amazon GuardDuty: Intelligent Threat Detection and Continuous Monitoring to P...
Amazon GuardDuty: Intelligent Threat Detection and Continuous Monitoring to P...Amazon GuardDuty: Intelligent Threat Detection and Continuous Monitoring to P...
Amazon GuardDuty: Intelligent Threat Detection and Continuous Monitoring to P...Amazon Web Services
 
Building Event-driven Architectures with Amazon EventBridge
Building Event-driven Architectures with Amazon EventBridge Building Event-driven Architectures with Amazon EventBridge
Building Event-driven Architectures with Amazon EventBridge James Beswick
 
AWS Black Belt Techシリーズ Amazon Workspaces
AWS Black Belt Techシリーズ  Amazon WorkspacesAWS Black Belt Techシリーズ  Amazon Workspaces
AWS Black Belt Techシリーズ Amazon WorkspacesAmazon Web Services Japan
 
금융권을 위한 AWS Direct Connect 기반 하이브리드 구성 방법 - AWS Summit Seoul 2017
금융권을 위한 AWS Direct Connect 기반 하이브리드 구성 방법 - AWS Summit Seoul 2017금융권을 위한 AWS Direct Connect 기반 하이브리드 구성 방법 - AWS Summit Seoul 2017
금융권을 위한 AWS Direct Connect 기반 하이브리드 구성 방법 - AWS Summit Seoul 2017Amazon Web Services Korea
 
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container DayECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container DayAmazon Web Services Korea
 
[AWS Dev Day] 앱 현대화 | DevOps 개발자가 되기 위한 쿠버네티스 핵심 활용 예제 알아보기 - 정영준 AWS 솔루션즈 아키...
[AWS Dev Day] 앱 현대화 | DevOps 개발자가 되기 위한 쿠버네티스 핵심 활용 예제 알아보기 - 정영준 AWS 솔루션즈 아키...[AWS Dev Day] 앱 현대화 | DevOps 개발자가 되기 위한 쿠버네티스 핵심 활용 예제 알아보기 - 정영준 AWS 솔루션즈 아키...
[AWS Dev Day] 앱 현대화 | DevOps 개발자가 되기 위한 쿠버네티스 핵심 활용 예제 알아보기 - 정영준 AWS 솔루션즈 아키...Amazon Web Services Korea
 
AWS Core Services Overview, Immersion Day Huntsville 2019
AWS Core Services Overview, Immersion Day Huntsville 2019AWS Core Services Overview, Immersion Day Huntsville 2019
AWS Core Services Overview, Immersion Day Huntsville 2019Amazon Web Services
 
(DVO315) Log, Monitor and Analyze your IT with Amazon CloudWatch
(DVO315) Log, Monitor and Analyze your IT with Amazon CloudWatch(DVO315) Log, Monitor and Analyze your IT with Amazon CloudWatch
(DVO315) Log, Monitor and Analyze your IT with Amazon CloudWatchAmazon Web Services
 
CI-CD with AWS Developer Tools and Fargate_AWSPSSummit_Singapore
CI-CD with AWS Developer Tools and Fargate_AWSPSSummit_SingaporeCI-CD with AWS Developer Tools and Fargate_AWSPSSummit_Singapore
CI-CD with AWS Developer Tools and Fargate_AWSPSSummit_SingaporeAmazon Web Services
 
Deep Dive - Amazon Virtual Private Cloud (VPC)
Deep Dive - Amazon Virtual Private Cloud (VPC)Deep Dive - Amazon Virtual Private Cloud (VPC)
Deep Dive - Amazon Virtual Private Cloud (VPC)Amazon Web Services
 

What's hot (20)

Introduction to DevOps on AWS
Introduction to DevOps on AWSIntroduction to DevOps on AWS
Introduction to DevOps on AWS
 
Enterprise Governance: Build Your AWS Landing Zone (ENT351-R1) - AWS re:Inven...
Enterprise Governance: Build Your AWS Landing Zone (ENT351-R1) - AWS re:Inven...Enterprise Governance: Build Your AWS Landing Zone (ENT351-R1) - AWS re:Inven...
Enterprise Governance: Build Your AWS Landing Zone (ENT351-R1) - AWS re:Inven...
 
Amazon ECS Deep Dive
Amazon ECS Deep DiveAmazon ECS Deep Dive
Amazon ECS Deep Dive
 
[2017 Windows on AWS] AWS 를 활용한 Active Directory 연동 및 이관 방안
[2017 Windows on AWS] AWS 를 활용한 Active Directory 연동 및 이관 방안[2017 Windows on AWS] AWS 를 활용한 Active Directory 연동 및 이관 방안
[2017 Windows on AWS] AWS 를 활용한 Active Directory 연동 및 이관 방안
 
Amazon Detective를 활용하여 AWS 환경에서 보안사고 원인 분석하기 – 임기성, AWS 보안 담당 솔루션즈 아키텍트:: AWS...
Amazon Detective를 활용하여 AWS 환경에서 보안사고 원인 분석하기 – 임기성, AWS 보안 담당 솔루션즈 아키텍트:: AWS...Amazon Detective를 활용하여 AWS 환경에서 보안사고 원인 분석하기 – 임기성, AWS 보안 담당 솔루션즈 아키텍트:: AWS...
Amazon Detective를 활용하여 AWS 환경에서 보안사고 원인 분석하기 – 임기성, AWS 보안 담당 솔루션즈 아키텍트:: AWS...
 
DevOps on AWS
DevOps on AWSDevOps on AWS
DevOps on AWS
 
Amazon GuardDuty: Intelligent Threat Detection and Continuous Monitoring to P...
Amazon GuardDuty: Intelligent Threat Detection and Continuous Monitoring to P...Amazon GuardDuty: Intelligent Threat Detection and Continuous Monitoring to P...
Amazon GuardDuty: Intelligent Threat Detection and Continuous Monitoring to P...
 
Building Event-driven Architectures with Amazon EventBridge
Building Event-driven Architectures with Amazon EventBridge Building Event-driven Architectures with Amazon EventBridge
Building Event-driven Architectures with Amazon EventBridge
 
Security on AWS
Security on AWSSecurity on AWS
Security on AWS
 
Introduction to AWS IoT
Introduction to AWS IoTIntroduction to AWS IoT
Introduction to AWS IoT
 
AWS Black Belt Techシリーズ Amazon Workspaces
AWS Black Belt Techシリーズ  Amazon WorkspacesAWS Black Belt Techシリーズ  Amazon Workspaces
AWS Black Belt Techシリーズ Amazon Workspaces
 
금융권을 위한 AWS Direct Connect 기반 하이브리드 구성 방법 - AWS Summit Seoul 2017
금융권을 위한 AWS Direct Connect 기반 하이브리드 구성 방법 - AWS Summit Seoul 2017금융권을 위한 AWS Direct Connect 기반 하이브리드 구성 방법 - AWS Summit Seoul 2017
금융권을 위한 AWS Direct Connect 기반 하이브리드 구성 방법 - AWS Summit Seoul 2017
 
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container DayECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
 
AWS Technical Essentials Day
AWS Technical Essentials DayAWS Technical Essentials Day
AWS Technical Essentials Day
 
[AWS Dev Day] 앱 현대화 | DevOps 개발자가 되기 위한 쿠버네티스 핵심 활용 예제 알아보기 - 정영준 AWS 솔루션즈 아키...
[AWS Dev Day] 앱 현대화 | DevOps 개발자가 되기 위한 쿠버네티스 핵심 활용 예제 알아보기 - 정영준 AWS 솔루션즈 아키...[AWS Dev Day] 앱 현대화 | DevOps 개발자가 되기 위한 쿠버네티스 핵심 활용 예제 알아보기 - 정영준 AWS 솔루션즈 아키...
[AWS Dev Day] 앱 현대화 | DevOps 개발자가 되기 위한 쿠버네티스 핵심 활용 예제 알아보기 - 정영준 AWS 솔루션즈 아키...
 
Introducing Amazon EKS
Introducing Amazon EKSIntroducing Amazon EKS
Introducing Amazon EKS
 
AWS Core Services Overview, Immersion Day Huntsville 2019
AWS Core Services Overview, Immersion Day Huntsville 2019AWS Core Services Overview, Immersion Day Huntsville 2019
AWS Core Services Overview, Immersion Day Huntsville 2019
 
(DVO315) Log, Monitor and Analyze your IT with Amazon CloudWatch
(DVO315) Log, Monitor and Analyze your IT with Amazon CloudWatch(DVO315) Log, Monitor and Analyze your IT with Amazon CloudWatch
(DVO315) Log, Monitor and Analyze your IT with Amazon CloudWatch
 
CI-CD with AWS Developer Tools and Fargate_AWSPSSummit_Singapore
CI-CD with AWS Developer Tools and Fargate_AWSPSSummit_SingaporeCI-CD with AWS Developer Tools and Fargate_AWSPSSummit_Singapore
CI-CD with AWS Developer Tools and Fargate_AWSPSSummit_Singapore
 
Deep Dive - Amazon Virtual Private Cloud (VPC)
Deep Dive - Amazon Virtual Private Cloud (VPC)Deep Dive - Amazon Virtual Private Cloud (VPC)
Deep Dive - Amazon Virtual Private Cloud (VPC)
 

Similar to DEV204_Debugging Modern Applications Introduction to AWS X-Ray

AWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
AWS X-Ray: Debugging Applications at Scale - AWS Online Tech TalksAWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
AWS X-Ray: Debugging Applications at Scale - AWS Online Tech TalksAmazon Web Services
 
SID344-Soup to Nuts Identity Federation for AWS
SID344-Soup to Nuts Identity Federation for AWSSID344-Soup to Nuts Identity Federation for AWS
SID344-Soup to Nuts Identity Federation for AWSAmazon Web Services
 
Application Performance Management on AWS
Application Performance Management on AWSApplication Performance Management on AWS
Application Performance Management on AWSAmazon Web Services
 
Deep-Dive for AWS X-Ray - DEV402 - re:Invent 2017
Deep-Dive for AWS X-Ray - DEV402 - re:Invent 2017Deep-Dive for AWS X-Ray - DEV402 - re:Invent 2017
Deep-Dive for AWS X-Ray - DEV402 - re:Invent 2017Amazon Web Services
 
Genomics on aws-webinar-april2018
Genomics on aws-webinar-april2018Genomics on aws-webinar-april2018
Genomics on aws-webinar-april2018Brendan Bouffler
 
Debug your Container and Serverless Applications with AWS X-Ray in 5 Minutes ...
Debug your Container and Serverless Applications with AWS X-Ray in 5 Minutes ...Debug your Container and Serverless Applications with AWS X-Ray in 5 Minutes ...
Debug your Container and Serverless Applications with AWS X-Ray in 5 Minutes ...Amazon Web Services
 
Use Amazon Rekognition to Build a Facial Recognition System
Use Amazon Rekognition to Build a Facial Recognition SystemUse Amazon Rekognition to Build a Facial Recognition System
Use Amazon Rekognition to Build a Facial Recognition SystemAmazon Web Services
 
Use Amazon Rekognition to Build a Facial Recognition System
Use Amazon Rekognition to Build a Facial Recognition SystemUse Amazon Rekognition to Build a Facial Recognition System
Use Amazon Rekognition to Build a Facial Recognition SystemAmazon Web Services
 
Serverless Architecture Patterns
Serverless Architecture PatternsServerless Architecture Patterns
Serverless Architecture PatternsAmazon Web Services
 
Soup to Nuts: Identity Federation for AWS
Soup to Nuts: Identity Federation for AWSSoup to Nuts: Identity Federation for AWS
Soup to Nuts: Identity Federation for AWSAmazon Web Services
 
High-Throughput Genomics on AWS - LFS309 - re:Invent 2017
High-Throughput Genomics on AWS - LFS309 - re:Invent 2017High-Throughput Genomics on AWS - LFS309 - re:Invent 2017
High-Throughput Genomics on AWS - LFS309 - re:Invent 2017Amazon Web Services
 
LFS309-High-Throughput Genomics on AWS.pdf
LFS309-High-Throughput Genomics on AWS.pdfLFS309-High-Throughput Genomics on AWS.pdf
LFS309-High-Throughput Genomics on AWS.pdfAmazon Web Services
 
DEV203_Launch Applications the Amazon Way
DEV203_Launch Applications the Amazon WayDEV203_Launch Applications the Amazon Way
DEV203_Launch Applications the Amazon WayAmazon Web Services
 
Journey Towards Scaling Your API to 10 Million Users
Journey Towards Scaling Your API to 10 Million UsersJourney Towards Scaling Your API to 10 Million Users
Journey Towards Scaling Your API to 10 Million UsersAdrian Hornsby
 
Debugging Modern Applications: Introduction to AWS X-Ray
Debugging Modern Applications: Introduction to AWS X-RayDebugging Modern Applications: Introduction to AWS X-Ray
Debugging Modern Applications: Introduction to AWS X-RayAmazon Web Services
 
I Want to Analyze and Visualize Website Access Logs, but Why Do I Need Server...
I Want to Analyze and Visualize Website Access Logs, but Why Do I Need Server...I Want to Analyze and Visualize Website Access Logs, but Why Do I Need Server...
I Want to Analyze and Visualize Website Access Logs, but Why Do I Need Server...Amazon Web Services
 
Building .NET-based Serverless Architectures and Running .NET Core Microservi...
Building .NET-based Serverless Architectures and Running .NET Core Microservi...Building .NET-based Serverless Architectures and Running .NET Core Microservi...
Building .NET-based Serverless Architectures and Running .NET Core Microservi...Amazon Web Services
 
Instrumenting Kubernetes for Observability Using AWS X-Ray and Amazon CloudWa...
Instrumenting Kubernetes for Observability Using AWS X-Ray and Amazon CloudWa...Instrumenting Kubernetes for Observability Using AWS X-Ray and Amazon CloudWa...
Instrumenting Kubernetes for Observability Using AWS X-Ray and Amazon CloudWa...Amazon Web Services
 
Serverless in Action on AWS
Serverless in Action on AWSServerless in Action on AWS
Serverless in Action on AWSAdrian Hornsby
 
Serverless Architectural Patterns
Serverless Architectural PatternsServerless Architectural Patterns
Serverless Architectural PatternsAmazon Web Services
 

Similar to DEV204_Debugging Modern Applications Introduction to AWS X-Ray (20)

AWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
AWS X-Ray: Debugging Applications at Scale - AWS Online Tech TalksAWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
AWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
 
SID344-Soup to Nuts Identity Federation for AWS
SID344-Soup to Nuts Identity Federation for AWSSID344-Soup to Nuts Identity Federation for AWS
SID344-Soup to Nuts Identity Federation for AWS
 
Application Performance Management on AWS
Application Performance Management on AWSApplication Performance Management on AWS
Application Performance Management on AWS
 
Deep-Dive for AWS X-Ray - DEV402 - re:Invent 2017
Deep-Dive for AWS X-Ray - DEV402 - re:Invent 2017Deep-Dive for AWS X-Ray - DEV402 - re:Invent 2017
Deep-Dive for AWS X-Ray - DEV402 - re:Invent 2017
 
Genomics on aws-webinar-april2018
Genomics on aws-webinar-april2018Genomics on aws-webinar-april2018
Genomics on aws-webinar-april2018
 
Debug your Container and Serverless Applications with AWS X-Ray in 5 Minutes ...
Debug your Container and Serverless Applications with AWS X-Ray in 5 Minutes ...Debug your Container and Serverless Applications with AWS X-Ray in 5 Minutes ...
Debug your Container and Serverless Applications with AWS X-Ray in 5 Minutes ...
 
Use Amazon Rekognition to Build a Facial Recognition System
Use Amazon Rekognition to Build a Facial Recognition SystemUse Amazon Rekognition to Build a Facial Recognition System
Use Amazon Rekognition to Build a Facial Recognition System
 
Use Amazon Rekognition to Build a Facial Recognition System
Use Amazon Rekognition to Build a Facial Recognition SystemUse Amazon Rekognition to Build a Facial Recognition System
Use Amazon Rekognition to Build a Facial Recognition System
 
Serverless Architecture Patterns
Serverless Architecture PatternsServerless Architecture Patterns
Serverless Architecture Patterns
 
Soup to Nuts: Identity Federation for AWS
Soup to Nuts: Identity Federation for AWSSoup to Nuts: Identity Federation for AWS
Soup to Nuts: Identity Federation for AWS
 
High-Throughput Genomics on AWS - LFS309 - re:Invent 2017
High-Throughput Genomics on AWS - LFS309 - re:Invent 2017High-Throughput Genomics on AWS - LFS309 - re:Invent 2017
High-Throughput Genomics on AWS - LFS309 - re:Invent 2017
 
LFS309-High-Throughput Genomics on AWS.pdf
LFS309-High-Throughput Genomics on AWS.pdfLFS309-High-Throughput Genomics on AWS.pdf
LFS309-High-Throughput Genomics on AWS.pdf
 
DEV203_Launch Applications the Amazon Way
DEV203_Launch Applications the Amazon WayDEV203_Launch Applications the Amazon Way
DEV203_Launch Applications the Amazon Way
 
Journey Towards Scaling Your API to 10 Million Users
Journey Towards Scaling Your API to 10 Million UsersJourney Towards Scaling Your API to 10 Million Users
Journey Towards Scaling Your API to 10 Million Users
 
Debugging Modern Applications: Introduction to AWS X-Ray
Debugging Modern Applications: Introduction to AWS X-RayDebugging Modern Applications: Introduction to AWS X-Ray
Debugging Modern Applications: Introduction to AWS X-Ray
 
I Want to Analyze and Visualize Website Access Logs, but Why Do I Need Server...
I Want to Analyze and Visualize Website Access Logs, but Why Do I Need Server...I Want to Analyze and Visualize Website Access Logs, but Why Do I Need Server...
I Want to Analyze and Visualize Website Access Logs, but Why Do I Need Server...
 
Building .NET-based Serverless Architectures and Running .NET Core Microservi...
Building .NET-based Serverless Architectures and Running .NET Core Microservi...Building .NET-based Serverless Architectures and Running .NET Core Microservi...
Building .NET-based Serverless Architectures and Running .NET Core Microservi...
 
Instrumenting Kubernetes for Observability Using AWS X-Ray and Amazon CloudWa...
Instrumenting Kubernetes for Observability Using AWS X-Ray and Amazon CloudWa...Instrumenting Kubernetes for Observability Using AWS X-Ray and Amazon CloudWa...
Instrumenting Kubernetes for Observability Using AWS X-Ray and Amazon CloudWa...
 
Serverless in Action on AWS
Serverless in Action on AWSServerless in Action on AWS
Serverless in Action on AWS
 
Serverless Architectural Patterns
Serverless Architectural PatternsServerless Architectural Patterns
Serverless Architectural Patterns
 

More from Amazon Web Services

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Amazon Web Services
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Amazon Web Services
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateAmazon Web Services
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSAmazon Web Services
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Amazon Web Services
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Amazon Web Services
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...Amazon Web Services
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsAmazon Web Services
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareAmazon Web Services
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSAmazon Web Services
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAmazon Web Services
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareAmazon Web Services
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWSAmazon Web Services
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckAmazon Web Services
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without serversAmazon Web Services
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...Amazon Web Services
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceAmazon Web Services
 

More from Amazon Web Services (20)

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS Fargate
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWS
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot
 
Open banking as a service
Open banking as a serviceOpen banking as a service
Open banking as a service
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
 
Computer Vision con AWS
Computer Vision con AWSComputer Vision con AWS
Computer Vision con AWS
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatare
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e web
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWS
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch Deck
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
 
Fundraising Essentials
Fundraising EssentialsFundraising Essentials
Fundraising Essentials
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container Service
 

DEV204_Debugging Modern Applications Introduction to AWS X-Ray

  • 1. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AWS re:INVENT Debugging Modern Applications: Introduction to AWS X-Ray A b h i s h e k S i n g h ( A W S ) A l a i n N i c o l e t ( C h i c k - f i l - A ) D E V 2 0 4 N o v e m b e r 2 8 , 2 0 1 7
  • 2. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. What to Expect from the Session  Overview  Concepts  Use cases  Getting started  Customer story  Q&A
  • 3. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Debugging Applications
  • 4. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Traditional Debugging Developer Local Test Developer Add Breakpoints Add Log Statements
  • 5. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Monolithic vs. Service-Oriented Architecture Service-Oriented Architecture Monolithic
  • 6. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. The traditional process of debugging doesn’t scale well for production applications or those built using a service- oriented, microservice, or serverless architecture It’s tedious, repetitive, and time consuming
  • 7. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Challenges Services such as AWS Lambda, Amazon EC2 Container Service, AWS Elastic Beanstalk, AWS CloudFormation, etc., make it easier to deploy and manage applications consisting of hundreds of services Deploying and managing service-oriented applications can be more work compared to monolithic applications Still hard to debug application issues in production applications due to:  Cross-service interactions  Varying log formats across services  Collecting, aggregating, and collating logs from services
  • 8. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Log-Centric Approach service 1 logs service 2 logs service 3 logs user
  • 9. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. User-Centric Approach user Amazon DynamoDB Amazon SQS queue Frontend API
  • 10. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Identify Performance Bottlenecks How Does AWS X-Ray help? Pinpoint Specific Service Issues Identify Errors Identify Impact to Users
  • 11. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Concepts
  • 12. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. X-Ray Concepts user Amazon DynamoDB table Amazon SQS queue Frontend API
  • 13. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. X-Ray Concepts Trace End-to-end data related a single request across services Segments Portions of the trace that correspond to a single service Sub-segments Remote call or local compute sections within a service Annotations Business data that can be used to filter traces Metadata Business data that can be added to the trace but not used for filtering traces Errors Normalized error message and stack trace Sampling Percentage of requests to your application to capture as traces
  • 14. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Use Cases
  • 15. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Visualize Service Call Graph
  • 16. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Identify Impact
  • 17. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Pinpoint Issues
  • 18. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Pinpoint Issues
  • 19. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Pinpoint Issues
  • 20. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Identify Performance Bottlenecks
  • 21. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Identify Performance Bottlenecks
  • 22. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Identify Performance Bottlenecks
  • 23. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Identify Performance Bottlenecks
  • 24. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AWS Lambda (Initialization)
  • 25. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AWS Lambda (Existing Container)
  • 26. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AWS Lambda (Exceptions)
  • 27. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AWS Lambda (Exception Details)
  • 28. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Advanced Use Cases Use Off-Cloud Custom Payload Deep Linking Custom Apps via API Filter Expressions
  • 29. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Interested in building custom apps? DEV402: Deep-Dive for AWS X-Ray Thursday (11/30) @ 1:00 p.m. Venetian, Level 2, Titian 2204
  • 30. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. How Does AWS X-Ray Work?
  • 31. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. X-Ray SDK Enables you to get started quickly without having to manually instrument your application code to log metadata about requests Source on GitHub under https://www.github.com/aws/ Available for Java, .NET, Python, Go, and Node.js Adds filters to automatically capture metadata for calls to:  AWS services using the AWS SDK  Non-AWS services over HTTP and HTTPS  Databases (MySQL, PostgreSQL, and Amazon DynamoDB)  Queues (Amazon SQS)
  • 32. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. X-Ray Daemon Receives data from the SDK over UDP and acts as a local buffer; data is flushed to the backend every second or when the local buffer fills Available for Amazon Linux AMI, RHEL, Ubuntu, OS X, and Windows Pre-installed on AWS Lambda Can be run anywhere as long as AWS credentials are provided (for example, EC2, ECS, on-premises, developer machine, and others)
  • 33. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. X-Ray Service
  • 34. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Trace ID & Propagation
  • 35. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Trace ID & Propagation
  • 36. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Trace ID & Propagation
  • 37. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Trace ID & Propagation
  • 38. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Trace ID & Propagation
  • 39. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Trace ID & Propagation
  • 40. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Trace ID & Propagation
  • 41. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Trace ID & Propagation
  • 42. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Trace ID & Propagation
  • 43. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. App & X-Ray SDK EC2 Instance X-Ray Daemon Localhost UDP X-Ray API HTTPS HTTPS X-Ray Console App & X-Ray SDK Server X-Ray Daemon Localhost UDP EC2 Role AWS Credentials DevOps Team HTTPS X-Ray Workflow
  • 44. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Sampling Configuration { "rules": { “payment": { "id": 1, "service_name": "*", "http_method": "*", "url_path": "/api/payment/*", "fixed_target": 0, "rate": 1.00 }, "base": { "id": 2, "service_name": "*", "http_method": "*", "url_path": "*", "fixed_target": 1, "rate": 0.1 } } } This example defines two rules: The first rule applies a 100% sampling rate with no minimum number of requests to trace to requests with paths under /api/payment The second overrides the default sampling rule with a rule that traces the first request each second and 10% of additional requests
  • 45. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. APIs
  • 46. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. X-Ray API X-Ray provides a set of APIs to enable you to send, filter, and retrieve trace data You can send trace data directly to the service without having to use our SDKs (that is, you can write your own SDKs for languages not currently supported) Raw trace data is available using batch get APIs You can build your own data analysis applications on top of the data collected by X-Ray
  • 47. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. X-Ray API PutTraceSegments Uploads segment documents to AWS X-Ray BatchGetTraces Retrieves a list of traces specified by ID GetServiceGraph Retrieves a document that describes services in your application and their connections GetTraceSummaries Retrieves IDs and metadata for traces available for a specified time frame using an optional filter
  • 48. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Segment Document Minimal example { "name" : "example.com", "id" : "70de5b6f19ff9a0a", "start_time" : 1.478293361271E9, "trace_id" : "1-581cf771-a006649127e371903a2de979", "end_time" : 1.478293361449E9 } Example showing an in-progress segment { "name" : "example.com", "id" : "70de5b6f19ff9a0b", "start_time" : 1.478293361271E9, "trace_id" : "1-581cf771-a006649127e371903a2de979", “in_progress”: true }
  • 49. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Getting Started
  • 50. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Agent Installation (Amazon EC2 Linux) #!/bin/bash curl https://s3.dualstack.us-east-1.amazonaws.com/aws-xray-assets.us-east-1/xray-daemon/aws-xray- daemon-1.x.rpm -o /home/ec2-user/xray.rpm yum install -y /home/ec2-user/xray.rpm
  • 51. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Agent Installation (Amazon EC2 Windows)
  • 52. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Agent Installation (Amazon ECS)
  • 53. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. App Instrumentation (Node.js) //Add aws-xray-sdk package to package.json var XRay = require('aws-xray-sdk'); var AWS = captureAWS(require('aws-sdk')); … XRay.config([XRay.plugins.EC2]); XRay.captureHTTPs(http); XRay.setDefaultName('myfrontend-dev'); … app.use(XRay.express.openSegment()); app.get('/', function(req, res) … app.get('/blog', function(req, res) … app.use(XRay.express.closeSegment());
  • 54. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Customer Story
  • 55. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Introduction Alain Nicolet Enterprise Architect for Operator and Restaurant facing systems Atlanta, Georgia Chick-fil-A
  • 56. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Cloud + DevOps + Microservices Journey
  • 57. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Spring Boot Operator Mobile App • Sales Metrics API • Labor API • Truck Tracking API • User Preferences API • News API • And More Use Case AWS Lambda AWS Elastic Beanstalk Amazon DynamoDB
  • 58. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Successful, Not Perfect!  Made a big impact  Positive feedback from operators!  Microservices are awesome! X Debugging is log-based, annoying, and slow Need application-level tracing and performance monitoring
  • 59. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Enter X-Ray • Evaluated APM options including X-Ray • It had the features we needed • Participated in beta • Used it for the past year AWS X-Ray
  • 60. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Trace Everything? Yes Cloud Pricing AWS X-Ray Standard: Always have application-level performance monitoring turned on for everything we build/deploy Three reasons we chose X-Ray Before X-Ray, cost more for tracing than compute (3X to 10X) Focus on strategic initiatives, not infrastructureTracing as a Service 1) Check box at deploy 2) Add to POM 3) Common integration points 4) Custom measurements Easy Integration
  • 61. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. X-Ray Impact Changed Our Team • 2 minutes in X-Ray saves hours • Encourages curiosity and ownership of performance • Graphical peer reviews • Data-driven decisions Enables Analytics • URL-level performance metrics • Export data and track changes over time • Track against error budgets
  • 62. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Real-World Use Case
  • 63. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
  • 64. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
  • 65. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
  • 66. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
  • 67. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
  • 68. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Thanks! “Don’t dismiss the importance of making fun a priority.” - Truett Cathy Contact information: Alain Nicolet www.linkedin.com/in/alainnicolet Atlanta, GA Chick-fil-A
  • 69. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Additional Information
  • 70. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. X-Ray Pricing Free tier  The first 100,000 traces recorded are free  The first 1,000,000 traces retrieved or scanned are free Additional charges  Beyond the free tier, traces recorded cost $5.00 per million traces  Beyond the free tier, traces retrieved or scanned cost $0.50 per million traces
  • 71. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Helpful Links Go to https://aws.amazon.com/xray to learn more Documentation: http://docs.aws.amazon.com/xray/latest/devguide/aws- xray.html Samples:  .NET: https://github.com/awslabs/aws-xray-dotnet-webapp  Java: https://github.com/awslabs/eb-java-scorekeep/tree/xray  Node.js: https://github.com/awslabs/eb-node-express-sample/tree/xray  Python: https://github.com/awslabs/eb-py-flask-signup/tree/xray  Lambda: https://github.com/awslabs/aws-xray-rekognition-lambda-sample  Alarms & Alerts: https://github.com/aws-samples/aws-xray-cloudwatch-event
  • 72. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Q&A
  • 73. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Thank you!