why http won't work for the internet of things (dreamforce 2014)

25
Why HTTP Won’t Work For IoT Tim Kellogg Principal Software Engineer @kellogh

Upload: kellogh

Post on 24-Jun-2015

568 views

Category:

Engineering


1 download

DESCRIPTION

The Internet of Things has offers compounding value but also compounding problems on top of what we get for either the Internet or embedded technology. While HTTP made the Web successful, the challenges experienced by the IoT are different and require different solutions.

TRANSCRIPT

Page 1: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Why HTTP Won’t Work For IoTTim Kellogg

Principal Software Engineer

@kellogh

Page 2: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

About Me

Backend Cloud Services

Simple Designs

Abstractions Are Good

Page 3: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Internet of Things

Embedded Internet IoT

Page 4: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Internet of Things

Constrained environments• Constrained memory footprint MCUs• Embedded Linux• No OS

Unreliable network connectivity

Page 5: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Constrained devices

Page 6: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Telemetry

Device to server

Sensor readings

Big data & analytics

Page 7: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Telemetry

BrokerPublishCloud

ConnectorsSubscribe

Salesforce1Platform

Subscribe

Devices

Sensors

Page 8: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

HTTPFor request / response

Page 9: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

HTTP

Client ServerRequest

Response

Page 10: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

HTTP

Consumer must be available at all times

Publisher needs to know the exact destination

Publisher depends on the response status

Page 11: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

MQTT

Broker must be available at all times• Doesn’t do any processing, failure is uncommon

Publisher and subscriber are decoupled• Publisher publishes at it’s leisure• Subscriber processes messages at it’s leisure

Publisher does not care who (if anyone) it’s publishing to

Publisher doesn’t care about the result of processing

Page 12: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Quality of Service (QoS)

0 – fire and forget

1 – Guaranteed delivery at least once

2 – Guaranteed delivery exactly once• Can be easily implemented client-side by

using QoS 1 to increase throughput

Page 13: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Topics

Hierarchical• a/b/c• com.example/sensors/sen546/temp• CTL/com.example/sensors/sen546

“+” matches single level• com.example/sensors/+/temp• +/sensors/sen546

“#” matches many level, must be at end• com.example/sensors/#• CTL/com.example/#

Page 14: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

MQTT Features

Last will and testament• Unexpected disconnects

Retained messages• Infrequently published values

Page 15: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

MQTT-SN

MQTT for Sensor Networks

UDP + 6LoWPAN

Gateway

Configuration-free discovery

Page 16: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

MQTT-SN

Gateway

Broker

Page 17: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

CoAPA lighter version of HTTP with some extra bells and whistles

Page 18: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Constrained Application Protocol

REST

HTTP mappings for proxy servers

Very lightweight messages

UDP + 6LoWPAN

Confirmable messages

Page 19: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Additional response messages sent whenever the resource changes

No polling

GET+Observe

Page 20: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Resources

IoT Zone

MQTT & CoAP• http://iot.eclipse.org/ • https://app.thingfabric.com/

Hardware• http://www.kelloggsresearchlabs.com/PressRele

aseGenerator

Page 21: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

@kellogh

Page 22: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

APPENDIX

CONFIDENTIAL - 2lemetry, LLC

Page 23: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

We power the connected enterprise

• 2lemetry is an IoT technology and solutions company that powers the connected enterprise, tying people, processes, data and devices together—transforming raw data into real-time actionable intelligence.

• Founded 2011—spun off from hardware manufacturer

• 100% Focus on Internet of Things—with a “cloud first” focus

Page 24: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

Technology - ThingFabric

Broker Layer

Data Storage

CEP EngineRules Engine

REST API

Regional Load Balancing

• Historical data storage• Automation replication• Schemaless

• Find trends• Run computations• Build complex models

• HTTP webhook• Republish rules• SMS/Email• Reformat payloads

• Supports custom protocols• Supports MQTT, Stomp, CoAP• Balanced by geographical response time

Page 25: Why HTTP Won't Work For The Internet of Things (Dreamforce 2014)

2lemetry technology, solutions, partners and expertise to provide an end to end solution

Technology2lemetry Device Cloud Platform

SolutionsEnterprise system integration tools

Digital signage

Proximity sensing

Facial recognition

PartnersAcross entire IoT project lifecycle

Sales channel

ExpertiseIoT strategy

Integration expertise and application development

Managed service and support

CONFIDENTIAL - 2lemetry, LLC