(arc306) iot: small things and the cloud | aws re:invent 2014

59
© 2014 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified, or distributed in whole or in part without the express consent of Amazon.com, Inc. ARC 306 IoT: Small Things and the Cloud Brett Francis, Solutions Architecture November 12, 2014 | Las Vegas, NV

Upload: amazon-web-services

Post on 02-Jul-2015

2.339 views

Category:

Technology


1 download

DESCRIPTION

Working with fleets of ''Internet of Things'' (IoT) devices brings about distinct challenges. In this session, we will explore four of these challenges: telemetry, commands, device devops, and audit and authorization, and how they transform when deploying hundreds-of-thousands of resource-constrained devices. We'll explore high-level architectural patterns that customers use to meet these challenges through the functionality and ubiquity of a globally accessible cloud platform. If you consider yourself a device developer, an electrical, industrial, or hardware engineer, a hardware incubator class member, a new device manufacturer, an existing device manufacturer who wants to smarten up their next-gen devices, or a software developer working with people who identify as part of these tribes, you'll want to participate in this session.

TRANSCRIPT

Page 1: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

© 2014 Amazon.com, Inc. and its affiliates. All rights reserved. May not be copied, modified, or distributed in whole or in part without the express consent of Amazon.com, Inc.

ARC 306

IoT: Small Things and the Cloud

Brett Francis, Solutions Architecture

November 12, 2014 | Las Vegas, NV

Page 2: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

What is a Small Thing?

Page 3: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

What is a Small Thing?Why

Page 4: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Small Things maximize

a resource by using it

as little as possible.

Page 5: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Define: Resource constrained computing thing

• Devices constrained in at least one

computing dimension

• Regularly deployed at counts in the

thousands or more

• May play critical roles without human

interaction

Page 6: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT and Small Thing comparisons

Not a Small Thing A Small Thing

Page 7: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT and Small Thing comparisons

Not a Small Thing A Small Thing

Page 8: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT and Small Thing comparisons

Not a Small Thing A Small Thing

Page 9: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT and Small Thing comparisons

Not a Small Thing A Small Thing

Page 10: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT and Small Thing comparisons

Not a Small Thing A Small Thing

Page 11: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

A Small Thing is connected but

inherently limited in some way.

Page 12: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Almost everywhere a

Small Thing has a gap…

Page 13: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

…a globally accessible cloud

platform helps fill the gaps.

Page 14: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

The smaller the device is,

the bigger the data

…and the newer the challenges.

Page 15: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Let’s explore…

Page 16: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Gap

Gap Gap

Gap

Gap Gap

Filling in some gaps

Small

Thing

Page 17: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

First challenge: telemetry

Page 18: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Telemetry today

Remotely determine what a device

senses.

Page 19: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Telemetry misconception

“Just gather the sensor data and

send it in for use.”

Page 20: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

AWS Cloud

Archive

Correlation

Analysis

Just gather the sensor data and send it in for use.

Mobile

DeviceVarious

Sensors

HTTPS

Small

Thing

Basic telemetry + cloud architecture

Persistent

Stream

Page 21: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

ThingSmall

Thing

Small

Thing

Small

ThingSmall

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

ThingSmall

Thing

Small

Thing

Small

ThingSmall

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

ThingSmall

Thing

Small

Thing

Small

ThingSmall

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

ThingSmall

Thing

Small

Thing

Small

ThingSmall

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

Thing

Small

Thing

Small

Thing

Small

Thing

Small

Thing Small

Thing

Small

Thing

Small

Thing

Small

ThingSmall

ThingSmall

Thing

Small

Thing

Small

ThingSmall

Thing

Small

ThingSmall

Thing

Success looks like

thousands or millions

Page 22: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Real world telemetry challenges

Hundreds of thousands of devices need:

• Strategies for intermittent connectivity

• To send sensor data reliably

• Elastic solutions to wave crests and troughs

Page 23: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Intermittent connectivity means…

Logging algorithms matter

Page 24: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

FIFO, aggregate, and culling algorithms

1min 1min1min 5min 5min

ON

AGG

1min 1min 1min1min 1min

ON OFF

1min 1min 1min1min 1min

ON

OF

F

OF

F

FIFO

Aggregate

Culling

