SlideShare a Scribd company logo
1 of 25
Download to read offline
A Scalable and Hybrid Cloud
Framework for Evaluating Streams
of Sensor Data in Real-Time
Gabriele Di Bernardo
November 14, 2017
Sensors
• A sensor is a device that measures a physical quantity and convert
it into a signal which can be read by an electronic instrument
• Smartphone sensors (e.g., accelerometer, GPS, gyroscope,
ambient light sensors, barometer and many others).
• By 2018, over a third of the world’s population is projected to
own a smartphone, an estimated total of almost 2.53 billion
smartphone users in the world. - statista.com
• Internet-of-Things
• 8 billion connected things will be in use worldwide in 2017
and will reach 20.4 billion by 2020 according to Gartner Inc.
• Can we process all this sensor-generated data in real-time?
!2
The SWAN
Framework
• SWAN (Sensing With Android Nodes) is a framework
for easily building context-aware applications for
Android smartphones
• High-level abstraction for accessing smartphone
sensors
• Multi sensor support (20+ types of sensors)
!3
SWAN-Song
• SWAN-Song is a domain specific language for context
expressions
• Sensor data evaluated through a history window and
a history reduction operator
• Predicates can be combinated using math, comparison
and logic operators
self@light : lux{MEAN, 2000ms}
!4
The Cowbird Framework
• Cowbird combines smartphone
sensors and real-time data
generated by IoT sensors
• IoT sensor data sensed in the
cloud via Java threads
• Streams of sensor data
continuously sensed and
processed
• Smartphone sensors evaluation is
performed locally
• IoT sensors evaluation is
computed in the cloud
!5
Research Questions
• Which architecture can be used to process large
streams of data?
• Which technologies can be used to create real-time
data streaming applications?
• How Cowbird can be extended in order to build a
platform that senses and evaluates a large number of
sensor data streams in real-time?
!6
Lambda Architecture
!7
Stream Processing
Frameworks
• Distributed processing engines
• Two data processing methods
• Micro-batch
• Stream
!8
Benchmarking Stream Processing
Frameworks for Cowbird
!9
0
500
1000
1500
2000
2500
3000
3500
4000
0 20000 40000 60000 80000 100000
Latency(ms)
Input (messages/s)
Flink
Spark Streaming
Kafka Streams
Hybrid-Cowbirds
!10
Cowbird Fog
!11
Cowbird Streams
• Powered by Apache Flink
• Communication between Fog and Streams mediated by Kafka
broker
• Stream state kept by RocksDB
• Two SWAN-Song evaluation implementations
• Smart offloading
cloud@thingspeak : temperature{MEAN, 3h} > 24.0
cloud@thingspeak : temperature{ANY, 3h} > 24.0
!12
SWAN-Song
Streaming-Oriented Evaluation
• Original SWAN framework collects all sensor values
within the time window and the history reduction mode
is then applied
• Streaming-oriented evaluation keeps only partial
results of each stream instead of all the data values
• MEDIAN reduction mode implemented through
Remedian algorithm
• O(log n) space
• Fixed or aligned time windows
!13
Hybrid-Cowbirds Evaluation
• Test application evaluates data coming from different
sound sensors arranged in different geographical locations
• Testing environment @ SURFsara
• Cowbird Fog 8 nodes (16 vCPU, 16 GiB memory)
• Kafka 1 node (16 vCPU, 32 GiB memory, 50 GiB disk).
• Cowbird Streams 16 YARN containers (8 vCPU, 48 GiB
memory)
• We evaluated performance in terms of latency and
throughput
!14
Experimental Results
!15
0
1000
2000
3000
4000
5000
6000
7000
0 10 20 30 40 50 60
Latency(ms)
Active SWAN-Song expressions
Fog
Streams
Cowbird
Experimental Results
64
128
256
512
1024
2048
4096
8192
100 150 200 250 300 350
Latency(ms)
Active SWAN-Song expressions
Fog
Streams
!16
Experimental Results
0
100
200
300
400
500
600
700
800
0 50 100 150 200 250 300 350
Latency(ms)
Active SWAN-Song expressions
Fog
Streams
!17
Experimental Results
!18
0
20
40
60
80
100
120
Streaming-oriented Core
RocksDBcheckpointdirectorysize(MB)
Experimental Results
750
800
850
900
950
1000
1050
1100
1150
1000 1500 2000 2500 3000 3500 4000 4500 5000
Latency(ms)
Active SWAN-Song expressions
Core
Streaming-oriented
!19
Related Work
Many different sensor-oriented streaming
architectures available in the literature
• Implementations of the Lambda architecture
• Limited to particular scenarios/use cases (e.g.,
robotics, smart farms, etc.)
!20
Conclusions
• Designed and implemented a hybrid and scalable
distributed architecture for the Cowbird framework
• Distributed sensing and evaluation(s) layer
• Capable of evaluating large loads of SWAN-Song
expressions with a low latency
• SWAN-Song expressions evaluation can be performed
by both the architectural layers depending by the
scenario
!21
Future Work
• Investigating the feasibility of adopting the realized
architecture in a fog computing scenario
• Implementing a real-time adaptive heuristic for offloading
SWAN-Song expressions evaluation to the Streams layer
• Re-engineering Cowbird internals as Akka actors
• Binary format for communication messages
• Extending SWAN-Song semantics to support Flink
features (e.g., ML, CEP)
!22
Questions?
Benchmarking Streaming
Engines for Cowbird
0
5000
10000
15000
20000
25000
30000
35000
40000
45000
50000
0 100000 200000 300000 400000 500000 600000 700000 800000 900000 1x106
Latency(ms)
Input (messages/s)
Flink
Spark Streaming
Kafka Streams
0
2000
4000
6000
8000
10000
12000
14000
16000
18000
20000
0 1000 2000 3000 4000 5000 6000 7000 8000 9000 10000
Latency(ms)
Input (messages/s)
Flink
Spark Streaming
!24
Experimental Results
0
500
1000
1500
2000
2500
3000
3500
0 100 200 300 400 500 600 700
Latency(ms)
Active SWAN-Song expressions
Fog
Streams
0
500
1000
1500
2000
2500
3000
3500
0 50 100 150 200 250 300 350
Latency(ms)
Active SWAN-Song expressions
Fog
Streams
!25

