un backend: pour tous vos objets connectés

61
Un backend pour tous vos objets connectés Michael Garcia Architecte Solutions [email protected] @aws_actus

Upload: amazon-web-services

Post on 18-Jul-2015

213 views

Category:

Technology


3 download

TRANSCRIPT

Page 1: Un backend: pour tous vos objets connectés

Un backend pour tous vos objets

connectésMichael Garcia – Architecte Solutions –

[email protected]

@aws_actus

Page 2: Un backend: pour tous vos objets connectés

Source: reservoir.jobs / festivalmawazine

Page 3: Un backend: pour tous vos objets connectés

Source: tlciscreatice.com / activate.com

Page 4: Un backend: pour tous vos objets connectés

Source: engagor.com

Page 5: Un backend: pour tous vos objets connectés

We asked two questions to our mobile customers:

What makes your mobile apps unique?

Where are you spending most of your time?

Page 6: Un backend: pour tous vos objets connectés

We asked two questions to our mobile customers:

What makes your mobile apps unique?

Where are you spending most of your time?

Page 7: Un backend: pour tous vos objets connectés

How to build a mobile app today?

Page 8: Un backend: pour tous vos objets connectés

Your

Mobile

App

Page 9: Un backend: pour tous vos objets connectés

Your

Mobile

App

AWS Mobile SDK

Page 10: Un backend: pour tous vos objets connectés

Your

Mobile

App

Authenticate users

Amazon Cognito

(Identity Broker)

AWS Mobile SDK

Page 11: Un backend: pour tous vos objets connectés

Your

Mobile

App

Authenticate users

Synchronize dataAmazon Cognito

(Sync)

Amazon Cognito

(Identity Broker)

AWS Mobile SDK

Page 12: Un backend: pour tous vos objets connectés

Your

Mobile

App

Authenticate users

Analyze User Behavior

Synchronize data

Amazon Mobile

Analytics

Amazon Cognito

(Sync)

Amazon Cognito

(Identity Broker)

AWS Mobile SDK

Page 13: Un backend: pour tous vos objets connectés

Your

Mobile

App

Authenticate users

Analyze User Behavior

Synchronize data

Amazon Mobile

Analytics

Amazon Cognito

(Sync)

Amazon Cognito

(Identity Broker)

AWS Mobile SDK

Send push notificationsAmazon SNS

Mobile Push

Page 14: Un backend: pour tous vos objets connectés

Your

Mobile

App

Authenticate users

Authorize access

Analyze User Behavior

Synchronize data

Amazon Mobile

Analytics

Amazon Cognito

(Sync)

Amazon Cognito

(Identity Broker)

AWS Identity and

Access Management

Store shared dataAmazon DynamoDB

(Object Mapper)

Store and share media

Deliver media

Amazon S3

Transfer Manager

Amazon CloudFront

(Device Detection)

Event driven compute

AWS Lambda

AWS Mobile SDK

Send push notificationsAmazon SNS

Mobile Push

Page 15: Un backend: pour tous vos objets connectés

Improve mobile apps retention with

Amazon Simple Notification Service

Emmanuel Lemoine

CTO & Founder @ Pretty Fun Therapy

Page 16: Un backend: pour tous vos objets connectés

Pretty Fun Therapy

• We do ”Mobile Social Discovery”

– To bring people together through casual apps

– Because meeting people should be fun

Page 17: Un backend: pour tous vos objets connectés

Playme!Dating + Gaming

• Release: May 15, 2014

• Platform: iOS and Android

• Audience: 6k DAU

Filter Browse Play Engage

Page 18: Un backend: pour tous vos objets connectés

What is Amazon Simple Notification Service?

• Notification service (HTTP/S, Email, SQS, Mobile Push)

• Cross platform for Mobile Push

– Android / iOS / Windows / Baidu / FireOS

• Cross platform “Native Push“ handler

Page 19: Un backend: pour tous vos objets connectés

Why do we use it?

• “Social app” means “users engagement”

Without SNS:

Hey, how

are you?

DynamoDB

Page 20: Un backend: pour tous vos objets connectés

Why do we use it?

• “Social app” means “users engagement”

With SNS:

Hey, how

are you?

DynamoDB SNS

Fine, what

about u?

Rentention boosterUX enhancer

Page 21: Un backend: pour tous vos objets connectés

What does SNS do for us?

• PFT uses SNS for Native Push purpose

• SNS acts as an intermediate between our App and providers’ Native

Push System (Only one integration to build)

• SNS is also like a database of our users’ device identifier

Cross platform devices

Register

SNS

UserId: 1DeviceToken: ecaffa86334b6885359… Platform: APNS

UserId: 2DeviceToken: APA91bHpUYDrDRlNA… Platform: GCM

UserId: 1DeviceToken: addcea86334b6885359… Platform: APNS

Page 22: Un backend: pour tous vos objets connectés

What does SNS do for us?

• PFT uses SNS for Native Push purpose

