SlideShare a Scribd company logo
Template designed by
IoT & Azure
Mirco Vanini
mirco.vanini@adamfactory.com
http://mircovanini.blogspot.it/
Slide con sponsor che arriva a
qualche giorno dalla conferenza
sponsor
adam | factory
analisi, progettazione, consulenza, alm, formazione
Microsoft MVP for Windows Embedded
XeDotNet
TinyCLR.it
@MircoVanini
http://it.linkedin.com/in/proxsoft
http://mvp.microsoft.com/it-it/MVP/Mirco%20Vanini-4039714
chi sono
Microsoft Azure IoT Services
Azure Service Bus
Azure Event Hubs
Azure Stream Analitycs
Demo
Recap
agenda
microsoft azure IoT services
Producers Connect Devices Storage Analytics Take Action
Event Hubs SQL Database
Machine
Learning
Azure Websites
Service Bus
Table/Blob
Storage
Stream
Analytics
Power BI
External Data
Sources
DocumentDB HDInsight
Notification
Hubs
External Data
Sources
Data Factory Mobile Services
BizTalk Services
{ }
Microsoft Azure IoT Services
Azure Service Bus
Relay
Queue
Topic
Notification Hub
Event Hub
NAT and Firewall Traversal Service
Request/Response Services
Unbuffered with TCP Throttling
Transactional Cloud AMQP/HTTP Broker
High-Scale, High-Reliability Messaging
Sessions, Scheduled Delivery, etc.
Transactional Message Distribution
Up to 2000 subscriptions per Topic
Up to 2K/100K filter rules per subscription
High-scale notification distribution
Most mobile push notification services
Millions of notification targets
…
intelligent mobility and connected car
telemetry ... the problem
Information flowing from a device to other systems for
conveying status of device and environment
Unidirectional
Data frequency can be different based on
applications/conditions
service bus - queus & topics
Message are durably stored but with TTL
Receive & Delete or Peek Lock
Sessions (for FIFO feature)
Request/Reply pattern (based on correlation)
Transaction for batch send/receive
Dead-letter queue (TTL or “poisoned” messages)
introducing azure event hubs
Event
Producers
> 1M Producers
> 1GB/sec
Aggregate
Throughput
Direct
PartitionKey
Hash
Receivers
AMQP 1.0
Credit-based flow control
Client-side cursors
Offset by Id or Timestamp
Throughput Units:
• 1 ≤ TUs ≤ Partition Count
• TU: 1 MB/s writes, 2 MB/s
reads
event hubs - overview
Event Hubs is a highly scalable ingestion system that can process
millions of events per second, enabling your application to
process and analyze the massive amounts of data produced by
your connected devices and applications.
The Azure Event Hubs capability differs from Service Bus topics
in that it is strongly biased towards high throughput and event
processing scenarios.
event hubs - overview
An Event Hub is created at the namespace level in Service
Bus, similar to queues and topics. Event Hubs uses AMQP
and HTTP as its primary API interfaces.
event hubs - partitions
Event Hubs provides message streaming through a partitioned
consumer pattern.
A partition is an ordered sequence of events that is held in an
Event Hub. As newer events arrive, they are added to the end of
this sequence. A partition can be thought of as a “commit log.”
The number of partitions is specified at the Event Hub creation
time and must be between 8 and 32.
Segmentation of event stream for scale-out.
event hubs - event data
In the Event Hubs context, messages are referred to as event data.
Event data contains the body of the event, a user defined property
bag, and various metadata about the event such as its offset in the
partition and its number in the stream sequence. Partitions are filled
with a sequence of event data (max 256kb).
You can publish an event via AMQP 1.0 or HTTP. Service Bus provides
an EventHubClient class that you can use for publishing events to an
Event Hub from .NET clients. For other runtimes and platforms, you
can use any AMQP 1.0 client such as Apache Qpid.
event hubs - what is AMQP 1.0?
Advanced Message Queuing Protocol (AMQP) is an efficient,
reliable, wire-level messaging protocol (OASIS standard) that
you can use to build robust, cross-platform, messaging
applications. The protocol has a simple goal: to define the
mechanics of the secure, reliable, and efficient transfer of
messages between two parties.
event hubs - AMQP or HTTP ?
The choice to use AMQP or HTTP is specific to the usage
scenario. AMQP requires the establishment of a persistent
bidirectional socket in addition to transport level security (TLS)
or SSL/TLS. This can be a costly operation in terms of network
traffic, but only happens at the beginning of an AMQP session.
HTTP has a lower initial overhead, but requires additional SSL
overhead for every request. For publishers who frequently
publish events, AMQP offers significant performance, latency,
and throughput savings
event hubs - partition key
A partition key is a value that is used to map incoming event data into
specific partitions for the purposes of data organization. The partition key
is a sender-supplied value passed into an Event Hub. It is processed
through a static hashing function, the result of which creates the partition
assignment.
Event Hubs ensures that any and all events sharing the same partition key
value are delivered in order, and to the same partition.
event hubs - consumer groups
The publish/subscribe mechanism of Event Hubs is enabled
through consumer groups. A consumer group is a view (state,
position, or offset) of an entire Event Hub. Consumer groups
enable multiple consuming applications to each have a separate
view of the event stream, and to read the stream independently
at its own pace and with its own offsets.
event hubs - stream offset
An offset is the position of an event within a partition. You can
think of an offset as a client-side cursor. The offset is a byte
numbering of the event. This enables an event consumer
(reader) to specify a point in the event stream from which they
want to begin reading events. You can specify the offset as a
timestamp or as an offset value.
event hubs - reading events
In order to consume events from an Event Hub, a consumer
must connect to a partition. Only a single reader should be
active on a partition at any one time within a consumer group.
Each event data instance contains important metadata such as
the offset and sequence number that are used to facilitate
checkpointing on the event sequence.
event hubs - throughput units
The throughput capacity of Event Hubs is controlled by throughput units. Throughput units
are pre-purchased units of capacity. A single throughput unit includes the following:
Write: Up to 1MB per second or 1000 events per second.
Read: Up to 2MB per second.
Included retention: 84GByte/day (24h at full ingress rate)
Sending data above this amount results in a quota exceeded exception !
Throughput units are billed per hour and are purchased ahead of time
Up to 20 throughput units can be purchased for a Service Bus namespace
event hubs vs queues & topics
Patterns
Q&T : useful for Command Message and Request/Replay Message (response queue)
EH : useful for Event Messages
Cursor
Q&T : on server side. Message consumed and deleted from queue, cursor to next available
message
EH : on client side. Client can rewind on the stream and re-read same events (during their
retention). Access partition by offset or timestamp
Retention
Q&T : TTL at queue/topic level or message level
EH : max 7 days
event hubs vs queues & topics
Security & Authentication
Q&T and EH
• SSL/TLS via HTTP(S) or AMQP(S)
• SAS (Secure Access Signature) for sending/receiving
EH
• Publisher policy (SAS Token)
• Fine grained per device
• Revoke/Restore publisher
Other
EH doesn't have dead lettering, transaction, ... to have higher throughput
stream analitycs - overview
Real-time business insights
Stream Analytics is an event processing engine that helps uncover real-time insights from
devices, sensors, infrastructure, applications and data.
Stream millions of events per second
Stream Analytics provides out-of-the-box integration with Event Hubs to ingest millions of
events per second. Together, Event Hubs and Stream Analytics let you process massive
amounts of real-time data so you can make business decisions in real-time.
Real-time processing
Stream Analytics will process ingested events in real-time, comparing multiple real-time
streams or comparing real-time streams together with historical values and models
event hubs - connect the things
Intel Galileo
Intel® Quark™ X1000
Win32 / C++
Qpid Proton - Apache
Library
GHI Fez Spider
72 Mhz 32-bit ARM7
.NET MF & Gadgeteer / C#
Amqp.Net Lite
Toradex Colibri T30
NVIDIA® Tegra™ 3
.NET CF / WEC2013 / C#
Amqp.Net Lite
http://qpid.apache.org/proton/
https://amqpnetlite.codeplex.com/
demo
connect things to azure
event hub
event hubs - pricing
BASIC Standard
Ingress events €0.0209 per million events €0.0209 per million events
Throughput unit (1 MB/s ingress,
2MB/s egress)
€0.0112/hr (~€9/mo) €0.0224/hr (~€17/mo)
Publisher policies √
Consumer groups 1 - Default 20
Maximum throughput units 20 20
Service Bus brokered connections 100 included 1000 included
Additional Service Bus brokered
connections
√
Message Retention 1 day included 1 day included
Additional storage (up to 7 days) √
http://azure.microsoft.com/en-us/pricing/details/event-hubs/
recap
Stream millions of events per second into multiple applications
Enable applications to process events with variable load profiles
Connect millions of devices across platforms
Available NOW !
Grazie a tutti per la partecipazione
Riceverete il link per il download a slide e demo via email nei
prossimi giorni
Per contattarmi
mirco.vanini@adamfactory.com
Grazie