Cull Point

Agg Point

Page 25: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

When networking, compute, or power is low…

A machine-to-machine proxy layer may

help

Page 26: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Logger

Trickles become a stream

AWS Cloud

Stream

Small Thing

Mobile DeviceVarious

Sensors

Auto Scaling Group

M2M Brokers

Device

Config

M2M BrokerFleet Keeper

M2M Config Broker

aka. evolved telemetry + cloud architecture

Archive

Correlation

Analysis

Page 27: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Streams flow into a riveraka Global Telemetry Architecture

Stream

Centralized Region

Amazon

Kinesis–

Enabled

App

Logger

Stream

Small Thing

Mobile Devices

Various Sensors Region

Amazon SQS

Complaint Queue

Logger

Stream

Small Thing

Mobile Devices

Various Sensors Region

Archive

Correlation

Analysis

Device

Config

Device

Config

Master Device

Config

M2M BrokerScaling Group

Page 28: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Rivers of data become Big Data

Copyright © 2014

My Photo Dump.

Page 29: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Gap Gap

Small thing telemetry — AWS helps

Global Ubiquity

$0 Inbound Data

Small

Thing

Elasticity

Purpose Built Services

Amazon

DynamoDB

Amazon

Kinesis

Amazon

SQS

Auto

Scaling

Page 30: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Next challenge: commands

Page 31: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Commands today

Ask a device to do something.

Page 32: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Commands misconception

“Just tell those devices to do

something.”

Page 33: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

(2) Get Command(s)

(1) Get Config

Basic commands + cloud architecture

AWS Cloud

Just tell those devices to do something.

Mobile Devices

Web App

Device

Config

Small Thing

Configured

Command

Source

Device

Commands

M2M Endpoints

Users

HTTPS orM2M Protocol

(B) User Commands

(A) Configured

Device Pair

…or…

Various Sensors

Page 34: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Real world Command challenges

Sending the correct commands matter

Hundreds of thousands of devices need:

• Delivery of authoritative commands

• Minimal-connection delivery

• Important commands to be transactional

Page 35: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Evolved command connections

Single High-Heat NoSQL Database Meet-Me M2M Broker Endpoint Pools

(3) Write Command SUCCESS

Device

Commands

(2) Read Command(s) from Table

(1) Get Config

Device

Config

Small Thing

Configured

Command

Source

Device

Commands

(3) Write Command SUCCESS

(2) Read Command(s) from Topic

(1) Get Config

Device

Config

Small Thing

Configured

Command

Source

Meet-Me M2M Endpoints

Meet-Me M2M Endpoints

Just tell those devices to do something.

Page 36: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Evolved commands + cloud architecture

(3) Write Command SUCCESS

Device

Commands

(2) Read Command(s) from Table

(1) Get Config

Device

Config

Small Thing

Configured

Command

Source

Device

Commands

Just tell those devices to do something.

Mobile Devices

Web App

(C) User Commands

(B) Get Configured

Device Pair

Amazon

Cognito

Authorization

(A) Mobile User

Authorization

Users

Page 37: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Gap Gap

Commands — AWS helps

Global Ubiquity

$0 Inbound Data

Small

Thing

Elasticity

Purpose Built Services

Amazon

DynamoDB

Amazon

CognitoAuto

Scaling

Page 38: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Next challenge: Device DevOps

Page 39: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Device DevOps today

Ask a device to be something new.

Page 40: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Device DevOps misconception

“Just send out firmware updates

when needed.”

Page 41: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Basic DevOps + cloud architecture

Just send out firmware updates when needed.

(2) Get Firmware Bundle(s)

(1) Get Command

AWS Cloud

Device

Commands

Small Thing

Get

Firmware

Bundle

Bundle Download

Device Specific

BundleVarious Sensors

Page 42: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Real world Device DevOps challenges

If you kill it, it is dead

Hundreds of thousands of devices need help with:

• Intelligent exception management

• Staged, validated, and rolling updates

Page 43: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Evolved DevOps + cloud architecture

(2) Get Firmware Bundle(s)

(1) Get Config

AWS Cloud

Device

Commands

Small Thing

Configured

Firmware

Bundle

Bundle Download

Device Specific

Bundle

(3) Send Firmware SUCCESS