• SNS acts as an intermediate between our App and providers’ Native

Push System (Only one integration to build)

• SNS is also like a database of our users’ device identifier

"SNS rocks!"

Android?

iOS?

GCM

APNS

Page 23: Un backend: pour tous vos objets connectés

Multiple platforms,one syntax :

@sns.pulish(params)

Page 24: Un backend: pour tous vos objets connectés

MyCrazyTopic Android subscribers

SNS Topics

• Call once, deliver to thousands

@sns.pulish(topic_arn: ‘MyCrazyTopic’)

GCM APNS

MyCrazyTopic iOS subscribers

Page 25: Un backend: pour tous vos objets connectés

Pricing ?

Amazon SNS

Mobile Push

Free Tier:1 Million push messages every month15 GB for all free tier services

Page 26: Un backend: pour tous vos objets connectés

What did we gain using SNS ?

Low Cost +20% day 1 user retentionBuilding the app fasterwith less maintenance

Page 27: Un backend: pour tous vos objets connectés

Your

Mobile

App

Authenticate users

Analyze User Behavior

Synchronize data

Amazon Mobile

Analytics

Amazon Cognito

(Sync)

Amazon Cognito

(Identity Broker)

AWS Mobile SDK

Send push notificationsAmazon SNS

Mobile Push

Page 28: Un backend: pour tous vos objets connectés

Amazon Cognito Authentication

Page 29: Un backend: pour tous vos objets connectés

Amazon Cognito

Cross-device and

Cross-platform Sync

Securely access all

AWS services from Mobile device

Simplifies Identity and

Access ManagementImplement security best

practices

“Your App data is secure, available offline, and kept in sync between devices”

Synchronize user’s data

across devices and

platforms

Manage users as

unique identities across

identity providers

Guest Your own Auth

Page 30: Un backend: pour tous vos objets connectés

Amazon Cognito Security

EC2 S3 DynamoDB Kinesis

Page 31: Un backend: pour tous vos objets connectés

Amazon Cognito Security Architecture

End Users

App with

AWS Mobile

SDK

Access

to AWS

Services

Login OAUTH/OpenID

Access Token

Cognito ID,

Temp

Credentials

Access

Token

Pool ID

Role ARNs

Cognito ID

(Temp

Credentials)

DynamoDB

Cognito Identity

Broker

S3

Mobile Analytics

Cognito Sync

Store

Page 32: Un backend: pour tous vos objets connectés

Identity

Providers

Unique

IdentitiesJoe Anna Bob

Any Device

Any Platform

Amazon Cognito Identity

Page 33: Un backend: pour tous vos objets connectés

Amazon Cognito for Unauthenticated Identities

Visitor

Preferences

Cognito

Store

Guest

S3 DynamoDB Kinesis

Page 34: Un backend: pour tous vos objets connectés

Users begin their life as guests

Amazon Cognito for Unauthenticated Identities

Page 35: Un backend: pour tous vos objets connectés

Later on they register an account

• The transition should be seamless

Amazon Cognito for Unauthenticated Identities

Page 36: Un backend: pour tous vos objets connectés

Multiple accounts can be linked

• You should have a consistent identifier

Amazon Cognito for Unauthenticated Identities

Page 37: Un backend: pour tous vos objets connectés

Amazon Cognito Sync

Page 38: Un backend: pour tous vos objets connectés

Amazon Cognito Sync

Page 39: Un backend: pour tous vos objets connectés

Amazon Cognito Sync

Page 40: Un backend: pour tous vos objets connectés

Amazon Cognito Sync

AWS SDK

Local SQLite Cache

iOS/Android/FireOS/any platform

(AWS SDK)

Page 41: Un backend: pour tous vos objets connectés

Concrete Software builds cross platform mobile games

With Amazon Cognito, We

can build games much faster

and provide great user

experience to our customers.

Keith A. Pichelman

CEO, Concrete Software

“• Provide a seamless user experience across devices

and platforms to our users.

• Store save games in the cloud and synchronize them

across all of a user’s devices without creating or

hosting a backend.

The Challenge

The solution

• Amazon Cognito helps us securely access our AWS

resources.

• Cognito Sync gives us flexibility to save data in the

cloud, and cache it on a user’s devices, without

managing any backend infrastructure.

Page 42: Un backend: pour tous vos objets connectés

Integrating Cognito Sync functionality is fast

Initialize the CredentialsProvider and CognitoClient

Call synchronize on the dataset

Create or open Dataset and Add Key Values

provider = new CognitoCachingCredentialsProvider (context, AWS_ACCOUNT_ID,

COGNITO_POOL_ID, COGNTIO_ROLE_UNAUTH, COGNITO_ROLE_AUTH, Regions.US_EAST_1);

cognito = new CognitoSyncManager (context, Regions.US_EAST_1, provider);

dataset.synchronize(new SyncCallback(){..});

cognito.openOrCreateDataset(datasetName);

dataset.put(key, value);

