iot supercharged: complex event processing for mqtt with eclipse technologies
Post on 12-Apr-2017
1.003 Views
Preview:
TRANSCRIPT
IoT Supercharged:Complex event processing for
MQTT with Eclipse technologies
István Ráth (Budapest University of Technology and Economics)
Ákos Horváth (IncQuery Labs)
IoT challenges
SensorsSmart home
Personaldevices
• Challenges• Produce a coherent view of the system• Detect and react quickly• Scale with system complexity
• Lots of data• Many different sources• Many different original formats
States and events
Window is open
Window is closed
window_close
window_open
State
Event
State-based logic: switch (state) {case (window_open): if (room_temp<12) alarm();}
Event-based logic: on (window_open) {if (room_temp<12) alarm();}
How do I …?
when (“window was opened at least 10 minutes ago” && “room cools down to 12”) { alarm();}
Complex event processing
Event 1
Event 2
Event n
Event 3
Time window: > 10 mins
Room_temp is below 12AND
it was higher beforeAND
window was opened >10 mins ago AND
wasn’t closed since
Room_temp = 15
Window_open = true
Room_temp = 11
Door_closed = true
Event stream
Complex event processing
Event 1
Event 2
Event n
Event 3
Room_temp = 15
Window_open = true
Room_temp = 11
Time window: > 10 mins
Room_temp is below 12AND
it was higher beforeAND
window was opened >10 mins ago AND
wasn’t closed since
Door_closed = true
MATCH
• Traditional application domains:• Online log analysis• Intrusion / fraud detection• Algorithmic trading, …
• Tools• Microsoft, Oracle, SAP, …• Drools Fusion (ASL 2)• Esper (GPL v2)
• And now: VIATRA-CEP (EPL)!
OSGi
VIATRA-CEP overview
Runtime
Designtime
VIATRA-CEP(VEPL)
EMF-IncQuery
(IQPL)
Arduino, RasPI etc.
MQTT Runtime EMF model
VIATRA-CEP runtime
Dashboard
• Xtext-based DSLs powered by XBase
• Easy to integrate with Java or Xtend• Reuse your existing Java code
• Structured system state representation
• Serialization in human readable format
• Use Modeling tools in new ways:Debugging and Visualization• See our other talk on Sirius
“live diagrams” Thu 11.15 Silchersaalhttps://goo.gl/SmvMv8
• EMF-IncQuery: scalable incremental EMF queries
• VIATRA: live model transformations based on IncQuery and Xtend
Let’s see some code (live demo)
Real-world applicationsIncQuery-Jnect Demo @ ECE 2013
Model train demo 2014-2015
TeqBox: automated game tracking system for TeqBallhttp://teqball.com http://y2u.be/I6XwXy65KPE
ConclusionPointers• http://eclipse.org/viatra• https://wiki.eclipse.org/VIATRA/CEP • https://
github.com/IncQueryLabs/viatra-cep-mqttAcknowledgements• István Dávid (University of Antwerp)• András Vörös, Bálint Hegyi, László Balogh
(BUTE)• István Papp, Ákos Menyhért, Zoltán Selmeczi,
Zsolt Mázló (IncQuery Labs)Thank you for your attention!
Don’t forget to evaluate!
top related