More Related Content

Similar to A Scalable and Hybrid Cloud Framework for Evaluating Streams of Sensor Data in Real-Time

Informix - The Ideal Database for IoT
Informix - The Ideal Database for IoTInformix - The Ideal Database for IoT
Informix - The Ideal Database for IoTPradeep Natarajan
 
Large Scale Stream Analytics using a Resource-constrained Edge
Large Scale Stream Analytics using a Resource-constrained EdgeLarge Scale Stream Analytics using a Resource-constrained Edge
Large Scale Stream Analytics using a Resource-constrained EdgeGabriele Di Bernardo
 
Fom io t_to_bigdata_step_by_step-final
Fom io t_to_bigdata_step_by_step-finalFom io t_to_bigdata_step_by_step-final
Fom io t_to_bigdata_step_by_step-finalLuis Filipe Silva
 
Smack Stack and Beyond—Building Fast Data Pipelines with Jorg Schad
Smack Stack and Beyond—Building Fast Data Pipelines with Jorg SchadSmack Stack and Beyond—Building Fast Data Pipelines with Jorg Schad
Smack Stack and Beyond—Building Fast Data Pipelines with Jorg SchadSpark Summit
 
Webinar - Big Data: Let's SMACK - Jorg Schad
Webinar - Big Data: Let's SMACK - Jorg SchadWebinar - Big Data: Let's SMACK - Jorg Schad
Webinar - Big Data: Let's SMACK - Jorg SchadCodemotion
 
Spark Summit EU: IBM Keynote
Spark Summit EU: IBM KeynoteSpark Summit EU: IBM Keynote
Spark Summit EU: IBM Keynotesparktc
 