More Related Content

What's hot (19)

PDF
Kafka as an Event Store - is it Good Enough?
Guido Schmutz
 
PDF
IoT Data Platforms: Processing IoT Data with Apache Kafka™
confluent
 
PDF
Event Hub (i.e. Kafka) in Modern Data (Analytics) Architecture
Guido Schmutz
 
PPTX
A guide through the Azure Messaging services - Update Conference
Eldert Grootenboer
 
PPTX
RightScale Webinar: How RightScale Architects Its Databases (for Worldwide Sc...
RightScale
 
PDF
Architecting Microservices Applications with Instant Analytics
confluent
 
PPTX
Delivering SaaS Using IaaS - RightScale Compute 2013
RightScale
 
PDF
Introduction to Streaming Analytics
Guido Schmutz
 
PPTX
Supply Chain Optimization with Apache Kafka
Kai Wähner
 
PDF
Redis and Kafka - Advanced Microservices Design Patterns Simplified
Allen Terleto
 
PPTX
Pulsar Watermarking - Pulsar Virtual Summit Europe 2021
StreamNative
 
PDF
Building event-driven Microservices with Kafka Ecosystem
Guido Schmutz
 
PDF
Apache Kafka vs. Integration Middleware (MQ, ETL, ESB) - Friends, Enemies or ...
confluent
 
PDF
Designing For Multicloud, CF Summit Frankfurt 2016
Mark D'Cunha
 
PDF
Top use cases for 2022 with Data in Motion and Apache Kafka
confluent
 
PPTX
Seamless Guest Experience with Kafka Streams
Knoldus Inc.
 
PPTX
NextGen IBM Cloud Monitoring and Logging
Nagesh Ramamoorthy
 
PDF
Kontena@Berlin OpenSource MeetUp
Jussi Nummelin
 
PDF
Architecture Patterns for Event Streaming (Nick Dearden, Confluent) London 20...
confluent
 
Kafka as an Event Store - is it Good Enough?
Guido Schmutz
 
IoT Data Platforms: Processing IoT Data with Apache Kafka™
confluent
 
Event Hub (i.e. Kafka) in Modern Data (Analytics) Architecture
Guido Schmutz
 
A guide through the Azure Messaging services - Update Conference
Eldert Grootenboer
 
RightScale Webinar: How RightScale Architects Its Databases (for Worldwide Sc...
RightScale
 
Architecting Microservices Applications with Instant Analytics
confluent
 
Delivering SaaS Using IaaS - RightScale Compute 2013
RightScale
 
Introduction to Streaming Analytics
Guido Schmutz
 
Supply Chain Optimization with Apache Kafka
Kai Wähner
 
Redis and Kafka - Advanced Microservices Design Patterns Simplified
Allen Terleto
 
Pulsar Watermarking - Pulsar Virtual Summit Europe 2021
StreamNative
 
Building event-driven Microservices with Kafka Ecosystem
Guido Schmutz
 
Apache Kafka vs. Integration Middleware (MQ, ETL, ESB) - Friends, Enemies or ...
confluent
 
Designing For Multicloud, CF Summit Frankfurt 2016
Mark D'Cunha
 
Top use cases for 2022 with Data in Motion and Apache Kafka
confluent
 
Seamless Guest Experience with Kafka Streams
Knoldus Inc.
 
NextGen IBM Cloud Monitoring and Logging
Nagesh Ramamoorthy
 
Kontena@Berlin OpenSource MeetUp
Jussi Nummelin
 
Architecture Patterns for Event Streaming (Nick Dearden, Confluent) London 20...
confluent
 

Similar to INTERNET OF THINGS & AZURE (20)

PDF
IoT & Azure (EventHub)
Mirco Vanini
 
PPTX
High throughput data streaming in Azure
Alexander Laysha
 
PPTX
Building High-scalable Enterprise Solutions,
Swiss Data Forum Swiss Data Forum
 
PPTX
Azure Messaging Crossroads
Sean Feldman
 
PDF
GECon2017_High-volume data streaming in azure_ Aliaksandr Laisha
GECon_Org Team
 
PDF
Azure Event Hubs - Behind the Scenes With Kasun Indrasiri | Current 2022
HostedbyConfluent
 
PDF
Azure IOT: EVENT HUB & STREAM ANALYTICS & POWER BI
Chourouk HJAIEJ
 
PPTX
Latest Updates to Azure Integration Services
Daniel Toomey
 
PPTX
Windows iot barone
DotNetCampus
 
PPTX
MICROSOFT E IL MONDO IOT
DotNetCampus
 
PDF
How to Stream IoT MQTT Messages Into the Azure Event Hubs Service
HiveMQ
 
PPTX
Azure Messaging with Azure Functions
Josh Carlisle
 
PPTX
Azure IoT Summary
Todd Whitehead
 
PPTX
Beyond REST and RPC: Asynchronous Eventing and Messaging Patterns
Clemens Vasters
 
PDF
Serverless Messaging with Microsoft Azure by Steef-Jan Wiggers
Adam Walhout
 
PPTX
Event Grid - quiet event to revolutionize Azure and more
Sean Feldman
 
PDF
Azure Events and Messages
Neeraj Kumar
 
PPTX
Scala API - Azure Event Hub Integration
Braja Krishna Das
 
PDF
IoT
Arun Kumar
 
PPTX
Manage your devices with Azure IoT...and more
Marco Parenzan
 
IoT & Azure (EventHub)
Mirco Vanini
 
High throughput data streaming in Azure
Alexander Laysha
 
Building High-scalable Enterprise Solutions,
Swiss Data Forum Swiss Data Forum
 
Azure Messaging Crossroads
Sean Feldman
 
GECon2017_High-volume data streaming in azure_ Aliaksandr Laisha
GECon_Org Team
 
Azure Event Hubs - Behind the Scenes With Kasun Indrasiri | Current 2022
HostedbyConfluent
 
Azure IOT: EVENT HUB & STREAM ANALYTICS & POWER BI
Chourouk HJAIEJ
 
Latest Updates to Azure Integration Services
Daniel Toomey
 
Windows iot barone
DotNetCampus
 
MICROSOFT E IL MONDO IOT
DotNetCampus
 
How to Stream IoT MQTT Messages Into the Azure Event Hubs Service
HiveMQ
 
Azure Messaging with Azure Functions
Josh Carlisle
 
Azure IoT Summary
Todd Whitehead
 
Beyond REST and RPC: Asynchronous Eventing and Messaging Patterns
Clemens Vasters
 
Serverless Messaging with Microsoft Azure by Steef-Jan Wiggers
Adam Walhout
 
Event Grid - quiet event to revolutionize Azure and more
Sean Feldman
 
Azure Events and Messages
Neeraj Kumar
 
Scala API - Azure Event Hub Integration
Braja Krishna Das
 
Manage your devices with Azure IoT...and more
Marco Parenzan
 
Ad

More from DotNetCampus (20)

PDF
ARCHITETTURA DI UN'APPLICAZIONE SCALABILE
DotNetCampus
 
PPTX
70-485: ADVANCED OF DEVELOPING WINDOWS STORE APPS USING C#
DotNetCampus
 
PDF
70-534: ARCHITECTING MICROSOFT AZURE SOLUTIONS
DotNetCampus
 
PDF
70-483: PROGRAMMING IN C#
DotNetCampus
 
PPTX
DSTORIE DALLA TRINCEA: TEAM FOUNDATION SERVER IN CASI LIMITE E NON SOLO...
DotNetCampus
 
PPTX
TUTTO SU VISUAL STUDIO ALM 2015
DotNetCampus
 
PPTX
CONTINUOUS INTEGRATION CON SQL SERVER
DotNetCampus
 
PPTX
PREDICT THE FUTURE , MACHINE LEARNING & BIG DATA
DotNetCampus
 
PPTX
DESKTOP AND CLIENT VIRTUALIZATION: NEW WORKSTYLES WITH MICROSOFT VDI
DotNetCampus
 
PPTX
FROM ON-PREMISE TO THE HYBRID CLOUD WITH MICROSOFT AZURE
DotNetCampus
 
PPTX
SHAREPOINT 2016 - WHAT'S NEW
DotNetCampus
 
PPTX
COSTRUISCI IL TUO DEVICE
DotNetCampus
 
PPTX
SVILUPPARE PER MICROSOFT BAND
DotNetCampus
 
PPTX
INTERFACCE GRAFICHE CON UNITY3D 4.6: IL GIOCO NON BASTA!
DotNetCampus
 
PPTX
WINDOWS PHONE APPS IN C++
DotNetCampus
 
PPTX
AZURE NOTIFICATION HUB
DotNetCampus
 
PPTX
SFRUTTARE I MICROSOFT AZURE MOBILE SERVICES CON XAMARIN.FORMS
DotNetCampus
 
PPTX
INTRO TO XAMARIN
DotNetCampus
 
PPTX
UNIVERSAL APP IN TUTTE LE SALSE: PHONE, TABLET, PC, XBOX E IOT
DotNetCampus
 
PPTX
SFRUTTARE CORTANA E LE SPEECH API NELLE NOSTRE APP
DotNetCampus
 
ARCHITETTURA DI UN'APPLICAZIONE SCALABILE
DotNetCampus
 
70-485: ADVANCED OF DEVELOPING WINDOWS STORE APPS USING C#
DotNetCampus
 
70-534: ARCHITECTING MICROSOFT AZURE SOLUTIONS
DotNetCampus
 
70-483: PROGRAMMING IN C#
DotNetCampus
 
DSTORIE DALLA TRINCEA: TEAM FOUNDATION SERVER IN CASI LIMITE E NON SOLO...
DotNetCampus
 
TUTTO SU VISUAL STUDIO ALM 2015
DotNetCampus
 
CONTINUOUS INTEGRATION CON SQL SERVER
DotNetCampus
 
PREDICT THE FUTURE , MACHINE LEARNING & BIG DATA
DotNetCampus
 
DESKTOP AND CLIENT VIRTUALIZATION: NEW WORKSTYLES WITH MICROSOFT VDI
DotNetCampus
 
FROM ON-PREMISE TO THE HYBRID CLOUD WITH MICROSOFT AZURE
DotNetCampus
 
SHAREPOINT 2016 - WHAT'S NEW
DotNetCampus
 
COSTRUISCI IL TUO DEVICE
DotNetCampus
 
SVILUPPARE PER MICROSOFT BAND
DotNetCampus
 
INTERFACCE GRAFICHE CON UNITY3D 4.6: IL GIOCO NON BASTA!
DotNetCampus
 
WINDOWS PHONE APPS IN C++
DotNetCampus
 
AZURE NOTIFICATION HUB
DotNetCampus
 
SFRUTTARE I MICROSOFT AZURE MOBILE SERVICES CON XAMARIN.FORMS
DotNetCampus
 
INTRO TO XAMARIN
DotNetCampus
 
UNIVERSAL APP IN TUTTE LE SALSE: PHONE, TABLET, PC, XBOX E IOT
DotNetCampus
 
SFRUTTARE CORTANA E LE SPEECH API NELLE NOSTRE APP
DotNetCampus
 
Ad

Recently uploaded (20)

PPTX
How to Manage Allocation Report for Manufacturing Orders in Odoo 18
Celine George
 
PPTX
Identifying elements in the story. Arrange the events in the story
geraldineamahido2
 
PPTX
PPT-Q1-WEEK-3-SCIENCE-ERevised Matatag Grade 3.pptx
reijhongidayawan02
 
PDF
Women's Health: Essential Tips for Every Stage.pdf
Iftikhar Ahmed
 
PPTX
infertility, types,causes, impact, and management
Ritu480198
 
PDF
The Constitution Review Committee (CRC) has released an updated schedule for ...
nservice241
 
PDF
epi editorial commitee meeting presentation
MIPLM
 
PDF
The History of Phone Numbers in Stoke Newington by Billy Thomas
History of Stoke Newington
 
PDF
Characteristics, Strengths and Weaknesses of Quantitative Research.pdf
Thelma Villaflores
 
PPTX
care of patient with elimination needs.pptx
Rekhanjali Gupta
 
PPTX
CATEGORIES OF NURSING PERSONNEL: HOSPITAL & COLLEGE
PRADEEP ABOTHU
 
PPTX
EDUCATIONAL MEDIA/ TEACHING AUDIO VISUAL AIDS
Sonali Gupta
 
PDF
Week 2 - Irish Natural Heritage Powerpoint.pdf
swainealan
 
PPTX
Controller Request and Response in Odoo18
Celine George
 
PDF
Governor Josh Stein letter to NC delegation of U.S. House
Mebane Rash
 
PDF
Stokey: A Jewish Village by Rachel Kolsky
History of Stoke Newington
 
PDF
Vani - The Voice of Excellence - Jul 2025 issue
Savipriya Raghavendra
 
PPTX
TRANSLATIONAL AND ROTATIONAL MOTION.pptx
KIPAIZAGABAWA1
 
PPTX
Nitrogen rule, ring rule, mc lafferty.pptx
nbisen2001
 
PPTX
Introduction to Biochemistry & Cellular Foundations.pptx
marvinnbustamante1
 
How to Manage Allocation Report for Manufacturing Orders in Odoo 18
Celine George
 
Identifying elements in the story. Arrange the events in the story
geraldineamahido2
 
PPT-Q1-WEEK-3-SCIENCE-ERevised Matatag Grade 3.pptx
reijhongidayawan02
 
Women's Health: Essential Tips for Every Stage.pdf
Iftikhar Ahmed
 
infertility, types,causes, impact, and management
Ritu480198
 
The Constitution Review Committee (CRC) has released an updated schedule for ...
nservice241
 
epi editorial commitee meeting presentation
MIPLM
 
The History of Phone Numbers in Stoke Newington by Billy Thomas
History of Stoke Newington
 
Characteristics, Strengths and Weaknesses of Quantitative Research.pdf
Thelma Villaflores
 
care of patient with elimination needs.pptx
Rekhanjali Gupta
 
CATEGORIES OF NURSING PERSONNEL: HOSPITAL & COLLEGE
PRADEEP ABOTHU
 
EDUCATIONAL MEDIA/ TEACHING AUDIO VISUAL AIDS
Sonali Gupta
 
Week 2 - Irish Natural Heritage Powerpoint.pdf
swainealan
 
Controller Request and Response in Odoo18
Celine George
 
Governor Josh Stein letter to NC delegation of U.S. House
Mebane Rash
 
Stokey: A Jewish Village by Rachel Kolsky
History of Stoke Newington
 
Vani - The Voice of Excellence - Jul 2025 issue
Savipriya Raghavendra
 
TRANSLATIONAL AND ROTATIONAL MOTION.pptx
KIPAIZAGABAWA1
 
Nitrogen rule, ring rule, mc lafferty.pptx
nbisen2001
 
Introduction to Biochemistry & Cellular Foundations.pptx
marvinnbustamante1
 

INTERNET OF THINGS & AZURE

  • 1. Template designed by IoT & Azure Mirco Vanini [email protected] http://mircovanini.blogspot.it/
  • 2. Slide con sponsor che arriva a qualche giorno dalla conferenza sponsor
  • 3. adam | factory analisi, progettazione, consulenza, alm, formazione Microsoft MVP for Windows Embedded XeDotNet TinyCLR.it @MircoVanini http://it.linkedin.com/in/proxsoft http://mvp.microsoft.com/it-it/MVP/Mirco%20Vanini-4039714 chi sono
  • 4. Microsoft Azure IoT Services Azure Service Bus Azure Event Hubs Azure Stream Analitycs Demo Recap agenda
  • 5. microsoft azure IoT services Producers Connect Devices Storage Analytics Take Action Event Hubs SQL Database Machine Learning Azure Websites Service Bus Table/Blob Storage Stream Analytics Power BI External Data Sources DocumentDB HDInsight Notification Hubs External Data Sources Data Factory Mobile Services BizTalk Services { } Microsoft Azure IoT Services
  • 6. Azure Service Bus Relay Queue Topic Notification Hub Event Hub NAT and Firewall Traversal Service Request/Response Services Unbuffered with TCP Throttling Transactional Cloud AMQP/HTTP Broker High-Scale, High-Reliability Messaging Sessions, Scheduled Delivery, etc. Transactional Message Distribution Up to 2000 subscriptions per Topic Up to 2K/100K filter rules per subscription High-scale notification distribution Most mobile push notification services Millions of notification targets …
  • 7. intelligent mobility and connected car
  • 8. telemetry ... the problem Information flowing from a device to other systems for conveying status of device and environment Unidirectional Data frequency can be different based on applications/conditions
  • 9. service bus - queus & topics Message are durably stored but with TTL Receive & Delete or Peek Lock Sessions (for FIFO feature) Request/Reply pattern (based on correlation) Transaction for batch send/receive Dead-letter queue (TTL or “poisoned” messages)
  • 10. introducing azure event hubs Event Producers > 1M Producers > 1GB/sec Aggregate Throughput Direct PartitionKey Hash Receivers AMQP 1.0 Credit-based flow control Client-side cursors Offset by Id or Timestamp Throughput Units: • 1 ≤ TUs ≤ Partition Count • TU: 1 MB/s writes, 2 MB/s reads
  • 11. event hubs - overview Event Hubs is a highly scalable ingestion system that can process millions of events per second, enabling your application to process and analyze the massive amounts of data produced by your connected devices and applications. The Azure Event Hubs capability differs from Service Bus topics in that it is strongly biased towards high throughput and event processing scenarios.
  • 12. event hubs - overview An Event Hub is created at the namespace level in Service Bus, similar to queues and topics. Event Hubs uses AMQP and HTTP as its primary API interfaces.
  • 13. event hubs - partitions Event Hubs provides message streaming through a partitioned consumer pattern. A partition is an ordered sequence of events that is held in an Event Hub. As newer events arrive, they are added to the end of this sequence. A partition can be thought of as a “commit log.” The number of partitions is specified at the Event Hub creation time and must be between 8 and 32. Segmentation of event stream for scale-out.
  • 14. event hubs - event data In the Event Hubs context, messages are referred to as event data. Event data contains the body of the event, a user defined property bag, and various metadata about the event such as its offset in the partition and its number in the stream sequence. Partitions are filled with a sequence of event data (max 256kb). You can publish an event via AMQP 1.0 or HTTP. Service Bus provides an EventHubClient class that you can use for publishing events to an Event Hub from .NET clients. For other runtimes and platforms, you can use any AMQP 1.0 client such as Apache Qpid.
  • 15. event hubs - what is AMQP 1.0? Advanced Message Queuing Protocol (AMQP) is an efficient, reliable, wire-level messaging protocol (OASIS standard) that you can use to build robust, cross-platform, messaging applications. The protocol has a simple goal: to define the mechanics of the secure, reliable, and efficient transfer of messages between two parties.
  • 16. event hubs - AMQP or HTTP ? The choice to use AMQP or HTTP is specific to the usage scenario. AMQP requires the establishment of a persistent bidirectional socket in addition to transport level security (TLS) or SSL/TLS. This can be a costly operation in terms of network traffic, but only happens at the beginning of an AMQP session. HTTP has a lower initial overhead, but requires additional SSL overhead for every request. For publishers who frequently publish events, AMQP offers significant performance, latency, and throughput savings
  • 17. event hubs - partition key A partition key is a value that is used to map incoming event data into specific partitions for the purposes of data organization. The partition key is a sender-supplied value passed into an Event Hub. It is processed through a static hashing function, the result of which creates the partition assignment. Event Hubs ensures that any and all events sharing the same partition key value are delivered in order, and to the same partition.
  • 18. event hubs - consumer groups The publish/subscribe mechanism of Event Hubs is enabled through consumer groups. A consumer group is a view (state, position, or offset) of an entire Event Hub. Consumer groups enable multiple consuming applications to each have a separate view of the event stream, and to read the stream independently at its own pace and with its own offsets.
  • 19. event hubs - stream offset An offset is the position of an event within a partition. You can think of an offset as a client-side cursor. The offset is a byte numbering of the event. This enables an event consumer (reader) to specify a point in the event stream from which they want to begin reading events. You can specify the offset as a timestamp or as an offset value.
  • 20. event hubs - reading events In order to consume events from an Event Hub, a consumer must connect to a partition. Only a single reader should be active on a partition at any one time within a consumer group. Each event data instance contains important metadata such as the offset and sequence number that are used to facilitate checkpointing on the event sequence.
  • 21. event hubs - throughput units The throughput capacity of Event Hubs is controlled by throughput units. Throughput units are pre-purchased units of capacity. A single throughput unit includes the following: Write: Up to 1MB per second or 1000 events per second. Read: Up to 2MB per second. Included retention: 84GByte/day (24h at full ingress rate) Sending data above this amount results in a quota exceeded exception ! Throughput units are billed per hour and are purchased ahead of time Up to 20 throughput units can be purchased for a Service Bus namespace
  • 22. event hubs vs queues & topics Patterns Q&T : useful for Command Message and Request/Replay Message (response queue) EH : useful for Event Messages Cursor Q&T : on server side. Message consumed and deleted from queue, cursor to next available message EH : on client side. Client can rewind on the stream and re-read same events (during their retention). Access partition by offset or timestamp Retention Q&T : TTL at queue/topic level or message level EH : max 7 days
  • 23. event hubs vs queues & topics Security & Authentication Q&T and EH • SSL/TLS via HTTP(S) or AMQP(S) • SAS (Secure Access Signature) for sending/receiving EH • Publisher policy (SAS Token) • Fine grained per device • Revoke/Restore publisher Other EH doesn't have dead lettering, transaction, ... to have higher throughput
  • 24. stream analitycs - overview Real-time business insights Stream Analytics is an event processing engine that helps uncover real-time insights from devices, sensors, infrastructure, applications and data. Stream millions of events per second Stream Analytics provides out-of-the-box integration with Event Hubs to ingest millions of events per second. Together, Event Hubs and Stream Analytics let you process massive amounts of real-time data so you can make business decisions in real-time. Real-time processing Stream Analytics will process ingested events in real-time, comparing multiple real-time streams or comparing real-time streams together with historical values and models
  • 25. event hubs - connect the things Intel Galileo Intel® Quark™ X1000 Win32 / C++ Qpid Proton - Apache Library GHI Fez Spider 72 Mhz 32-bit ARM7 .NET MF & Gadgeteer / C# Amqp.Net Lite Toradex Colibri T30 NVIDIA® Tegra™ 3 .NET CF / WEC2013 / C# Amqp.Net Lite http://qpid.apache.org/proton/ https://amqpnetlite.codeplex.com/
  • 26. demo connect things to azure event hub
  • 27. event hubs - pricing BASIC Standard Ingress events €0.0209 per million events €0.0209 per million events Throughput unit (1 MB/s ingress, 2MB/s egress) €0.0112/hr (~€9/mo) €0.0224/hr (~€17/mo) Publisher policies √ Consumer groups 1 - Default 20 Maximum throughput units 20 20 Service Bus brokered connections 100 included 1000 included Additional Service Bus brokered connections √ Message Retention 1 day included 1 day included Additional storage (up to 7 days) √ http://azure.microsoft.com/en-us/pricing/details/event-hubs/
  • 28. recap Stream millions of events per second into multiple applications Enable applications to process events with variable load profiles Connect millions of devices across platforms Available NOW !
  • 29. Grazie a tutti per la partecipazione Riceverete il link per il download a slide e demo via email nei prossimi giorni Per contattarmi [email protected] Grazie