Page 43: Un backend: pour tous vos objets connectés

Integrating Cognito Sync functionality is fast

Initialize the AWSCognitoSyncClient

Call synchronize on the dataset

Create or open Dataset and Add Key Values

DataSet *dataset = [syncClient openOrCreateDataSet:@"myDataSet"];

NSString *value = [dataset readStringForKey:@"myKey"];

[dataset putString:@"my value" forKey:@"myKey"];

AWSCognitoSyncClient *syncClient = [[AWSCognitoSyncClient alloc]

initWithConfiguration: configuration];

[dataset synchronize];

iOS

Page 44: Un backend: pour tous vos objets connectés

Analyze User Behavior: Amazon Mobile Analytics

Page 45: Un backend: pour tous vos objets connectés

What Customers Told Us About “Mobile Analytics”

Developers deeply value user analytics and consider it an integral part of

their app development process. They want to monitor their most

important metrics in a timely manner, and take action quickly. They would

like to own their mobile data, just like they do with any other AWS

service.

Page 46: Un backend: pour tous vos objets connectés

Amazon Mobile Analytics

Scalable and Generous

Free Tier

Focus on metrics that matter. Usage reports

available within 60 minutes of receiving data from an

app

Fast

Scale to billions of events per day from millions of

users.

Own Your Data

“Easily collect, visualize and understand your app usage data at scale”

Data collected are not shared, aggregated, or

reused

Page 47: Un backend: pour tous vos objets connectés

Specific metrics related to your app and your business

Track the number of Likes/Shares, per article, in a news app

Understand player abort rates per level, in a game

Number of songs played, per user session, in a music app

In-app item popularity in a shopping app

Track Custom Events

Active users / Sessions / Revenue / Retention

Track Behavior Events

Page 48: Un backend: pour tous vos objets connectés

Integrating Mobile Analytics is fast

Initialize the MobileAnalyticsManager. That’s it! Get Session

Activity in the AWS Management Console.

For Custom Events activity reports, add events.

Add OnResume() and OnPause()

private static MobileAnalyticsManager analytics;

analytics = MobileAnalyticsManager.getOrCreateInstance(

this.getApplicationContext(),"yourCompany.yourAppId",

Regions.YOUR_REGION, config, cognitoProvider );

EventClient eventClient = analytics.getEventClient();

MobileAnalyticsEvent visitEvent = eventClient.createEvent("speedSet");

eventClient.recordEvent(visitEvent);

analytics.getSessionClient().resumeSession();

analytics.getSessionClient().pauseSession();

Analytics.getEventClient().submitEvents();

Page 49: Un backend: pour tous vos objets connectés

Integrating Mobile Analytics is fast

Initialize the AWSMobileAnalytics object. That’s it! Get Session

Activity in the AWS Management Console.

Submit the event. If we don't call submitEvents, events

will automatically be submitted at periodic intervals.

Create add Custom Events

[eventClient submitEvents];

id<AWSMobileAnalyticsEventClient> eventClient =

analytics.eventClient;

id<AWSMobileAnalyticsEvent> level1Event = [eventClient

createEventWithEventType:@"level1Complete"];

AWSMobileAnalytics* analytics = [AWSMobileAnalytics

defaultAWSMobileAnalyticsWithIdentifier:@"someuniqueid"];

iOS

Page 50: Un backend: pour tous vos objets connectés

Demo: Amazon Mobile Analytics

Page 51: Un backend: pour tous vos objets connectés

Beyond mobile analytics

mobile client Amazon S3 Amazon RedshiftAmazon Mobile Analytics

Analytic tool

Page 52: Un backend: pour tous vos objets connectés
Page 53: Un backend: pour tous vos objets connectés

53

FORZA FOOTBALLSINCE 2012

Page 54: Un backend: pour tous vos objets connectés

BY TABLEAU

VISUALIZATIONS

Page 55: Un backend: pour tous vos objets connectés

PENETRATIONUSERS PER COUNTRY

55

Page 56: Un backend: pour tous vos objets connectés

LEVERAGE ON MISSIONVOTE PER COUNTRY

56

Page 57: Un backend: pour tous vos objets connectés

DEVICESIN FORZA FOOTBALL

57

Page 58: Un backend: pour tous vos objets connectés

Amazon Cognito Amazon Mobile

Analytics

Amazon SNS

Mobile Push

Free Tier:1 Million push messages every month

Free Tier:1 Million syncs/month + 10GB of storage for Amazon Cognito

Free Tier:100 Million events every month

Get Started for Free!

http://aws.amazon.com/mobile

Page 59: Un backend: pour tous vos objets connectés

AWS Mobile

SDK

Your

Mobile

App

serverlessbackend

Page 60: Un backend: pour tous vos objets connectés

Thank you !!

@aws_actus

Page 61: Un backend: pour tous vos objets connectés

Inscrivez-vous gratuitement à l’adresse :

aws.amazon.com/summits/paris