on supporting contract-aware iot dataspace services
TRANSCRIPT
On Supporting Contract-aware IoT
Dataspace Services
Florin Bogdan Balint & Hong-Linh Truong
Distributed Systems Group, TU Wien
http://rdsea.github.io
Mobile Cloud 2017, 7-9 April, 2017 1
Outline
Motivation
IoT data contract
Contract-aware IoT Framework
Contract monitoring
Prototype & Evaluation
Conclusions and Future Work
2Mobile Cloud 2017, 7-9 April, 2017
Our view
Several providers provide IoT data produced by their IoT devices
non-personal data: environmental data in smart cities, e.g., air temperature, and carbon monoxide concentration
IoT device providers provide information about their devices.
Users are prepared to negotiate a data contract for data produced by Things.
3Mobile Cloud 2017, 7-9 April, 2017
Convincing reasons?
IoT Network-as-a-Service enables multiple
stakeholders to bring their own IoT data
sources: devices and gateways
Mobile Cloud 2017, 7-9 April, 2017 4
Convincing reason?
Many stakeholders only
want to buy the data Lobster farms in a seawater
bay
Farmers require IoT
data/infrastructure, edge
server and cloud resources
as a service
Other examples
Government provides
data about city, water,
etc.
Mobile Cloud 2017, 7-9 April, 2017 5
Figure source: from Tran-Vu Pham,
Bach Khoa Uni., VN
Motivation
Several platforms facilitate data purchasing and selling but
No data contract
Limited data contract design: not possible to establish individual data contracts
Challenges
Technical problems: 1 Data Contract established for 1 to X Things, which produce data with 1 to Y ≤ X different structures, that is published at 1 to Z ≤ X different frequencies.
Governance problems: liability, warranty, etc.
Mobile Cloud 2017, 7-9 April, 2017 6
Data contracts
Leveraged previous work on data contracts for data-as-a-service
Data Contracts: possible data contractual terms
Data Rights: Derivation, Collection, Reproduction, Commercial Usage
Quality of Data (QoD): Completeness, Conformity, Average Message Age, Average Message Currency
Quality of Service (QoS): Availability
Pricing: Price, Subscription Period
Purchasing Policy: Contract Termination, Shipping, Refund
Control and Relationship: Warranty, Indemnity, Liability, Jurisdiction
7Mobile Cloud 2017, 7-9 April, 2017
Hong Linh Truong, Marco Comerio, Flavio De Paoli, G. R. Gangadharan, Schahram Dustdar: Data contracts for
cloud-based data marketplaces. IJCSE 7(4): 280-295 (2012)
IoT Data Space & Contract
Nowadays the space can be established by using
many IoT datahub (e.g. Google, Azure, etc.)
Mobile Cloud 2017, 7-9 April, 2017 8
Interactions in contract-aware IoT
data
Mobile Cloud 2017, 7-9 April, 2017 9
The detail of establishment contract/contract negotiation is in the paper
IoT data contract
Mobile Cloud 2017, 7-9 April, 2017 10
{
"_id":
"57f57a770a975a2cc7f52cc5",
"metaInfo": {
"contractId": "...",
"creationDate": "2016-10-06
00:11:03",
"active": false,
"party1Accepted": true,
"party2Accepted": true,
"revision": 4,
"party1Id": "...",
"party2Id": "..."
},
"dataRights": {
"derivation": true,
"collection": true,
"reproduction": false,
"commercialUsage": false
},
"pricingModel": {
"price": 3,
"currency": "EUR",
"transaction": false,
"numberOfTransactions": null,
"subscription": {
"startDate": "2016-10-07 00:00:00",
"endDate": "2016-10-08 00:00:00" }
},
"controlAndRelationship": {
"warranty": "None",
"indemnity": "None",
"liability": "None",
"jurisdiction": "AustriaVienna"
},
"purchasingPolicy": {
"contractTermination": "Automatic",
"shipping": "Automatic",
"refund": "None"
},
"thingIds": [{"thingId": "...",}, ...]
}
IoT Data Contract Design
Mobile Cloud 2017, 7-9 April, 2017 11
Extensible Contract-aware Framework Architecture
Mobile Cloud 2017, 7-9 April, 2017 12
Data Contract Monitoring
Things publish data to message brokers / queues
Published messages have a custom property set, e.g., ThingID
Meta-Model of a Thing’s produced messages is known
Message consumption from queue
Message redirection to subscribers
Based on meta-model
QoD: Completeness, Conformity, Avg. Age, Avg. Currency
QoS: Availability
13Mobile Cloud 2017, 7-9 April, 2017
Mobile Cloud 2017, 7-9 April, 2017 14
In the design:
using different
plug-ins for
QoD/QoS
evaluation
Mobile Cloud 2017, 7-9 April, 2017 15
QoS check can
be based on
sampling
Prototype
Open source in github
https://github.com/e0725439/idac
Contract management using MongoDB
IoT data hub and queue:
Apache ActiveMQ
Using MQTT protocol
Services are developed by using Apache Camel
Microservice principles
Mobile Cloud 2017, 7-9 April, 2017 16
Illustrating Examples
Mobile Cloud 2017, 7-9 April, 2017 17
Illustrating Examples
Mobile Cloud 2017, 7-9 April, 2017 18
Illustrating Examples
Mobile Cloud 2017, 7-9 April, 2017 19
Illustrating Examples
Mobile Cloud 2017, 7-9 April, 2017 20
Performance Evaluation
Data
Temperature sensor: DS18B20 connected to Raspberry Pi
Emulated device: water quality sampling data from City of Austin (https://data.austintexas.gov/Environmental/Water-
Quality-Sampling-Data/5tye-7ray)
Emulated device: mobile device measurements obtained with OpenSignal
Systems – intentionally limited
Windows 10 / Kernel 64-bit, Intel(R) Core(TM) i3 M370 @ 2.00GHz, 2 Cores , 8 GB RAM
21Mobile Cloud 2017, 7-9 April, 2017
Performance Evaluation
Mobile Cloud 2017, 7-9 April, 2017 22
Type of Thing Number of
Things
Messages
per Things
Broadcasting
frequency (ms)
Qos/qod
Computation
Time (ms)
Temperature
sensor
100 100 100 1.46
Temperature
sensor
100 100 1000 1.07
Water quality 100 100 100 1.38
Water quality 100 100 1000 1.01
Opensignal 100 100 100 1.77
Opensignal 100 100 1000 1.20
Direct test by calling components without queue
Performance Evaluation
Mobile Cloud 2017, 7-9 April, 2017 23
High overhead if we want “exact” monitoring: Overhead (M) ranges from
approx. 32% to approx. 38%.
For each type of things:
4 tests were conducted.
Per case: 10 or 20
Things broadcasted data
to either one or two
message queues
In all cases each Thing
was bound to a different
data contract
all Things a minimum
number of 1000
messages were
consumed
Multiple tests with data through queues
Conclusions and Future Work
Conclusions IoT data-as-a-service can be built based on multiple IoT
providers
IoT data contract is an important issue: business and
compliance purposes
We have introduced a scalable framework for IoT data contract
Future work Push further for implementation and experiments
Integrate with real-world data hub: Google/Azure/Amazon
Integrate with Thing Information Management Services
http://sincconcept.github.io/HINC/
Plug-ins/microservices for enforcing different contract terms
Secured deliverable data based on contracts
Mobile Cloud 2017, 7-9 April, 2017 24
Thanks for your
attention!
Questions?
Hong-Linh Truong
Distributed Systems GroupTU Wien
dsg.tuwien.ac.at/staff/truong
Mobile Cloud 2017, 7-9 April, 2017 25