Device

Commands

Various Sensors

Just send out firmware updates when needed.

Page 44: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Evolved Device DevOps process arch

(2) Get Firmware Bundle(s)

(1) Get Command

Device

Commands

Small Thing

Device Specific

Bundle

(3) Send Firmware SUCCESS

Device

Commands

Small Thing

All Success?

(2) Get Firmware Bundle(s)

(1) Get Command

Device

Commands

Device Specific

Bundle

(3) Send Firmware SUCCESS

Device

Commands

StagingProduction

LoggerSmall Thing

LoggerSmall Thing

(B) Copy Bundle

(C) Update Commands

Various Sensors

Just send out firmware updates when needed.

(A) Validate Bundle

All Success?

(D) Manage Exceptions

Page 45: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Gap

Device DevOps — AWS helps

Global Ubiquity

$0 Inbound Data

Small

Thing

Elasticity

Purpose Built Services

Amazon

DynamoDB

Amazon

S3

Global

Object

Store

Page 46: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Last challenge: audit & authorization

Page 47: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Audit & authorization today

Determine if a device should be

allowed to do something.

Page 48: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Audit & authorization misconception

“Just allow the right devices to do

something.”

Page 49: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Basic audit & authorization + cloud arch

(2) Authenticate and Authorize

AWS Cloud

Small Thing

(3) Register

Device

Registration

(4) Proceed with Privilege

Device

Config

(1) Install Creds

Just allow the right devices to do something.

Page 50: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

IoT : [ Telemetry ][ Commands ][ Device DevOps ][ Audit & Authorization ]

Real world audit and authorization challenges

Hundreds of thousands of devices need:

• Intelligent exception management

• Resource constrained authorization

• Device authorization and renewal

Page 51: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

(1) Get Cognito ID

Evolved Audit & Authorization + Cloud Arch

AWS Cloud

Just allow the right devices to do something.

Small Thing

Cognito

AuthorizationCognito ID

(2) Unauthenticated Register

Device

Registration

(3) Authorize Device

Device

Registration

Web AppUsers & Admins

Page 52: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Audit & authorization — AWS helps

Global Ubiquity

$0 Inbound Data

Small

Thing

Elasticity

Purpose Built Services

Global

Object

Store

Audit

&

AZNAmazon

CognitoDynamoDB

Page 53: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Small Things — AWS helps

Global Ubiquity

$0 Inbound Data

Small

Thing

Elasticity

Purpose Built Services

Global

Object

Store

Audit

&

AZN Amazon

S3

Amazon

CognitoAmazon

DynamoDB

Amazon

Kinesis

Amazon

SQS

Auto

Scaling

Page 54: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

A Small Thing solution architecture

Page 55: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Pragma architecture(“Pragma” is Greek for “thing”)

Small

Thing

Serving LayerIntermittent Layer

Speed Layer

Telemetry

Commands

Device DevOps

Audit & Authorization

Web Apps

Page 56: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

How do I get started?

• Open an AWS account

– https://portal.aws.amazon.com/gp/aws/developer/registration/index.html

• Explore the AWS IoT mini-site

– http://aws.amazon.com/iot/

• Explore Amazon Cognito: http://aws.amazon.com/cognito/

• Explore Amazon Kinesis: http://aws.amazon.com/kinesis/

• Explore DynamoDB: http://aws.amazon.com/dynamodb/

• After re:Invent, download this deck

Page 57: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

http://bit.ly/awsevals

Serving LayerIntermittent Layer

Speed Layer

Telemetry

Commands

Device DevOps

Audit & AZNSmall

Thing

Pragma Architecture(“Pragma” is Greek for “thing”)

[email protected]

Thank You

Page 58: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Appendix

Page 59: (ARC306) IoT: Small Things and the Cloud | AWS re:Invent 2014

Pragma architecture characteristics

• The intermittent layer is the control point for access to the

speed layer.

• The intermittent layer acts as the nexus of fleet management,

supports high-heat data interactions.

• The speed layer acts as the inbound high-bandwidth data bus

and the outbound command bus.

• The serving layer enables applications to interact with archive,

analysis, correlation, and real-time views of the device fleet.

• The serving layer enables the intermittent layer to distribute

and control updates.