[フレーム]
PDF, PPTX11,694 views

AWS Game Analytics - GDC 2014

This document discusses using AWS services like S3, Redshift, DynamoDB and EMR to analyze game analytics data from mobile games. It provides examples of collecting and storing event data from games, then loading and analyzing that data in Redshift to gain insights into player behavior and retention. Cohort analysis is highlighted as a way to group players by attributes like install date and then measure retention across cohorts over time. The document emphasizes starting simply and expanding the solution over time to incorporate more data sources and analytics use cases.

Download as PDF, PPTX
50 / 53AWS Gaming Solutions | GDC 2014 Death in Real-Time PUT "kills" {"game_id":"e4b5","map":"Boston","killer":38,"victim":39,"coord":"274,591,48"} PUT "kills" {"game_id":"e4b5","map":"Boston","killer":13,"victim":27,"coord":"101,206,35"} PUT "kills" {"game_id":"e4b5","map":"Boston","killer":38,"victim":39,"coord":"165,609,17"} PUT "kills" {"game_id":"e4b5","map":"Boston","killer":6,"victim":29,"coord":"120,422,26"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":34,"victim":18,"coord":"163,677,18"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":20,"victim":37,"coord":"71,473,20"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":21,"victim":19,"coord":"332,381,17"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":0,"victim":10,"coord":"14,108,25"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":32,"victim":18,"coord":"13,685,32"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":7,"victim":14,"coord":"16,233,16"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":27,"victim":19,"coord":"16,498,29"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":1,"victim":38,"coord":"138,732,21"}
AWS Gaming Solutions | GDC 2014 Game Analytics with AWS Or, How to learn what your players love so they will love your game Nate Wiger @nateware | Principal Gaming Solutions Architect
AWS Gaming Solutions | GDC 2014 Mobile Game Landscape • Free To Play • In-App Purchases • Long-Tail • Cross-Platform • Go Global • User Retention = Revenue
AWS Gaming Solutions | GDC 2014 Projected Mobile App Revenue 0 10000 20000 30000 40000 50000 60000 70000 80000 90000 2011 2012 2013 2014 2015 2016 2017 Ads IAP Paid Source: Gartner
AWS Gaming Solutions | GDC 2014 Winning at Free to Play • Phase 1: Collect Data • Phase 2: Analyze • Phase 3: Profit
AWS Gaming Solutions | GDC 2014 Analyze What? Emotions • Enjoying game • Engaged • Like/dislike new content • Stuck on a level • Bored • Abandonment Behaviors • Hours played day/week • Number of sessions/day • Level progression • Friend invites/referrals • Response to mobile push • Money spent/week
AWS Gaming Solutions | GDC 2014 Example: Level Progression (One Metric) 0 2 4 6 8 10 L1 L2 L3 L4 L5 L6 L7 L8 L9 L10 Tries / Level # of Tries
AWS Gaming Solutions | GDC 2014 Example: Level Progression (Two Metrics) 0 10 20 30 40 50 60 0 2 4 6 8 10 L1 L2 L3 L4 L5 L6 L7 L8 L9 L10 Tries / Level % Highest Level # of Tries
AWS Gaming Solutions | GDC 2014 Key Takeaways • Multiple data sources • Correlate variables • Deltas vs absolutes • Settle on terminology (game vs level) • Time matters
AWS Gaming Solutions | GDC 2014
AWS Gaming Solutions | GDC 2014 Events & Metrics • Event = Moment in Time – Login/quit – Game start/end – Level up – In-app purchase • Metrics = What to Measure – KISS – Numbers – Booleans – Strings (Enums) • Always Include (ALWAYS) – User – Action – Session (context-dependent) – Timestamp in ISO8601 2014-­‐03-­‐16T16:28:26
AWS Gaming Solutions | GDC 2014 Off The Shelf Analytics • Easy To Integrate • Pre-Baked Reports • Rate Limits • Retention Windows • Data Lock-In
AWS Gaming Solutions | GDC 2014 Ok, A Real Business Plan Ingest Store Process Analyze
AWS Gaming Solutions | GDC 2014 Ok, A Real Business Plan Ingest • HTTP PUT • Kafka • Kinesis • Scribe Store • S3 • DynamoDB • HDFS • Redshift Process • EMR (Hadoop) • Spark • Storm Analyze • Tableau • Pentaho • Jaspersoft
AWS Gaming Solutions | GDC 2014 • Write Events File on Device • Periodically Upload to S3 • Process into Redshift • Point GUI Tool to Redshift Start Simple 2014-­‐01-­‐24,nateware,e4df,login 2014-­‐01-­‐24,nateware,e4df,gamestart 2014-­‐01-­‐24,nateware,e4df,gameend 2014-­‐01-­‐25,nateware,a88c,login 2014-­‐01-­‐25,nateware,a88c,friendlist 2014-­‐01-­‐25,nateware,a88c,gamestart Profit!
AWS Gaming Solutions | GDC 2014 Redshift at a Glance 10 GigE (HPC) Ingestion Backup Restore SQL Clients/BI Tools 128GB RAM 16TB disk 16 cores Amazon S3/DynamoDB JDBC/ODBC 128GB RAM 16TB disk 16 coresCompute Node 128GB RAM 16TB disk 16 coresCompute Node 128GB RAM 16TB disk 16 coresCompute Node Leader Node • Leader Node – SQL endpoint – Stores metadata – Coordinates query execution • Compute Nodes – Columnar table storage – Load, backup, restore via Amazon S3 – Parallel load from Amazon DynamoDB • Single node version available
AWS Gaming Solutions | GDC 2014 Tableau + Redshift
AWS Gaming Solutions | GDC 2014 Plumbing 1 Create S3 bucket ("mygame-analytics-events") 2 Request a security token for your mobile app: http://docs.aws.amazon.com/STS/latest/UsingSTS/Welcome.html 3 Upload data from your users' devices 4 Run a scheduled copy to Redshift 5 Setup Tableau to access Redshift 6 Go to the Beach
AWS Gaming Solutions | GDC 2014 Loading Redshift from S3 copy events from 's3://mygame-­‐analytics-­‐events' credentials 'aws_access_key_id=<access-­‐key-­‐id>; aws_secret_access_key=<secret-­‐access-­‐key>' delimiter=','; Scheduled Redshift Load using Data Pipeline: http://aws.amazon.com/articles/1143507459230804
AWS Gaming Solutions | GDC 2014 • Also Collect Server Logs • Periodically Upload to S3 • Stuff into Redshift • External Analytics Data Too More Data Sources EC2 External Analytics
AWS Gaming Solutions | GDC 2014 Logrotate to S3 /var/log/apache2/*.log { sharedscripts postrotate sudo /usr/sbin/apache2ctl graceful s3cmd sync /var/log/*.gz s3://mygame-­‐logs/ endscript } Blog Entry on Log Rotation: http://www.dowdandassociates.com/blog/content/howto-rotate-logs-to-s3/ And/or, Use ELB Access Logs: http://docs.aws.amazon.com/ElasticLoadBalancing/latest/DeveloperGuide/ access-log-collection.html
AWS Gaming Solutions | GDC 2014 • Different File Formats • Device vs Apache vs CDN • Cleanup with EMR Job • Output to Clean Bucket • Load into Redshift Dealing With Messy Data EC2
AWS Gaming Solutions | GDC 2014 Redshift vs Elastic MapReduce Redshift • Columnar DB • Familiar SQL • Structured Data • Batch Load • Faster to Query • Long-term Storage Elastic MapReduce • Hadoop • Hive/Pig are SQL-like • Unstructured Data • Streaming Loop • Scales > PB's • Transient
AWS Gaming Solutions | GDC 2014 • Integrate Game DB • Load Directly into Redshift • Redshift does Intelligent Merge • Tracks Hash Keys, Columns Direct From DynamoDB EC2
AWS Gaming Solutions | GDC 2014 • Integrate Game DB • Load Directly into Redshift • Redshift does Intelligent Merge • Tracks Hash Keys, Columns • Or Stream into EMR Direct From DynamoDB EC2
AWS Gaming Solutions | GDC 2014 Loading Redshift from DynamoDB copy games from 'dynamodb://games' credentials 'aws_access_key_id=<access-­‐key-­‐id>; aws_secret_access_key=<secret-­‐access-­‐key>'; copy events from 's3://mygame-­‐analytics-­‐events' credentials 'aws_access_key_id=<access-­‐key-­‐id>; aws_secret_access_key=<secret-­‐access-­‐key>' delimiter=',';
AWS Gaming Solutions | GDC 2014
AWS Gaming Solutions | GDC 2014 Funnel Cake
AWS Gaming Solutions | GDC 2014 Back To Basics 2014-­‐01-­‐24,nateware,e4df,login 2014-­‐01-­‐24,nateware,e4df,gamestart 2014-­‐01-­‐24,nateware,e4df,gameend 2014-­‐01-­‐25,nateware,a88c,login 2014-­‐01-­‐25,nateware,a88c,friendlist 2014-­‐01-­‐25,nateware,a88c,gamestart
AWS Gaming Solutions | GDC 2014 Measure Retention: Repeated Plays create view events_by_user_by_month as select user_id, date_trunc('month', event_date) as month_active, count(*) as total_events from events group by user_id, month_active;
AWS Gaming Solutions | GDC 2014 First-Pass Retention – Too Noisy 0 5 10 15 20 25 30 35 40 # Play Sessions / Month nateware Lazyd0g AK187 3strikes
AWS Gaming Solutions | GDC 2014 Cohorts & Cambria • Enables calculating relative metrics • Group users by a common attribute – Month game installed – Demographics • Run analysis by cohort – Join with metrics • Use Redshift as it's SQL – Example of where SQL is a good fit
AWS Gaming Solutions | GDC 2014 Creating Cohorts with Redshift create view cohort_by_first_event_date as select user_id, date_trunc('month', min(event_date)) as first_month from events group by user_id; http://snowplowanalytics.com/analytics/customer- analytics/cohort-analysis.html
AWS Gaming Solutions | GDC 2014 Retention by Cohort – Join Events with Cohort 0 5 10 15 20 25 Week 1 Week 2 Week 3 Week 5 Week 6 Week 7 # Sessions / Week 2013-11 2013-12 2014-01 2014-02 2014-03 2014-04
AWS Gaming Solutions | GDC 2014 Moar Cohorts • Define multiple cohorts – By activity, time, demographics – As many as you like • Change cohort depending on analysis • Join same metrics with different cohorts – Retention by date – Retention by demographic – Retention by average plays/month quartile
AWS Gaming Solutions | GDC 2014 Example Event Stream 2014-­‐03-­‐17T09:52:08-­‐07:00,nateware,e4b5,login 2014-­‐03-­‐17T09:52:54-­‐07:00,nateware,e4b5,gamestart 2014-­‐03-­‐17T09:53:15-­‐07:00,nateware,e4b5,levelup 2014-­‐03-­‐17T09:54:06-­‐07:00,nateware,e4b5,gameend 2014-­‐03-­‐17T09:54:23-­‐07:00,nateware,30a4,gamestart 2014-­‐03-­‐17T09:55:14-­‐07:00,nateware,30a4,gameend 2014-­‐03-­‐17T09:55:41-­‐07:00,nateware,30a4,gamestart 2014-­‐03-­‐17T09:57:12-­‐07:00,nateware,6ebd,levelup 2014-­‐03-­‐17T09:58:50-­‐07:00,nateware,6ebd,levelup 2014-­‐03-­‐17T09:59:52-­‐07:00,nateware,6ebd,gameend
AWS Gaming Solutions | GDC 2014 Example Event Stream 2014-­‐03-­‐17T09:52:08-­‐07:00,nateware,e4b5,login 2014-­‐03-­‐17T09:52:54-­‐07:00,nateware,e4b5,gamestart 2014-­‐03-­‐17T09:53:15-­‐07:00,nateware,e4b5,levelup 2014-­‐03-­‐17T09:54:06-­‐07:00,nateware,e4b5,gameend 2014-­‐03-­‐17T09:54:23-­‐07:00,nateware,30a4,gamestart 2014-­‐03-­‐17T09:55:14-­‐07:00,nateware,30a4,gameend 2014-­‐03-­‐17T09:55:41-­‐07:00,nateware,30a4,gamestart 2014-­‐03-­‐17T09:57:12-­‐07:00,nateware,6ebd,levelup 2014-­‐03-­‐17T09:58:50-­‐07:00,nateware,6ebd,levelup 2014-­‐03-­‐17T09:59:52-­‐07:00,nateware,6ebd,gameend
AWS Gaming Solutions | GDC 2014 Cohorts by Type of Activity create view cohort_by_first_play_date as select user_id, date_trunc('month', min(event_date)) as first_month from events where action = 'gamestart' group by user_id;
AWS Gaming Solutions | GDC 2014
AWS Gaming Solutions | GDC 2014 Post-Match Heatmaps
AWS Gaming Solutions | GDC 2014 Real-Time Analytics Batch • What game modes do people like best? • How many people have downloaded DLC pack 2? • Where do most people die on map 4? • How many daily players are there on average? Real-Time • What game modes are people playing now? • Are more or less people downloading DLC today? • Are people dying in the same places? Different? • How many people are playing today? Variance?
AWS Gaming Solutions | GDC 2014 Why Real-Time Analytics? 30x in 24 hours What if you ran a promo?
AWS Gaming Solutions | GDC 2014 Real-Time Tools Spark • High-Performance Hadoop Alternative • Berkeley.edu • Compatible with HiveQL • 100x faster than Hadoop • Runs on EMR Kinesis • Amazon fully-managed streaming data layer • Similar to Kafka • Streams contain Shards • Each Shard ingests data up to 1MB/sec, 1000 TPS • Data stored for 24 hours
AWS Gaming Solutions | GDC 2014 • Always Batch Due to S3 Back To Basics [Dubstep Remix] EC2
AWS Gaming Solutions | GDC 2014 • Stream Data With Kinesis • Multiple Writers and Readers • Still Output to Redshift Need Data Faster! EC2
AWS Gaming Solutions | GDC 2014 • Stream Data With Kinesis • Multiple Writers and Readers • Still Output to Redshift • Stream to Spark on EMR • Storm via Kinesis Spout • Custom EC2 Workers Lots of Ins and Outs EC2 EC2
AWS Gaming Solutions | GDC 2014 Data Sources App.4 [Machine Learning] AWS Endpoint App.1 [Aggregate & De-­‐Duplicate] Data Sources Data Sources Data Sources App.2 [Metric Extrac=on] S3 DynamoDB Redshift App.3 [Sliding Window Analysis] Data Sources Availability Zone Shard 1 Shard 2 Shard N Availability Zone Availability Zone Introducing Amazon Kinesis Service for Real-Time Big Data Ingestion
AWS Gaming Solutions | GDC 2014 Putting Data into Kinesis • Producers use PUT to send data to a Stream • PutRecord {Data, PartitionKey, StreamName} • Partition Key distributes PUTs across Shards • Unique Sequence # returned on PUT call • Documentation: http://docs.aws.amazon.com/kinesis/latest/dev/ introduction.html Producer Shard 1 Shard 2 Shard 3 Shard n Shard 4 Producer Producer Producer Producer Producer Producer Producer Producer Kinesis
AWS Gaming Solutions | GDC 2014 Writing to a Kinesis Stream POST / HTTP/1.1 Host: kinesis.<region>.<domain> x-­‐amz-­‐Date: <Date> Authorization: AWS4-­‐HMAC-­‐SHA256 Credential=<Credential>, SignedHeaders=content-­‐ type;date;host;user-­‐agent;x-­‐amz-­‐date;x-­‐amz-­‐target;x-­‐amzn-­‐requestid, Signature=<Signature> User-­‐Agent: <UserAgentString> Content-­‐Type: application/x-­‐amz-­‐json-­‐1.1 Content-­‐Length: <PayloadSizeBytes> Connection: Keep-­‐Alive X-­‐Amz-­‐Target: Kinesis_20131202.PutRecord { "StreamName": "exampleStreamName", "Data": "XzxkYXRhPl8x", "PartitionKey": "partitionKey" }
AWS Gaming Solutions | GDC 2014 Kinesis + Spark http://aws.amazon.com/articles/4926593393724923
AWS Gaming Solutions | GDC 2014 Death in Real-Time PUT "kills" {"game_id":"e4b5","map":"Boston","killer":38,"victim":39,"coord":"274,591,48"} PUT "kills" {"game_id":"e4b5","map":"Boston","killer":13,"victim":27,"coord":"101,206,35"} PUT "kills" {"game_id":"e4b5","map":"Boston","killer":38,"victim":39,"coord":"165,609,17"} PUT "kills" {"game_id":"e4b5","map":"Boston","killer":6,"victim":29,"coord":"120,422,26"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":34,"victim":18,"coord":"163,677,18"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":20,"victim":37,"coord":"71,473,20"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":21,"victim":19,"coord":"332,381,17"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":0,"victim":10,"coord":"14,108,25"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":32,"victim":18,"coord":"13,685,32"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":7,"victim":14,"coord":"16,233,16"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":27,"victim":19,"coord":"16,498,29"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":1,"victim":38,"coord":"138,732,21"}
AWS Gaming Solutions | GDC 2014 Real-Time Heatmaps
AWS Gaming Solutions | GDC 2014 But A Bow On It • Collect data from the start • Store it even if you can't process it (yet) • Start simple – S3 + Redshift • Add data sources – process with EMR • Real-time – Kinesis + Spark • Tons of untapped potential for gaming
AWS Gaming Solutions | GDC 2014 Fallback Plan Cheers – Nate Wiger @nateware

More Related Content

Scalable Gaming with AWS - GDC 2014
PDF
Scalable Gaming with AWS - GDC 2014
AWS RoadShow Dublin - Intro to AWS
PDF
AWS RoadShow Dublin - Intro to AWS
GDC 2015 - Game Analytics with AWS Redshift, Kinesis, and the Mobile SDK
PDF
GDC 2015 - Game Analytics with AWS Redshift, Kinesis, and the Mobile SDK
GDC 2015 - Low-latency Multiplayer Gaming with AWS
PDF
GDC 2015 - Low-latency Multiplayer Gaming with AWS
Gaming AWS with Docker - Gluecon 2014
PPTX
Gaming AWS with Docker - Gluecon 2014
Refael Bitton @ All Things DATA 2016 - Firebase Analytics
PDF
Refael Bitton @ All Things DATA 2016 - Firebase Analytics
Implementing Analytics in High-Traffic Social Games
PPTX
Implementing Analytics in High-Traffic Social Games
Modeling of players activity by Michel pierfitte, Director of Game Analytics ...
PPTX
Modeling of players activity by Michel pierfitte, Director of Game Analytics ...
Scalable Gaming with AWS - GDC 2014
Scalable Gaming with AWS - GDC 2014
AWS RoadShow Dublin - Intro to AWS
AWS RoadShow Dublin - Intro to AWS
GDC 2015 - Game Analytics with AWS Redshift, Kinesis, and the Mobile SDK
GDC 2015 - Game Analytics with AWS Redshift, Kinesis, and the Mobile SDK
GDC 2015 - Low-latency Multiplayer Gaming with AWS
GDC 2015 - Low-latency Multiplayer Gaming with AWS
Gaming AWS with Docker - Gluecon 2014
Gaming AWS with Docker - Gluecon 2014
Refael Bitton @ All Things DATA 2016 - Firebase Analytics
Refael Bitton @ All Things DATA 2016 - Firebase Analytics
Implementing Analytics in High-Traffic Social Games
Implementing Analytics in High-Traffic Social Games
Modeling of players activity by Michel pierfitte, Director of Game Analytics ...
Modeling of players activity by Michel pierfitte, Director of Game Analytics ...

Viewers also liked

Game analytics - The challenges of mobile free-to-play games
PPTX
Game analytics - The challenges of mobile free-to-play games
Jelly Splash: Puzzling your way to the top of the App Stores - GDC 2014
PDF
Jelly Splash: Puzzling your way to the top of the App Stores - GDC 2014
How to make people love your game in 90 seconds or less
PDF
How to make people love your game in 90 seconds or less
Intro To Mobile Analytics
PDF
Intro To Mobile Analytics
7 Psychological Tactics Used in Games
PDF
7 Psychological Tactics Used in Games
GDC 2016: Modular Level Design of Fallout 4
PPTX
GDC 2016: Modular Level Design of Fallout 4
Game analytics - The challenges of mobile free-to-play games
Game analytics - The challenges of mobile free-to-play games
Jelly Splash: Puzzling your way to the top of the App Stores - GDC 2014
Jelly Splash: Puzzling your way to the top of the App Stores - GDC 2014
How to make people love your game in 90 seconds or less
How to make people love your game in 90 seconds or less
Intro To Mobile Analytics
Intro To Mobile Analytics
7 Psychological Tactics Used in Games
7 Psychological Tactics Used in Games
GDC 2016: Modular Level Design of Fallout 4
GDC 2016: Modular Level Design of Fallout 4

Similar to AWS Game Analytics - GDC 2014

Cloud Big Data Architectures
PDF
Cloud Big Data Architectures
Openbar Kontich // Google Cloud: past, present and the (oh so sweet) future b...
PDF
Openbar Kontich // Google Cloud: past, present and the (oh so sweet) future b...
Getting to 1.5M Ads/sec: How DataXu manages Big Data
PPTX
Getting to 1.5M Ads/sec: How DataXu manages Big Data
Google Cloud Dataflow Two Worlds Become a Much Better One
PDF
Google Cloud Dataflow Two Worlds Become a Much Better One
2018 07 aws windsor user group - fall project planning v1
PPTX
2018 07 aws windsor user group - fall project planning v1
Serverless without Code (Lambda)
PPTX
Serverless without Code (Lambda)
AWS for the SQL Server Pro
PPTX
AWS for the SQL Server Pro
AWS vs Azure vs Google (GCP) - Slides
PDF
AWS vs Azure vs Google (GCP) - Slides
Leapfrog into Serverless - a Deloitte-Amtrak Case Study | Serverless Confere...
PDF
Leapfrog into Serverless - a Deloitte-Amtrak Case Study | Serverless Confere...
Beyond Relational
PDF
Beyond Relational
Dsdt meetup 2017 11-21
PDF
Dsdt meetup 2017 11-21
DSDT Meetup Nov 2017
PDF
DSDT Meetup Nov 2017
AWS for Java Developers workshop
PDF
AWS for Java Developers workshop
Code first in the cloud: going serverless with Azure
PPTX
Code first in the cloud: going serverless with Azure
Azure IPaaS: Integration Evolved! (Glenn Colpaert @TechdaysNL 2017)
PPTX
Azure IPaaS: Integration Evolved! (Glenn Colpaert @TechdaysNL 2017)
Look Before You Leap: Migrating On-Premises Hadoop to AWS
PDF
Look Before You Leap: Migrating On-Premises Hadoop to AWS
Futur de l'intégration - BizTalk Server
PDF
Futur de l'intégration - BizTalk Server
The journey of Moving from AWS ELK to GCP Data Pipeline
PDF
The journey of Moving from AWS ELK to GCP Data Pipeline
Beyond serverless.pptx
PDF
Beyond serverless.pptx
How Docker Accelerates Continuous Development at ironSource: Containers #101 ...
PPTX
How Docker Accelerates Continuous Development at ironSource: Containers #101 ...
Cloud Big Data Architectures
Cloud Big Data Architectures
Openbar Kontich // Google Cloud: past, present and the (oh so sweet) future b...
Openbar Kontich // Google Cloud: past, present and the (oh so sweet) future b...
Getting to 1.5M Ads/sec: How DataXu manages Big Data
Getting to 1.5M Ads/sec: How DataXu manages Big Data
Google Cloud Dataflow Two Worlds Become a Much Better One
Google Cloud Dataflow Two Worlds Become a Much Better One
2018 07 aws windsor user group - fall project planning v1
2018 07 aws windsor user group - fall project planning v1
Serverless without Code (Lambda)
Serverless without Code (Lambda)
AWS for the SQL Server Pro
AWS for the SQL Server Pro
AWS vs Azure vs Google (GCP) - Slides
AWS vs Azure vs Google (GCP) - Slides
Leapfrog into Serverless - a Deloitte-Amtrak Case Study | Serverless Confere...
Leapfrog into Serverless - a Deloitte-Amtrak Case Study | Serverless Confere...
Beyond Relational
Beyond Relational
Dsdt meetup 2017 11-21
Dsdt meetup 2017 11-21
DSDT Meetup Nov 2017
DSDT Meetup Nov 2017
AWS for Java Developers workshop
AWS for Java Developers workshop
Code first in the cloud: going serverless with Azure
Code first in the cloud: going serverless with Azure
Azure IPaaS: Integration Evolved! (Glenn Colpaert @TechdaysNL 2017)
Azure IPaaS: Integration Evolved! (Glenn Colpaert @TechdaysNL 2017)
Look Before You Leap: Migrating On-Premises Hadoop to AWS
Look Before You Leap: Migrating On-Premises Hadoop to AWS
Futur de l'intégration - BizTalk Server
Futur de l'intégration - BizTalk Server
The journey of Moving from AWS ELK to GCP Data Pipeline
The journey of Moving from AWS ELK to GCP Data Pipeline
Beyond serverless.pptx
Beyond serverless.pptx
How Docker Accelerates Continuous Development at ironSource: Containers #101 ...
How Docker Accelerates Continuous Development at ironSource: Containers #101 ...

Recently uploaded

Writing GPU-Ready AI Models in Pure Java with Babylon
PDF
Writing GPU-Ready AI Models in Pure Java with Babylon
Session 3 - Specialized AI Associate Series: AI Powered Automation through sp...
PDF
Session 3 - Specialized AI Associate Series: AI Powered Automation through sp...
Ultimate B2B Travel API Integration for Skyrocket Bookings
PDF
Ultimate B2B Travel API Integration for Skyrocket Bookings
What Is Agentic AI and How Is It Transforming ERP Systems?
PDF
What Is Agentic AI and How Is It Transforming ERP Systems?
Session 1 - Agentic Automation Building the Enterprise Agent of Tomorrow
PDF
Session 1 - Agentic Automation Building the Enterprise Agent of Tomorrow
Certified Kubernetes Security Specialist (CKS): Unit 5
PDF
Certified Kubernetes Security Specialist (CKS): Unit 5
Lightning_talk_Mojo comparision of python vs mojo performance
PPTX
Lightning_talk_Mojo comparision of python vs mojo performance
Web Mapping 101: Creating Dynamic Web Maps with Geospatial Data
PDF
Web Mapping 101: Creating Dynamic Web Maps with Geospatial Data
Unleash the Power of Salesforce Winter ’26 Release.pdf
PDF
Unleash the Power of Salesforce Winter ’26 Release.pdf
TechVerse Kent (Combining Tech, AI, Innovation and Creativity)
PPTX
TechVerse Kent (Combining Tech, AI, Innovation and Creativity)
Top 10+ Ajax Development Companies in France
PDF
Top 10+ Ajax Development Companies in France
A Guide to Microsoft Azure's Scalable and Secure Cloud Solutions
PDF
A Guide to Microsoft Azure's Scalable and Secure Cloud Solutions
A business case for open source: From lock-in to value.pdf
PDF
A business case for open source: From lock-in to value.pdf
sap 2016年09月14日_PP_MRPType_VB_Blogged.pptx
PPTX
sap 2016年09月14日_PP_MRPType_VB_Blogged.pptx
The Role of Human Experiences (HX) in GenAI Adoption
PDF
The Role of Human Experiences (HX) in GenAI Adoption
Neural Networks in a Nutshell: A practical review and usage
PDF
Neural Networks in a Nutshell: A practical review and usage
Session 2 - Specialized AI Associate Series: Orchestrator Deep-Dive and UiPa...
PDF
Session 2 - Specialized AI Associate Series: Orchestrator Deep-Dive and UiPa...
Cloud and internet-of-things secure integration along with security concerns
PDF
Cloud and internet-of-things secure integration along with security concerns
Unit 3 DS - Distributed Data Storage and Retrieval - PowerPoint Content.pdf
PDF
Unit 3 DS - Distributed Data Storage and Retrieval - PowerPoint Content.pdf
CIDT: Blockchain, DeFi & Product Engineering - MVPs in 4 Weeks with a Senior-...
PDF
CIDT: Blockchain, DeFi & Product Engineering - MVPs in 4 Weeks with a Senior-...
Writing GPU-Ready AI Models in Pure Java with Babylon
Writing GPU-Ready AI Models in Pure Java with Babylon
Session 3 - Specialized AI Associate Series: AI Powered Automation through sp...
Session 3 - Specialized AI Associate Series: AI Powered Automation through sp...
Ultimate B2B Travel API Integration for Skyrocket Bookings
Ultimate B2B Travel API Integration for Skyrocket Bookings
What Is Agentic AI and How Is It Transforming ERP Systems?
What Is Agentic AI and How Is It Transforming ERP Systems?
Session 1 - Agentic Automation Building the Enterprise Agent of Tomorrow
Session 1 - Agentic Automation Building the Enterprise Agent of Tomorrow
Certified Kubernetes Security Specialist (CKS): Unit 5
Certified Kubernetes Security Specialist (CKS): Unit 5
Lightning_talk_Mojo comparision of python vs mojo performance
Lightning_talk_Mojo comparision of python vs mojo performance
Web Mapping 101: Creating Dynamic Web Maps with Geospatial Data
Web Mapping 101: Creating Dynamic Web Maps with Geospatial Data
Unleash the Power of Salesforce Winter ’26 Release.pdf
Unleash the Power of Salesforce Winter ’26 Release.pdf
TechVerse Kent (Combining Tech, AI, Innovation and Creativity)
TechVerse Kent (Combining Tech, AI, Innovation and Creativity)
Top 10+ Ajax Development Companies in France
Top 10+ Ajax Development Companies in France
A Guide to Microsoft Azure's Scalable and Secure Cloud Solutions
A Guide to Microsoft Azure's Scalable and Secure Cloud Solutions
A business case for open source: From lock-in to value.pdf
A business case for open source: From lock-in to value.pdf
sap 2016年09月14日_PP_MRPType_VB_Blogged.pptx
sap 2016年09月14日_PP_MRPType_VB_Blogged.pptx
The Role of Human Experiences (HX) in GenAI Adoption
The Role of Human Experiences (HX) in GenAI Adoption
Neural Networks in a Nutshell: A practical review and usage
Neural Networks in a Nutshell: A practical review and usage
Session 2 - Specialized AI Associate Series: Orchestrator Deep-Dive and UiPa...
Session 2 - Specialized AI Associate Series: Orchestrator Deep-Dive and UiPa...
Cloud and internet-of-things secure integration along with security concerns
Cloud and internet-of-things secure integration along with security concerns
Unit 3 DS - Distributed Data Storage and Retrieval - PowerPoint Content.pdf
Unit 3 DS - Distributed Data Storage and Retrieval - PowerPoint Content.pdf
CIDT: Blockchain, DeFi & Product Engineering - MVPs in 4 Weeks with a Senior-...
CIDT: Blockchain, DeFi & Product Engineering - MVPs in 4 Weeks with a Senior-...

AWS Game Analytics - GDC 2014

  • 1.
    AWS Gaming Solutions | GDC 2014 Game Analytics with AWS Or, How to learn what your players love so they will love your game Nate Wiger @nateware | Principal Gaming Solutions Architect
  • 2.
    AWS Gaming Solutions | GDC 2014 Mobile Game Landscape • Free To Play • In-App Purchases • Long-Tail • Cross-Platform • Go Global • User Retention = Revenue
  • 3.
    AWS Gaming Solutions | GDC 2014 Projected Mobile App Revenue 0 10000 20000 30000 40000 50000 60000 70000 80000 90000 2011 2012 2013 2014 2015 2016 2017 Ads IAP Paid Source: Gartner
  • 4.
    AWS Gaming Solutions | GDC 2014 Winning at Free to Play • Phase 1: Collect Data • Phase 2: Analyze • Phase 3: Profit
  • 5.
    AWS Gaming Solutions | GDC 2014 Analyze What? Emotions • Enjoying game • Engaged • Like/dislike new content • Stuck on a level • Bored • Abandonment Behaviors • Hours played day/week • Number of sessions/day • Level progression • Friend invites/referrals • Response to mobile push • Money spent/week
  • 6.
    AWS Gaming Solutions | GDC 2014 Example: Level Progression (One Metric) 0 2 4 6 8 10 L1 L2 L3 L4 L5 L6 L7 L8 L9 L10 Tries / Level # of Tries
  • 7.
    AWS Gaming Solutions | GDC 2014 Example: Level Progression (Two Metrics) 0 10 20 30 40 50 60 0 2 4 6 8 10 L1 L2 L3 L4 L5 L6 L7 L8 L9 L10 Tries / Level % Highest Level # of Tries
  • 8.
    AWS Gaming Solutions | GDC 2014 Key Takeaways • Multiple data sources • Correlate variables • Deltas vs absolutes • Settle on terminology (game vs level) • Time matters
  • 9.
  • 10.
    AWS Gaming Solutions | GDC 2014 Events & Metrics • Event = Moment in Time – Login/quit – Game start/end – Level up – In-app purchase • Metrics = What to Measure – KISS – Numbers – Booleans – Strings (Enums) • Always Include (ALWAYS) – User – Action – Session (context-dependent) – Timestamp in ISO8601 2014-­‐03-­‐16T16:28:26
  • 11.
    AWS Gaming Solutions | GDC 2014 Off The Shelf Analytics • Easy To Integrate • Pre-Baked Reports • Rate Limits • Retention Windows • Data Lock-In
  • 12.
    AWS Gaming Solutions | GDC 2014 Ok, A Real Business Plan Ingest Store Process Analyze
  • 13.
    AWS Gaming Solutions | GDC 2014 Ok, A Real Business Plan Ingest • HTTP PUT • Kafka • Kinesis • Scribe Store • S3 • DynamoDB • HDFS • Redshift Process • EMR (Hadoop) • Spark • Storm Analyze • Tableau • Pentaho • Jaspersoft
  • 14.
    AWS Gaming Solutions | GDC 2014 • Write Events File on Device • Periodically Upload to S3 • Process into Redshift • Point GUI Tool to Redshift Start Simple 2014-­‐01-­‐24,nateware,e4df,login 2014-­‐01-­‐24,nateware,e4df,gamestart 2014-­‐01-­‐24,nateware,e4df,gameend 2014-­‐01-­‐25,nateware,a88c,login 2014-­‐01-­‐25,nateware,a88c,friendlist 2014-­‐01-­‐25,nateware,a88c,gamestart Profit!
  • 15.
    AWS Gaming Solutions | GDC 2014 Redshift at a Glance 10 GigE (HPC) Ingestion Backup Restore SQL Clients/BI Tools 128GB RAM 16TB disk 16 cores Amazon S3/DynamoDB JDBC/ODBC 128GB RAM 16TB disk 16 coresCompute Node 128GB RAM 16TB disk 16 coresCompute Node 128GB RAM 16TB disk 16 coresCompute Node Leader Node • Leader Node – SQL endpoint – Stores metadata – Coordinates query execution • Compute Nodes – Columnar table storage – Load, backup, restore via Amazon S3 – Parallel load from Amazon DynamoDB • Single node version available
  • 16.
    AWS Gaming Solutions | GDC 2014 Tableau + Redshift
  • 17.
    AWS Gaming Solutions | GDC 2014 Plumbing 1 Create S3 bucket ("mygame-analytics-events") 2 Request a security token for your mobile app: http://docs.aws.amazon.com/STS/latest/UsingSTS/Welcome.html 3 Upload data from your users' devices 4 Run a scheduled copy to Redshift 5 Setup Tableau to access Redshift 6 Go to the Beach
  • 18.
    AWS Gaming Solutions | GDC 2014 Loading Redshift from S3 copy events from 's3://mygame-­‐analytics-­‐events' credentials 'aws_access_key_id=<access-­‐key-­‐id>; aws_secret_access_key=<secret-­‐access-­‐key>' delimiter=','; Scheduled Redshift Load using Data Pipeline: http://aws.amazon.com/articles/1143507459230804
  • 19.
    AWS Gaming Solutions | GDC 2014 • Also Collect Server Logs • Periodically Upload to S3 • Stuff into Redshift • External Analytics Data Too More Data Sources EC2 External Analytics
  • 20.
    AWS Gaming Solutions | GDC 2014 Logrotate to S3 /var/log/apache2/*.log { sharedscripts postrotate sudo /usr/sbin/apache2ctl graceful s3cmd sync /var/log/*.gz s3://mygame-­‐logs/ endscript } Blog Entry on Log Rotation: http://www.dowdandassociates.com/blog/content/howto-rotate-logs-to-s3/ And/or, Use ELB Access Logs: http://docs.aws.amazon.com/ElasticLoadBalancing/latest/DeveloperGuide/ access-log-collection.html
  • 21.
    AWS Gaming Solutions | GDC 2014 • Different File Formats • Device vs Apache vs CDN • Cleanup with EMR Job • Output to Clean Bucket • Load into Redshift Dealing With Messy Data EC2
  • 22.
    AWS Gaming Solutions | GDC 2014 Redshift vs Elastic MapReduce Redshift • Columnar DB • Familiar SQL • Structured Data • Batch Load • Faster to Query • Long-term Storage Elastic MapReduce • Hadoop • Hive/Pig are SQL-like • Unstructured Data • Streaming Loop • Scales > PB's • Transient
  • 23.
    AWS Gaming Solutions | GDC 2014 • Integrate Game DB • Load Directly into Redshift • Redshift does Intelligent Merge • Tracks Hash Keys, Columns Direct From DynamoDB EC2
  • 24.
    AWS Gaming Solutions | GDC 2014 • Integrate Game DB • Load Directly into Redshift • Redshift does Intelligent Merge • Tracks Hash Keys, Columns • Or Stream into EMR Direct From DynamoDB EC2
  • 25.
    AWS Gaming Solutions | GDC 2014 Loading Redshift from DynamoDB copy games from 'dynamodb://games' credentials 'aws_access_key_id=<access-­‐key-­‐id>; aws_secret_access_key=<secret-­‐access-­‐key>'; copy events from 's3://mygame-­‐analytics-­‐events' credentials 'aws_access_key_id=<access-­‐key-­‐id>; aws_secret_access_key=<secret-­‐access-­‐key>' delimiter=',';
  • 26.
  • 27.
    AWS Gaming Solutions | GDC 2014 Funnel Cake
  • 28.
    AWS Gaming Solutions | GDC 2014 Back To Basics 2014-­‐01-­‐24,nateware,e4df,login 2014-­‐01-­‐24,nateware,e4df,gamestart 2014-­‐01-­‐24,nateware,e4df,gameend 2014-­‐01-­‐25,nateware,a88c,login 2014-­‐01-­‐25,nateware,a88c,friendlist 2014-­‐01-­‐25,nateware,a88c,gamestart
  • 29.
    AWS Gaming Solutions | GDC 2014 Measure Retention: Repeated Plays create view events_by_user_by_month as select user_id, date_trunc('month', event_date) as month_active, count(*) as total_events from events group by user_id, month_active;
  • 30.
    AWS Gaming Solutions | GDC 2014 First-Pass Retention – Too Noisy 0 5 10 15 20 25 30 35 40 # Play Sessions / Month nateware Lazyd0g AK187 3strikes
  • 31.
    AWS Gaming Solutions | GDC 2014 Cohorts & Cambria • Enables calculating relative metrics • Group users by a common attribute – Month game installed – Demographics • Run analysis by cohort – Join with metrics • Use Redshift as it's SQL – Example of where SQL is a good fit
  • 32.
    AWS Gaming Solutions | GDC 2014 Creating Cohorts with Redshift create view cohort_by_first_event_date as select user_id, date_trunc('month', min(event_date)) as first_month from events group by user_id; http://snowplowanalytics.com/analytics/customer- analytics/cohort-analysis.html
  • 33.
    AWS Gaming Solutions | GDC 2014 Retention by Cohort – Join Events with Cohort 0 5 10 15 20 25 Week 1 Week 2 Week 3 Week 5 Week 6 Week 7 # Sessions / Week 2013-11 2013-12 2014-01 2014-02 2014-03 2014-04
  • 34.
    AWS Gaming Solutions | GDC 2014 Moar Cohorts • Define multiple cohorts – By activity, time, demographics – As many as you like • Change cohort depending on analysis • Join same metrics with different cohorts – Retention by date – Retention by demographic – Retention by average plays/month quartile
  • 35.
    AWS Gaming Solutions | GDC 2014 Example Event Stream 2014-­‐03-­‐17T09:52:08-­‐07:00,nateware,e4b5,login 2014-­‐03-­‐17T09:52:54-­‐07:00,nateware,e4b5,gamestart 2014-­‐03-­‐17T09:53:15-­‐07:00,nateware,e4b5,levelup 2014-­‐03-­‐17T09:54:06-­‐07:00,nateware,e4b5,gameend 2014-­‐03-­‐17T09:54:23-­‐07:00,nateware,30a4,gamestart 2014-­‐03-­‐17T09:55:14-­‐07:00,nateware,30a4,gameend 2014-­‐03-­‐17T09:55:41-­‐07:00,nateware,30a4,gamestart 2014-­‐03-­‐17T09:57:12-­‐07:00,nateware,6ebd,levelup 2014-­‐03-­‐17T09:58:50-­‐07:00,nateware,6ebd,levelup 2014-­‐03-­‐17T09:59:52-­‐07:00,nateware,6ebd,gameend
  • 36.
    AWS Gaming Solutions | GDC 2014 Example Event Stream 2014-­‐03-­‐17T09:52:08-­‐07:00,nateware,e4b5,login 2014-­‐03-­‐17T09:52:54-­‐07:00,nateware,e4b5,gamestart 2014-­‐03-­‐17T09:53:15-­‐07:00,nateware,e4b5,levelup 2014-­‐03-­‐17T09:54:06-­‐07:00,nateware,e4b5,gameend 2014-­‐03-­‐17T09:54:23-­‐07:00,nateware,30a4,gamestart 2014-­‐03-­‐17T09:55:14-­‐07:00,nateware,30a4,gameend 2014-­‐03-­‐17T09:55:41-­‐07:00,nateware,30a4,gamestart 2014-­‐03-­‐17T09:57:12-­‐07:00,nateware,6ebd,levelup 2014-­‐03-­‐17T09:58:50-­‐07:00,nateware,6ebd,levelup 2014-­‐03-­‐17T09:59:52-­‐07:00,nateware,6ebd,gameend
  • 37.
    AWS Gaming Solutions | GDC 2014 Cohorts by Type of Activity create view cohort_by_first_play_date as select user_id, date_trunc('month', min(event_date)) as first_month from events where action = 'gamestart' group by user_id;
  • 38.
  • 39.
    AWS Gaming Solutions | GDC 2014 Post-Match Heatmaps
  • 40.
    AWS Gaming Solutions | GDC 2014 Real-Time Analytics Batch • What game modes do people like best? • How many people have downloaded DLC pack 2? • Where do most people die on map 4? • How many daily players are there on average? Real-Time • What game modes are people playing now? • Are more or less people downloading DLC today? • Are people dying in the same places? Different? • How many people are playing today? Variance?
  • 41.
    AWS Gaming Solutions | GDC 2014 Why Real-Time Analytics? 30x in 24 hours What if you ran a promo?
  • 42.
    AWS Gaming Solutions | GDC 2014 Real-Time Tools Spark • High-Performance Hadoop Alternative • Berkeley.edu • Compatible with HiveQL • 100x faster than Hadoop • Runs on EMR Kinesis • Amazon fully-managed streaming data layer • Similar to Kafka • Streams contain Shards • Each Shard ingests data up to 1MB/sec, 1000 TPS • Data stored for 24 hours
  • 43.
    AWS Gaming Solutions | GDC 2014 • Always Batch Due to S3 Back To Basics [Dubstep Remix] EC2
  • 44.
    AWS Gaming Solutions | GDC 2014 • Stream Data With Kinesis • Multiple Writers and Readers • Still Output to Redshift Need Data Faster! EC2
  • 45.
    AWS Gaming Solutions | GDC 2014 • Stream Data With Kinesis • Multiple Writers and Readers • Still Output to Redshift • Stream to Spark on EMR • Storm via Kinesis Spout • Custom EC2 Workers Lots of Ins and Outs EC2 EC2
  • 46.
    AWS Gaming Solutions | GDC 2014 Data Sources App.4 [Machine Learning] AWS Endpoint App.1 [Aggregate & De-­‐Duplicate] Data Sources Data Sources Data Sources App.2 [Metric Extrac=on] S3 DynamoDB Redshift App.3 [Sliding Window Analysis] Data Sources Availability Zone Shard 1 Shard 2 Shard N Availability Zone Availability Zone Introducing Amazon Kinesis Service for Real-Time Big Data Ingestion
  • 47.
    AWS Gaming Solutions | GDC 2014 Putting Data into Kinesis • Producers use PUT to send data to a Stream • PutRecord {Data, PartitionKey, StreamName} • Partition Key distributes PUTs across Shards • Unique Sequence # returned on PUT call • Documentation: http://docs.aws.amazon.com/kinesis/latest/dev/ introduction.html Producer Shard 1 Shard 2 Shard 3 Shard n Shard 4 Producer Producer Producer Producer Producer Producer Producer Producer Kinesis
  • 48.
    AWS Gaming Solutions | GDC 2014 Writing to a Kinesis Stream POST / HTTP/1.1 Host: kinesis.<region>.<domain> x-­‐amz-­‐Date: <Date> Authorization: AWS4-­‐HMAC-­‐SHA256 Credential=<Credential>, SignedHeaders=content-­‐ type;date;host;user-­‐agent;x-­‐amz-­‐date;x-­‐amz-­‐target;x-­‐amzn-­‐requestid, Signature=<Signature> User-­‐Agent: <UserAgentString> Content-­‐Type: application/x-­‐amz-­‐json-­‐1.1 Content-­‐Length: <PayloadSizeBytes> Connection: Keep-­‐Alive X-­‐Amz-­‐Target: Kinesis_20131202.PutRecord { "StreamName": "exampleStreamName", "Data": "XzxkYXRhPl8x", "PartitionKey": "partitionKey" }
  • 49.
    AWS Gaming Solutions | GDC 2014 Kinesis + Spark http://aws.amazon.com/articles/4926593393724923
  • 50.
    AWS Gaming Solutions | GDC 2014 Death in Real-Time PUT "kills" {"game_id":"e4b5","map":"Boston","killer":38,"victim":39,"coord":"274,591,48"} PUT "kills" {"game_id":"e4b5","map":"Boston","killer":13,"victim":27,"coord":"101,206,35"} PUT "kills" {"game_id":"e4b5","map":"Boston","killer":38,"victim":39,"coord":"165,609,17"} PUT "kills" {"game_id":"e4b5","map":"Boston","killer":6,"victim":29,"coord":"120,422,26"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":34,"victim":18,"coord":"163,677,18"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":20,"victim":37,"coord":"71,473,20"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":21,"victim":19,"coord":"332,381,17"} PUT "kills" {"game_id":"30a4","map":"Los Angeles","killer":0,"victim":10,"coord":"14,108,25"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":32,"victim":18,"coord":"13,685,32"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":7,"victim":14,"coord":"16,233,16"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":27,"victim":19,"coord":"16,498,29"} PUT "kills" {"game_id":"6ebd","map":"Seattle","killer":1,"victim":38,"coord":"138,732,21"}
  • 51.
    AWS Gaming Solutions | GDC 2014 Real-Time Heatmaps
  • 52.
    AWS Gaming Solutions | GDC 2014 But A Bow On It • Collect data from the start • Store it even if you can't process it (yet) • Start simple – S3 + Redshift • Add data sources – process with EMR • Real-time – Kinesis + Spark • Tons of untapped potential for gaming
  • 53.
    AWS Gaming Solutions | GDC 2014 Fallback Plan Cheers – Nate Wiger @nateware

AltStyle によって変換されたページ (->オリジナル) /