Realizing the Promise of Portable Data Processing with Apache Beam
Realizing the Promise of Portable Data Processing with Apache BeamRealizing the Promise of Portable Data Processing with Apache Beam
Realizing the Promise of Portable Data Processing with Apache BeamDataWorks Summit
 
Course Notes-Unit 5.ppt
Course Notes-Unit 5.pptCourse Notes-Unit 5.ppt
Course Notes-Unit 5.pptSafaM3
 
IoT Sensor Analytics with Python, Jupyter, TensorFlow, Keras, Apache Kafka, K...
IoT Sensor Analytics with Python, Jupyter, TensorFlow, Keras, Apache Kafka, K...IoT Sensor Analytics with Python, Jupyter, TensorFlow, Keras, Apache Kafka, K...
IoT Sensor Analytics with Python, Jupyter, TensorFlow, Keras, Apache Kafka, K...Kai Wähner
 
Ingestion in data pipelines with Managed Kafka Clusters in Azure HDInsight
Ingestion in data pipelines with Managed Kafka Clusters in Azure HDInsightIngestion in data pipelines with Managed Kafka Clusters in Azure HDInsight
Ingestion in data pipelines with Managed Kafka Clusters in Azure HDInsightMicrosoft Tech Community
 
DataStax and Esri: Geotemporal IoT Search and Analytics
DataStax and Esri: Geotemporal IoT Search and AnalyticsDataStax and Esri: Geotemporal IoT Search and Analytics
DataStax and Esri: Geotemporal IoT Search and AnalyticsDataStax Academy
 
SnappyData @ Seattle Spark Meetup
SnappyData @ Seattle Spark MeetupSnappyData @ Seattle Spark Meetup
SnappyData @ Seattle Spark MeetupSnappyData
 
ApacheCon2019 Talk: Kafka, Cassandra and Kubernetes at Scale – Real-time Ano...
ApacheCon2019 Talk: Kafka, Cassandra and Kubernetesat Scale – Real-time Ano...ApacheCon2019 Talk: Kafka, Cassandra and Kubernetesat Scale – Real-time Ano...
ApacheCon2019 Talk: Kafka, Cassandra and Kubernetes at Scale – Real-time Ano...Paul Brebner
 
Realizing the promise of portable data processing with Apache Beam
Realizing the promise of portable data processing with Apache BeamRealizing the promise of portable data processing with Apache Beam
Realizing the promise of portable data processing with Apache BeamDataWorks Summit
 
Big Data Day LA 2015 - Big Data Day LA 2015 - Applying GeoSpatial Analytics u...
Big Data Day LA 2015 - Big Data Day LA 2015 - Applying GeoSpatial Analytics u...Big Data Day LA 2015 - Big Data Day LA 2015 - Applying GeoSpatial Analytics u...
Big Data Day LA 2015 - Big Data Day LA 2015 - Applying GeoSpatial Analytics u...Data Con LA
 
Evolving Beyond the Data Lake: A Story of Wind and Rain
Evolving Beyond the Data Lake: A Story of Wind and RainEvolving Beyond the Data Lake: A Story of Wind and Rain
Evolving Beyond the Data Lake: A Story of Wind and RainMapR Technologies
 
AWS re:Invent 2016: Moving Mission Critical Apps from One Region to Multi-Reg...
AWS re:Invent 2016: Moving Mission Critical Apps from One Region to Multi-Reg...AWS re:Invent 2016: Moving Mission Critical Apps from One Region to Multi-Reg...
AWS re:Invent 2016: Moving Mission Critical Apps from One Region to Multi-Reg...Amazon Web Services
 
Data Streaming with Apache Kafka & MongoDB
Data Streaming with Apache Kafka & MongoDBData Streaming with Apache Kafka & MongoDB
Data Streaming with Apache Kafka & MongoDBconfluent
 

Similar to A Scalable and Hybrid Cloud Framework for Evaluating Streams of Sensor Data in Real-Time (20)

Informix - The Ideal Database for IoT
Informix - The Ideal Database for IoTInformix - The Ideal Database for IoT
Informix - The Ideal Database for IoT
 
On Crowd-sensing back-end
On Crowd-sensing back-endOn Crowd-sensing back-end
On Crowd-sensing back-end
 
Large Scale Stream Analytics using a Resource-constrained Edge
Large Scale Stream Analytics using a Resource-constrained EdgeLarge Scale Stream Analytics using a Resource-constrained Edge
Large Scale Stream Analytics using a Resource-constrained Edge
 
Fom io t_to_bigdata_step_by_step-final
Fom io t_to_bigdata_step_by_step-finalFom io t_to_bigdata_step_by_step-final
Fom io t_to_bigdata_step_by_step-final
 
Smack Stack and Beyond—Building Fast Data Pipelines with Jorg Schad
Smack Stack and Beyond—Building Fast Data Pipelines with Jorg SchadSmack Stack and Beyond—Building Fast Data Pipelines with Jorg Schad
Smack Stack and Beyond—Building Fast Data Pipelines with Jorg Schad
 
Webinar - Big Data: Let's SMACK - Jorg Schad
Webinar - Big Data: Let's SMACK - Jorg SchadWebinar - Big Data: Let's SMACK - Jorg Schad
Webinar - Big Data: Let's SMACK - Jorg Schad
 
Spark Summit EU: IBM Keynote
Spark Summit EU: IBM KeynoteSpark Summit EU: IBM Keynote
Spark Summit EU: IBM Keynote
 
Realizing the Promise of Portable Data Processing with Apache Beam
Realizing the Promise of Portable Data Processing with Apache BeamRealizing the Promise of Portable Data Processing with Apache Beam
Realizing the Promise of Portable Data Processing with Apache Beam
 
Spark Technology Center IBM
Spark Technology Center IBMSpark Technology Center IBM
Spark Technology Center IBM
 
Course Notes-Unit 5.ppt
Course Notes-Unit 5.pptCourse Notes-Unit 5.ppt
Course Notes-Unit 5.ppt
 
IoT Sensor Analytics with Python, Jupyter, TensorFlow, Keras, Apache Kafka, K...
IoT Sensor Analytics with Python, Jupyter, TensorFlow, Keras, Apache Kafka, K...IoT Sensor Analytics with Python, Jupyter, TensorFlow, Keras, Apache Kafka, K...
IoT Sensor Analytics with Python, Jupyter, TensorFlow, Keras, Apache Kafka, K...
 
Ingestion in data pipelines with Managed Kafka Clusters in Azure HDInsight
Ingestion in data pipelines with Managed Kafka Clusters in Azure HDInsightIngestion in data pipelines with Managed Kafka Clusters in Azure HDInsight
Ingestion in data pipelines with Managed Kafka Clusters in Azure HDInsight
 
DataStax and Esri: Geotemporal IoT Search and Analytics
DataStax and Esri: Geotemporal IoT Search and AnalyticsDataStax and Esri: Geotemporal IoT Search and Analytics
DataStax and Esri: Geotemporal IoT Search and Analytics
 
SnappyData @ Seattle Spark Meetup
SnappyData @ Seattle Spark MeetupSnappyData @ Seattle Spark Meetup
SnappyData @ Seattle Spark Meetup
 
ApacheCon2019 Talk: Kafka, Cassandra and Kubernetes at Scale – Real-time Ano...
ApacheCon2019 Talk: Kafka, Cassandra and Kubernetesat Scale – Real-time Ano...ApacheCon2019 Talk: Kafka, Cassandra and Kubernetesat Scale – Real-time Ano...
ApacheCon2019 Talk: Kafka, Cassandra and Kubernetes at Scale – Real-time Ano...
 
Realizing the promise of portable data processing with Apache Beam
Realizing the promise of portable data processing with Apache BeamRealizing the promise of portable data processing with Apache Beam
Realizing the promise of portable data processing with Apache Beam
 
Big Data Day LA 2015 - Big Data Day LA 2015 - Applying GeoSpatial Analytics u...
Big Data Day LA 2015 - Big Data Day LA 2015 - Applying GeoSpatial Analytics u...Big Data Day LA 2015 - Big Data Day LA 2015 - Applying GeoSpatial Analytics u...
Big Data Day LA 2015 - Big Data Day LA 2015 - Applying GeoSpatial Analytics u...
 
Evolving Beyond the Data Lake: A Story of Wind and Rain
Evolving Beyond the Data Lake: A Story of Wind and RainEvolving Beyond the Data Lake: A Story of Wind and Rain
Evolving Beyond the Data Lake: A Story of Wind and Rain
 
AWS re:Invent 2016: Moving Mission Critical Apps from One Region to Multi-Reg...
AWS re:Invent 2016: Moving Mission Critical Apps from One Region to Multi-Reg...AWS re:Invent 2016: Moving Mission Critical Apps from One Region to Multi-Reg...
AWS re:Invent 2016: Moving Mission Critical Apps from One Region to Multi-Reg...
 
Data Streaming with Apache Kafka & MongoDB
Data Streaming with Apache Kafka & MongoDBData Streaming with Apache Kafka & MongoDB
Data Streaming with Apache Kafka & MongoDB
 

Recently uploaded

Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsArshad QA
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)OPEN KNOWLEDGE GmbH
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsAlberto González Trastoy
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsAndolasoft Inc
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...OnePlan Solutions
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerThousandEyes
 
why an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfwhy an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfjoe51371421
 
Active Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdfActive Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdfCionsystems
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxComplianceQuest1
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideChristina Lin
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdfWave PLM
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfkalichargn70th171
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 

Recently uploaded (20)

Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.js
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
 
why an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfwhy an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdf
 
Active Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdfActive Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdf
 
A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docx
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
 
Call Girls In Mukherjee Nagar 📱 9999965857 🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
Call Girls In Mukherjee Nagar 📱  9999965857  🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...Call Girls In Mukherjee Nagar 📱  9999965857  🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
Call Girls In Mukherjee Nagar 📱 9999965857 🤩 Delhi 🫦 HOT AND SEXY VVIP 🍎 SE...
 
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS LiveVip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 

A Scalable and Hybrid Cloud Framework for Evaluating Streams of Sensor Data in Real-Time

  • 1. A Scalable and Hybrid Cloud Framework for Evaluating Streams of Sensor Data in Real-Time Gabriele Di Bernardo November 14, 2017
  • 2. Sensors • A sensor is a device that measures a physical quantity and convert it into a signal which can be read by an electronic instrument • Smartphone sensors (e.g., accelerometer, GPS, gyroscope, ambient light sensors, barometer and many others). • By 2018, over a third of the world’s population is projected to own a smartphone, an estimated total of almost 2.53 billion smartphone users in the world. - statista.com • Internet-of-Things • 8 billion connected things will be in use worldwide in 2017 and will reach 20.4 billion by 2020 according to Gartner Inc. • Can we process all this sensor-generated data in real-time? !2
  • 3. The SWAN Framework • SWAN (Sensing With Android Nodes) is a framework for easily building context-aware applications for Android smartphones • High-level abstraction for accessing smartphone sensors • Multi sensor support (20+ types of sensors) !3
  • 4. SWAN-Song • SWAN-Song is a domain specific language for context expressions • Sensor data evaluated through a history window and a history reduction operator • Predicates can be combinated using math, comparison and logic operators self@light : lux{MEAN, 2000ms} !4
  • 5. The Cowbird Framework • Cowbird combines smartphone sensors and real-time data generated by IoT sensors • IoT sensor data sensed in the cloud via Java threads • Streams of sensor data continuously sensed and processed • Smartphone sensors evaluation is performed locally • IoT sensors evaluation is computed in the cloud !5
  • 6. Research Questions • Which architecture can be used to process large streams of data? • Which technologies can be used to create real-time data streaming applications? • How Cowbird can be extended in order to build a platform that senses and evaluates a large number of sensor data streams in real-time? !6
  • 8. Stream Processing Frameworks • Distributed processing engines • Two data processing methods • Micro-batch • Stream !8
  • 9. Benchmarking Stream Processing Frameworks for Cowbird !9 0 500 1000 1500 2000 2500 3000 3500 4000 0 20000 40000 60000 80000 100000 Latency(ms) Input (messages/s) Flink Spark Streaming Kafka Streams
  • 12. Cowbird Streams • Powered by Apache Flink • Communication between Fog and Streams mediated by Kafka broker • Stream state kept by RocksDB • Two SWAN-Song evaluation implementations • Smart offloading cloud@thingspeak : temperature{MEAN, 3h} > 24.0 cloud@thingspeak : temperature{ANY, 3h} > 24.0 !12
  • 13. SWAN-Song Streaming-Oriented Evaluation • Original SWAN framework collects all sensor values within the time window and the history reduction mode is then applied • Streaming-oriented evaluation keeps only partial results of each stream instead of all the data values • MEDIAN reduction mode implemented through Remedian algorithm • O(log n) space • Fixed or aligned time windows !13
  • 14. Hybrid-Cowbirds Evaluation • Test application evaluates data coming from different sound sensors arranged in different geographical locations • Testing environment @ SURFsara • Cowbird Fog 8 nodes (16 vCPU, 16 GiB memory) • Kafka 1 node (16 vCPU, 32 GiB memory, 50 GiB disk). • Cowbird Streams 16 YARN containers (8 vCPU, 48 GiB memory) • We evaluated performance in terms of latency and throughput !14
  • 15. Experimental Results !15 0 1000 2000 3000 4000 5000 6000 7000 0 10 20 30 40 50 60 Latency(ms) Active SWAN-Song expressions Fog Streams Cowbird
  • 16. Experimental Results 64 128 256 512 1024 2048 4096 8192 100 150 200 250 300 350 Latency(ms) Active SWAN-Song expressions Fog Streams !16
  • 17. Experimental Results 0 100 200 300 400 500 600 700 800 0 50 100 150 200 250 300 350 Latency(ms) Active SWAN-Song expressions Fog Streams !17
  • 19. Experimental Results 750 800 850 900 950 1000 1050 1100 1150 1000 1500 2000 2500 3000 3500 4000 4500 5000 Latency(ms) Active SWAN-Song expressions Core Streaming-oriented !19
  • 20. Related Work Many different sensor-oriented streaming architectures available in the literature • Implementations of the Lambda architecture • Limited to particular scenarios/use cases (e.g., robotics, smart farms, etc.) !20
  • 21. Conclusions • Designed and implemented a hybrid and scalable distributed architecture for the Cowbird framework • Distributed sensing and evaluation(s) layer • Capable of evaluating large loads of SWAN-Song expressions with a low latency • SWAN-Song expressions evaluation can be performed by both the architectural layers depending by the scenario !21
  • 22. Future Work • Investigating the feasibility of adopting the realized architecture in a fog computing scenario • Implementing a real-time adaptive heuristic for offloading SWAN-Song expressions evaluation to the Streams layer • Re-engineering Cowbird internals as Akka actors • Binary format for communication messages • Extending SWAN-Song semantics to support Flink features (e.g., ML, CEP) !22
  • 24. Benchmarking Streaming Engines for Cowbird 0 5000 10000 15000 20000 25000 30000 35000 40000 45000 50000 0 100000 200000 300000 400000 500000 600000 700000 800000 900000 1x106 Latency(ms) Input (messages/s) Flink Spark Streaming Kafka Streams 0 2000 4000 6000 8000 10000 12000 14000 16000 18000 20000 0 1000 2000 3000 4000 5000 6000 7000 8000 9000 10000 Latency(ms) Input (messages/s) Flink Spark Streaming !24
  • 25. Experimental Results 0 500 1000 1500 2000 2500 3000 3500 0 100 200 300 400 500 600 700 Latency(ms) Active SWAN-Song expressions Fog Streams 0 500 1000 1500 2000 2500 3000 3500 0 50 100 150 200 250 300 350 Latency(ms) Active SWAN-Song expressions Fog Streams !25