SlideShare a Scribd company logo
TuSoW: Tuple Spaces for Edge Computing
Giovanni Ciatto1 Lorenzo Rizzato1 Andrea Omicini1
Stefano Mariani2
giovanni.ciatto@unibo.it lorenzo.rizzato@studio.unibo.it
andrea.omicini@unibo.it stefano.mariani@unimore.it
1Dipartimento di Informatica โ€“ Scienza e Ingegneriaโ€”Universit`a di Bologna
2Dipartimento di Scienze e Metodi dellโ€™Ingegneria, Universit`a di Modena e Reggio Emilia
1st International Workshop on Edge of Things (EoT)
Valencia, Spain โ€“ August 1, 2019
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 1 / 26
Outline
1 Context & Motivations
2 (Tuple-based) Coordination
3 Our proposal for TbC: the TuSoW project
4 Conclusions and Future Work
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 2 / 26
Context & Motivations
Next in Line. . .
1 Context & Motivations
2 (Tuple-based) Coordination
3 Our proposal for TbC: the TuSoW project
4 Conclusions and Future Work
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 3 / 26
Context & Motivations
Our perspective
In a nutshell
EoT = IoT โˆ’ Cloud
Computation is delegated to edge devices, when possible
In Cloud-based applications
the Cloud acts as a central coordinator
for devices, data, and activities
The coordination problem
! How can edge devices coordinate themselves without the cloud?
! And what is coordination in the ๏ฌrst place?
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 4 / 26
Context & Motivations
Our perspective
In a nutshell
EoT = IoT โˆ’ Cloud
Computation is delegated to edge devices, when possible
In Cloud-based applications
the Cloud acts as a central coordinator
for devices, data, and activities
The coordination problem
! How can edge devices coordinate themselves without the cloud?
! And what is coordination in the ๏ฌrst place?
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 4 / 26
Context & Motivations
Our perspective
In a nutshell
EoT = IoT โˆ’ Cloud
Computation is delegated to edge devices, when possible
In Cloud-based applications
the Cloud acts as a central coordinator
for devices, data, and activities
The coordination problem
! How can edge devices coordinate themselves without the cloud?
! And what is coordination in the ๏ฌrst place?
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 4 / 26
(Tuple-based) Coordination
Next in Line. . .
1 Context & Motivations
2 (Tuple-based) Coordination
3 Our proposal for TbC: the TuSoW project
4 Conclusions and Future Work
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 5 / 26
(Tuple-based) Coordination
What is Coordination?
Within MAS
โ€œA framework in which the interaction of active and independent entities
called agents can be expressedโ€ [Ciancarini, 1996]
active entities like, for instance, EoT devices and clients
interaction i.e., dependencies among computational activities
e.g. communication, cooperation, competition, etc.
expressed i.e., explicitly represented, observed & possibly governed
Takeaway
Coordination studies interaction at the fundamental level
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 6 / 26
(Tuple-based) Coordination
Coordination-as-a-Service [Viroli and Omicini, 2006] as the reference
meta-model
Coordinated
Space
Interaction Space Coordination
Space
Coordinated
Entities
Requests / Responses Coordination
Media
A number of entities
e.g. edge devices
coordinate by means of a
number of media
e.g. other edge devices,
cloud providers, etc
wherewith requests and
response messages are
exchanged
e.g. HTTP, MQTT, etc
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 7 / 26
(Tuple-based) Coordination
Linda [Gelernter, 1985] as the reference model I
1 In Linda coordination media are called tuple spaces
2 They are essentially shared blackboards
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 8 / 26
(Tuple-based) Coordination
Linda [Gelernter, 1985] as the reference model II
3 where clients can write any sort of informationโ€”a.k.a. tuples
according to some representation format of choice
to: Bob, msg: Hello
w
rite
Alice
to: Bob, msg: Hello
4 enabling a feature called generative communication
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 9 / 26
(Tuple-based) Coordination
Linda [Gelernter, 1985] as the reference model III
5 where clients can read all information matching a particular template
according to some query language of choice
to: Bob, msg: Hello
Alice
Bob
read
to: Bob, msg: *
6 enabling a feature called associative access
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 10 / 26
(Tuple-based) Coordination
Linda [Gelernter, 1985] as the reference model IV
7 or take it, making it unavailable for other clients
Alice
Carl
take
to: Carl, msg: Hello
to: Carl, msg: *
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 11 / 26
(Tuple-based) Coordination
Linda [Gelernter, 1985] as the reference model V
8 or take it, making it unavailable for other clients
Alice
Carl
to: Carl, msg: Hello
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 12 / 26
(Tuple-based) Coordination
Linda [Gelernter, 1985] as the reference model VI
What makes Linda di๏ฌ€erent from databases?
Suspensive semantics: read and take operations are suspended if no
tuple is available
Non-determinism: if several tuples are available, read and take
operations choose one, non-deterministically
Reference uncoupling: devices do not need to know (about) each
others
! Such features enable the development of open application
where loosely-coupled clients must interact
such as in the EoT
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 13 / 26
(Tuple-based) Coordination
The problem with Tuple-based Coordination (TbC)
As further discussed in [Ciatto et al., 2018]
TbC is a very well studied research topic
for which several proof of concept implementations have been
provided
coming with as many tuple & template languages
! mostly monolithic, discontinued or inadequate for real world needs
Our claim
Technological limitations are what actually hinders wide adoption of TbC
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 14 / 26
Our proposal for TbC: the TuSoW project
Next in Line. . .
1 Context & Motivations
2 (Tuple-based) Coordination
3 Our proposal for TbC: the TuSoW project
4 Conclusions and Future Work
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 15 / 26
Our proposal for TbC: the TuSoW project
The TuSoW project https://gitlab.com/pika-lab/tuples/coordination
Our proposal
TuSoW is our Linda-based technology focussing on
interoperability
lightweightness
Avoid repeating past errors
Do not commit to any particular
runtime platform (JVM, Python, JS, .NET, etc)
transport protocol (HTTP, MQTT, gRPC)
tuple/template language or matching mechanism
since EoT devices may be leverage on any of them
Design rationale
Design once, port everywhere (with minimal e๏ฌ€ort)
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 16 / 26
Our proposal for TbC: the TuSoW project
The TuSoW project https://gitlab.com/pika-lab/tuples/coordination
Our proposal
TuSoW is our Linda-based technology focussing on
interoperability
lightweightness
Avoid repeating past errors
Do not commit to any particular
runtime platform (JVM, Python, JS, .NET, etc)
transport protocol (HTTP, MQTT, gRPC)
tuple/template language or matching mechanism
since EoT devices may be leverage on any of them
Design rationale
Design once, port everywhere (with minimal e๏ฌ€ort)
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 16 / 26
Our proposal for TbC: the TuSoW project
The TuSoW project https://gitlab.com/pika-lab/tuples/coordination
Our proposal
TuSoW is our Linda-based technology focussing on
interoperability
lightweightness
Avoid repeating past errors
Do not commit to any particular
runtime platform (JVM, Python, JS, .NET, etc)
transport protocol (HTTP, MQTT, gRPC)
tuple/template language or matching mechanism
since EoT devices may be leverage on any of them
Design rationale
Design once, port everywhere (with minimal e๏ฌ€ort)
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 16 / 26
Our proposal for TbC: the TuSoW project
TuSoW โ€“ Layered Perspective
TuSoW Core API
TuSoW Local
Implementation
Transport Layer
TuSoW Core API
TuSoW Remote
Implementation
iOS
Docker
JVM
Library
Linking
(De)Serialization
HTTP
MQTT
gRPC
YAML
XML
JSON
JS
Python
JVM
.NET
iOS
Native
{
{
LocalRemote
Figure: Dashed lines as choice points
Remote impl., supporting
mainstream platforms
General, abstract, shared core API
Presentation layer supporting
various data representation
formats
Transport layer supporting various
protocols
and di๏ฌ€erent applications
Local impl., supporting mobile
devices and containerisation
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 17 / 26
Our proposal for TbC: the TuSoW project
About transport protocols
HTTP targets web-based & general purpose applications
focus on compatibility
gRPC targets mobile devices and smartphones
focus on portability
MQTT targets resource constrained devices (e.g. Raspberries)
focus on lightweightness
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 18 / 26
Our proposal for TbC: the TuSoW project
TuSoW โ€“ Spaces, Tuples, and Templates
core
Tuple Template
TupleSpace Match
domstringslogic
TuSoW
HTTP gRPC
MQTT
implementimplementimplement
wrapwrapwrap
Client
Client_API
implements
uses
Spaces Tuples Templates
textual strings regex
logic logic terms non-ground terms
objects YAML/JSON JsonPath
DOM XML XPath
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 19 / 26
Our proposal for TbC: the TuSoW project
About Tuple Spaces and Tuple/Template languages
Textual spaces target coordination of heterogeneous devices handling
poorly structured data
Logic spaces target coordination intelligent agents prone to symbolic
knowledge processing
Object or DOM spaces target coordination in the Web of Things
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 20 / 26
Our proposal for TbC: the TuSoW project
TuSoW โ€“ Multi-platform concurrency
Di๏ฌ€erent platforms come with di๏ฌ€erent concurrency model
e.g. co-routines on Python & .NET
e.g. Futures or Promises on Java or JavaScript
e.g. callbacks on Node
โ†’ Remote libraries must support the most natural style for each platform
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 21 / 26
Conclusions and Future Work
Next in Line. . .
1 Context & Motivations
2 (Tuple-based) Coordination
3 Our proposal for TbC: the TuSoW project
4 Conclusions and Future Work
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 22 / 26
Conclusions and Future Work
Conclusion & Future Works
Summing up, in this work we
argue Coordination-as-a-Service has a role to play in EoT
present TuSoW as an interoperable technology implementing it
and overcoming current technological limitations
In the future we plan to
extend TuSoW with access control
extend TuSoW with replications, for fault tolerance
provide more high-level API, e.g. for FIPA IP [Oโ€™Brien and Nicol, 1998]
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 23 / 26
Conclusions and Future Work
Conclusion & Future Works
Summing up, in this work we
argue Coordination-as-a-Service has a role to play in EoT
present TuSoW as an interoperable technology implementing it
and overcoming current technological limitations
In the future we plan to
extend TuSoW with access control
extend TuSoW with replications, for fault tolerance
provide more high-level API, e.g. for FIPA IP [Oโ€™Brien and Nicol, 1998]
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 23 / 26
TuSoW: Tuple Spaces for Edge Computing
Giovanni Ciatto1 Lorenzo Rizzato1 Andrea Omicini1
Stefano Mariani2
giovanni.ciatto@unibo.it lorenzo.rizzato@studio.unibo.it
andrea.omicini@unibo.it stefano.mariani@unimore.it
1Dipartimento di Informatica โ€“ Scienza e Ingegneriaโ€”Universit`a di Bologna
2Dipartimento di Scienze e Metodi dellโ€™Ingegneria, Universit`a di Modena e Reggio Emilia
1st International Workshop on Edge of Things (EoT)
Valencia, Spain โ€“ August 1, 2019
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 24 / 26
References
References I
Ciancarini, P. (1996).
Coordination models and languages as software integrators.
ACM Computing Surveys, 28(2):300โ€“302.
Ciatto, G., Mariani, S., Omicini, A., Zambonelli, F., and Louvel, M.
(2018).
Twenty years of coordination technologies: State-of-the-art and
perspectives.
In Di Marzo Serugendo, G. and Loreti, M., editors, Coordination
Models and Languages, volume 10852 of Lecture Notes in Computer
Science, pages 51โ€“80. Springer.
20th IFIP WG 6.1 International Conference, COORDINATION 2018,
Held as Part of the 13th International Federated Conference on
Distributed Computing Techniques, DisCoTec 2018, Madrid, Spain,
June 18-21, 2018. Proceedings.
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 25 / 26
References
References II
Gelernter, D. (1985).
Generative communication in Linda.
ACM Transactions on Programming Languages and Systems,
7(1):80โ€“112.
Oโ€™Brien, P. D. and Nicol, R. C. (1998).
Fipa โ€” towards a standard for software agents.
BT Technology Journal, 16(3):51โ€“59.
Viroli, M. and Omicini, A. (2006).
Coordination as a service.
Fundamenta Informaticae, 73(4):507โ€“534.
Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 26 / 26

More Related Content

PDF
Teaching about AR and Teaching with AR
PPTX
eInfranet cloud services โ€“ current state of affairs
PPTX
Accelerating the Design of Optical Networks using Surrogate Models
ย 
PDF
Simplifying IoT by Solving Software Complexity at the Edge
PDF
Tuple-Based Coordination in Large-Scale Situated Systems
PDF
Novel Opportunities for Tuple-based Coordination: XPath, the Blockchain, and ...
PDF
Distributed edge cloud: empowering the IoT revolution
PDF
The TuCSoN Coordination Model & Technology. A Guide
Teaching about AR and Teaching with AR
eInfranet cloud services โ€“ current state of affairs
Accelerating the Design of Optical Networks using Surrogate Models
ย 
Simplifying IoT by Solving Software Complexity at the Edge
Tuple-Based Coordination in Large-Scale Situated Systems
Novel Opportunities for Tuple-based Coordination: XPath, the Blockchain, and ...
Distributed edge cloud: empowering the IoT revolution
The TuCSoN Coordination Model & Technology. A Guide

Similar to TuSoW: Tuple Spaces for Edge Computing (20)

PPTX
Living on the (IoT) edge (Sam Vanhoutte @TechdaysNL 2017)
ย 
PDF
Coordination of Resource-Constrained Devices through a Distributed Semantic S...
PDF
EDGE COMPUTING: VISION AND CHALLENGES
ย 
PDF
Cooperative hierarchical based edge-computing approach for resources allocati...
PDF
Java Abs Peer To Peer Design & Implementation Of A Tuple Space
ย 
PDF
Java Abs Peer To Peer Design & Implementation Of A Tuple S
ย 
PDF
Device-Edge-Cloud Continuum: Paradigms, Architectures and Applications 1st Ed...
PDF
Air ground integration approach
PDF
Introducing the Open Edge Module
PPTX
IWCI21: Distributed Ledgers for Distributed Edge
PPTX
What-is-Edge-Computing power point presentation
PPTX
Unit-I.pptxsgsggggggggggggggZcvzvzfvzgghszg
PPTX
Unit-I.pptxmbmbmbmbm,b,hkggjfgjfc gvbn mm
PDF
MULTI-ACCESS EDGE COMPUTING ARCHITECTURE AND SMART AGRICULTURE APPLICATION IN...
ย 
PDF
International Journal of Mobile Network Communications & Telematics ( IJMNCT)
ย 
PDF
Message-Oriented Middleware for Edge Computing Applications
PDF
Engineering Resilient Collaborative Edge-enabled IoT
PDF
A SOLUTION FRAMEWORK FOR MANAGING INTERNET OF THINGS (IOT)
DOCX
arXiv1702.05309v2 [cs.I.docx
PDF
Edge ppt
Living on the (IoT) edge (Sam Vanhoutte @TechdaysNL 2017)
ย 
Coordination of Resource-Constrained Devices through a Distributed Semantic S...
EDGE COMPUTING: VISION AND CHALLENGES
ย 
Cooperative hierarchical based edge-computing approach for resources allocati...
Java Abs Peer To Peer Design & Implementation Of A Tuple Space
ย 
Java Abs Peer To Peer Design & Implementation Of A Tuple S
ย 
Device-Edge-Cloud Continuum: Paradigms, Architectures and Applications 1st Ed...
Air ground integration approach
Introducing the Open Edge Module
IWCI21: Distributed Ledgers for Distributed Edge
What-is-Edge-Computing power point presentation
Unit-I.pptxsgsggggggggggggggZcvzvzfvzgghszg
Unit-I.pptxmbmbmbmbm,b,hkggjfgjfc gvbn mm
MULTI-ACCESS EDGE COMPUTING ARCHITECTURE AND SMART AGRICULTURE APPLICATION IN...
ย 
International Journal of Mobile Network Communications & Telematics ( IJMNCT)
ย 
Message-Oriented Middleware for Edge Computing Applications
Engineering Resilient Collaborative Edge-enabled IoT
A SOLUTION FRAMEWORK FOR MANAGING INTERNET OF THINGS (IOT)
arXiv1702.05309v2 [cs.I.docx
Edge ppt
Ad

More from Giovanni Ciatto (12)

PDF
An Abstract Framework for Agent-Based Explanations in AI
PDF
2P-Kt: logic programming with objects & functions in Kotlin
PDF
Towards XMAS: eXplainability through Multi-Agent Systems
PDF
Comparative Analysis of Blockchain Technologies under a Coordination Perspective
PDF
Smart Contracts are More than Objects: Pro-activeness on the Blockchain
PDF
Towards Agent-oriented Blockchains: Autonomous Smart Contracts
PDF
Blockchain and Smart Contracts
PDF
From the Blockchain to Logic Programming and back: Research perspectives
PDF
Logic Programming in Space-Time: The Case of Situatedness in LPaaS
PDF
Blockchain & Smart Contracts Basics and Perspectives for MAS
PDF
A gentle introduction to the Blockchain and Smart Contracts
PDF
Introduzione alla Blockchain
An Abstract Framework for Agent-Based Explanations in AI
2P-Kt: logic programming with objects & functions in Kotlin
Towards XMAS: eXplainability through Multi-Agent Systems
Comparative Analysis of Blockchain Technologies under a Coordination Perspective
Smart Contracts are More than Objects: Pro-activeness on the Blockchain
Towards Agent-oriented Blockchains: Autonomous Smart Contracts
Blockchain and Smart Contracts
From the Blockchain to Logic Programming and back: Research perspectives
Logic Programming in Space-Time: The Case of Situatedness in LPaaS
Blockchain & Smart Contracts Basics and Perspectives for MAS
A gentle introduction to the Blockchain and Smart Contracts
Introduzione alla Blockchain
Ad

Recently uploaded (20)

PDF
๐Ÿ’ฐ ๐”๐Š๐“๐ˆ ๐Š๐„๐Œ๐„๐๐€๐๐†๐€๐ ๐Š๐ˆ๐๐„๐‘๐Ÿ’๐ƒ ๐‡๐€๐‘๐ˆ ๐ˆ๐๐ˆ ๐Ÿ๐ŸŽ๐Ÿ๐Ÿ“ ๐Ÿ’ฐ
ย 
PPTX
Mathew Digital SEO Checklist Guidlines 2025
PDF
Paper PDF World Game (s) Great Redesign.pdf
PPTX
PptxGenJS_Demo_Chart_20250317130215833.pptx
PPTX
SAP Ariba Sourcing PPT for learning material
PPTX
artificialintelligenceai1-copy-210604123353.pptx
ย 
PPTX
artificial intelligence overview of it and more
PPTX
Internet___Basics___Styled_ presentation
PPT
tcp ip networks nd ip layering assotred slides
PPTX
Slides PPTX World Game (s) Eco Economic Epochs.pptx
PPTX
Job_Card_System_Styled_lorem_ipsum_.pptx
PDF
Vigrab.top โ€“ Online Tool for Downloading and Converting Social Media Videos a...
PPTX
Power Point - Lesson 3_2.pptx grad school presentation
ย 
PPTX
Introuction about ICD -10 and ICD-11 PPT.pptx
PDF
An introduction to the IFRS (ISSB) Stndards.pdf
PDF
Automated vs Manual WooCommerce to Shopify Migration_ Pros & Cons.pdf
PPT
Ethics in Information System - Management Information System
PPTX
Digital Literacy And Online Safety on internet
PDF
Cloud-Scale Log Monitoring _ Datadog.pdf
PPT
isotopes_sddsadsaadasdasdasdasdsa1213.ppt
๐Ÿ’ฐ ๐”๐Š๐“๐ˆ ๐Š๐„๐Œ๐„๐๐€๐๐†๐€๐ ๐Š๐ˆ๐๐„๐‘๐Ÿ’๐ƒ ๐‡๐€๐‘๐ˆ ๐ˆ๐๐ˆ ๐Ÿ๐ŸŽ๐Ÿ๐Ÿ“ ๐Ÿ’ฐ
ย 
Mathew Digital SEO Checklist Guidlines 2025
Paper PDF World Game (s) Great Redesign.pdf
PptxGenJS_Demo_Chart_20250317130215833.pptx
SAP Ariba Sourcing PPT for learning material
artificialintelligenceai1-copy-210604123353.pptx
ย 
artificial intelligence overview of it and more
Internet___Basics___Styled_ presentation
tcp ip networks nd ip layering assotred slides
Slides PPTX World Game (s) Eco Economic Epochs.pptx
Job_Card_System_Styled_lorem_ipsum_.pptx
Vigrab.top โ€“ Online Tool for Downloading and Converting Social Media Videos a...
Power Point - Lesson 3_2.pptx grad school presentation
ย 
Introuction about ICD -10 and ICD-11 PPT.pptx
An introduction to the IFRS (ISSB) Stndards.pdf
Automated vs Manual WooCommerce to Shopify Migration_ Pros & Cons.pdf
Ethics in Information System - Management Information System
Digital Literacy And Online Safety on internet
Cloud-Scale Log Monitoring _ Datadog.pdf
isotopes_sddsadsaadasdasdasdasdsa1213.ppt

TuSoW: Tuple Spaces for Edge Computing

  • 1. TuSoW: Tuple Spaces for Edge Computing Giovanni Ciatto1 Lorenzo Rizzato1 Andrea Omicini1 Stefano Mariani2 giovanni.ciatto@unibo.it lorenzo.rizzato@studio.unibo.it andrea.omicini@unibo.it stefano.mariani@unimore.it 1Dipartimento di Informatica โ€“ Scienza e Ingegneriaโ€”Universit`a di Bologna 2Dipartimento di Scienze e Metodi dellโ€™Ingegneria, Universit`a di Modena e Reggio Emilia 1st International Workshop on Edge of Things (EoT) Valencia, Spain โ€“ August 1, 2019 Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 1 / 26
  • 2. Outline 1 Context & Motivations 2 (Tuple-based) Coordination 3 Our proposal for TbC: the TuSoW project 4 Conclusions and Future Work Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 2 / 26
  • 3. Context & Motivations Next in Line. . . 1 Context & Motivations 2 (Tuple-based) Coordination 3 Our proposal for TbC: the TuSoW project 4 Conclusions and Future Work Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 3 / 26
  • 4. Context & Motivations Our perspective In a nutshell EoT = IoT โˆ’ Cloud Computation is delegated to edge devices, when possible In Cloud-based applications the Cloud acts as a central coordinator for devices, data, and activities The coordination problem ! How can edge devices coordinate themselves without the cloud? ! And what is coordination in the ๏ฌrst place? Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 4 / 26
  • 5. Context & Motivations Our perspective In a nutshell EoT = IoT โˆ’ Cloud Computation is delegated to edge devices, when possible In Cloud-based applications the Cloud acts as a central coordinator for devices, data, and activities The coordination problem ! How can edge devices coordinate themselves without the cloud? ! And what is coordination in the ๏ฌrst place? Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 4 / 26
  • 6. Context & Motivations Our perspective In a nutshell EoT = IoT โˆ’ Cloud Computation is delegated to edge devices, when possible In Cloud-based applications the Cloud acts as a central coordinator for devices, data, and activities The coordination problem ! How can edge devices coordinate themselves without the cloud? ! And what is coordination in the ๏ฌrst place? Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 4 / 26
  • 7. (Tuple-based) Coordination Next in Line. . . 1 Context & Motivations 2 (Tuple-based) Coordination 3 Our proposal for TbC: the TuSoW project 4 Conclusions and Future Work Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 5 / 26
  • 8. (Tuple-based) Coordination What is Coordination? Within MAS โ€œA framework in which the interaction of active and independent entities called agents can be expressedโ€ [Ciancarini, 1996] active entities like, for instance, EoT devices and clients interaction i.e., dependencies among computational activities e.g. communication, cooperation, competition, etc. expressed i.e., explicitly represented, observed & possibly governed Takeaway Coordination studies interaction at the fundamental level Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 6 / 26
  • 9. (Tuple-based) Coordination Coordination-as-a-Service [Viroli and Omicini, 2006] as the reference meta-model Coordinated Space Interaction Space Coordination Space Coordinated Entities Requests / Responses Coordination Media A number of entities e.g. edge devices coordinate by means of a number of media e.g. other edge devices, cloud providers, etc wherewith requests and response messages are exchanged e.g. HTTP, MQTT, etc Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 7 / 26
  • 10. (Tuple-based) Coordination Linda [Gelernter, 1985] as the reference model I 1 In Linda coordination media are called tuple spaces 2 They are essentially shared blackboards Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 8 / 26
  • 11. (Tuple-based) Coordination Linda [Gelernter, 1985] as the reference model II 3 where clients can write any sort of informationโ€”a.k.a. tuples according to some representation format of choice to: Bob, msg: Hello w rite Alice to: Bob, msg: Hello 4 enabling a feature called generative communication Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 9 / 26
  • 12. (Tuple-based) Coordination Linda [Gelernter, 1985] as the reference model III 5 where clients can read all information matching a particular template according to some query language of choice to: Bob, msg: Hello Alice Bob read to: Bob, msg: * 6 enabling a feature called associative access Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 10 / 26
  • 13. (Tuple-based) Coordination Linda [Gelernter, 1985] as the reference model IV 7 or take it, making it unavailable for other clients Alice Carl take to: Carl, msg: Hello to: Carl, msg: * Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 11 / 26
  • 14. (Tuple-based) Coordination Linda [Gelernter, 1985] as the reference model V 8 or take it, making it unavailable for other clients Alice Carl to: Carl, msg: Hello Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 12 / 26
  • 15. (Tuple-based) Coordination Linda [Gelernter, 1985] as the reference model VI What makes Linda di๏ฌ€erent from databases? Suspensive semantics: read and take operations are suspended if no tuple is available Non-determinism: if several tuples are available, read and take operations choose one, non-deterministically Reference uncoupling: devices do not need to know (about) each others ! Such features enable the development of open application where loosely-coupled clients must interact such as in the EoT Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 13 / 26
  • 16. (Tuple-based) Coordination The problem with Tuple-based Coordination (TbC) As further discussed in [Ciatto et al., 2018] TbC is a very well studied research topic for which several proof of concept implementations have been provided coming with as many tuple & template languages ! mostly monolithic, discontinued or inadequate for real world needs Our claim Technological limitations are what actually hinders wide adoption of TbC Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 14 / 26
  • 17. Our proposal for TbC: the TuSoW project Next in Line. . . 1 Context & Motivations 2 (Tuple-based) Coordination 3 Our proposal for TbC: the TuSoW project 4 Conclusions and Future Work Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 15 / 26
  • 18. Our proposal for TbC: the TuSoW project The TuSoW project https://gitlab.com/pika-lab/tuples/coordination Our proposal TuSoW is our Linda-based technology focussing on interoperability lightweightness Avoid repeating past errors Do not commit to any particular runtime platform (JVM, Python, JS, .NET, etc) transport protocol (HTTP, MQTT, gRPC) tuple/template language or matching mechanism since EoT devices may be leverage on any of them Design rationale Design once, port everywhere (with minimal e๏ฌ€ort) Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 16 / 26
  • 19. Our proposal for TbC: the TuSoW project The TuSoW project https://gitlab.com/pika-lab/tuples/coordination Our proposal TuSoW is our Linda-based technology focussing on interoperability lightweightness Avoid repeating past errors Do not commit to any particular runtime platform (JVM, Python, JS, .NET, etc) transport protocol (HTTP, MQTT, gRPC) tuple/template language or matching mechanism since EoT devices may be leverage on any of them Design rationale Design once, port everywhere (with minimal e๏ฌ€ort) Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 16 / 26
  • 20. Our proposal for TbC: the TuSoW project The TuSoW project https://gitlab.com/pika-lab/tuples/coordination Our proposal TuSoW is our Linda-based technology focussing on interoperability lightweightness Avoid repeating past errors Do not commit to any particular runtime platform (JVM, Python, JS, .NET, etc) transport protocol (HTTP, MQTT, gRPC) tuple/template language or matching mechanism since EoT devices may be leverage on any of them Design rationale Design once, port everywhere (with minimal e๏ฌ€ort) Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 16 / 26
  • 21. Our proposal for TbC: the TuSoW project TuSoW โ€“ Layered Perspective TuSoW Core API TuSoW Local Implementation Transport Layer TuSoW Core API TuSoW Remote Implementation iOS Docker JVM Library Linking (De)Serialization HTTP MQTT gRPC YAML XML JSON JS Python JVM .NET iOS Native { { LocalRemote Figure: Dashed lines as choice points Remote impl., supporting mainstream platforms General, abstract, shared core API Presentation layer supporting various data representation formats Transport layer supporting various protocols and di๏ฌ€erent applications Local impl., supporting mobile devices and containerisation Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 17 / 26
  • 22. Our proposal for TbC: the TuSoW project About transport protocols HTTP targets web-based & general purpose applications focus on compatibility gRPC targets mobile devices and smartphones focus on portability MQTT targets resource constrained devices (e.g. Raspberries) focus on lightweightness Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 18 / 26
  • 23. Our proposal for TbC: the TuSoW project TuSoW โ€“ Spaces, Tuples, and Templates core Tuple Template TupleSpace Match domstringslogic TuSoW HTTP gRPC MQTT implementimplementimplement wrapwrapwrap Client Client_API implements uses Spaces Tuples Templates textual strings regex logic logic terms non-ground terms objects YAML/JSON JsonPath DOM XML XPath Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 19 / 26
  • 24. Our proposal for TbC: the TuSoW project About Tuple Spaces and Tuple/Template languages Textual spaces target coordination of heterogeneous devices handling poorly structured data Logic spaces target coordination intelligent agents prone to symbolic knowledge processing Object or DOM spaces target coordination in the Web of Things Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 20 / 26
  • 25. Our proposal for TbC: the TuSoW project TuSoW โ€“ Multi-platform concurrency Di๏ฌ€erent platforms come with di๏ฌ€erent concurrency model e.g. co-routines on Python & .NET e.g. Futures or Promises on Java or JavaScript e.g. callbacks on Node โ†’ Remote libraries must support the most natural style for each platform Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 21 / 26
  • 26. Conclusions and Future Work Next in Line. . . 1 Context & Motivations 2 (Tuple-based) Coordination 3 Our proposal for TbC: the TuSoW project 4 Conclusions and Future Work Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 22 / 26
  • 27. Conclusions and Future Work Conclusion & Future Works Summing up, in this work we argue Coordination-as-a-Service has a role to play in EoT present TuSoW as an interoperable technology implementing it and overcoming current technological limitations In the future we plan to extend TuSoW with access control extend TuSoW with replications, for fault tolerance provide more high-level API, e.g. for FIPA IP [Oโ€™Brien and Nicol, 1998] Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 23 / 26
  • 28. Conclusions and Future Work Conclusion & Future Works Summing up, in this work we argue Coordination-as-a-Service has a role to play in EoT present TuSoW as an interoperable technology implementing it and overcoming current technological limitations In the future we plan to extend TuSoW with access control extend TuSoW with replications, for fault tolerance provide more high-level API, e.g. for FIPA IP [Oโ€™Brien and Nicol, 1998] Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 23 / 26
  • 29. TuSoW: Tuple Spaces for Edge Computing Giovanni Ciatto1 Lorenzo Rizzato1 Andrea Omicini1 Stefano Mariani2 giovanni.ciatto@unibo.it lorenzo.rizzato@studio.unibo.it andrea.omicini@unibo.it stefano.mariani@unimore.it 1Dipartimento di Informatica โ€“ Scienza e Ingegneriaโ€”Universit`a di Bologna 2Dipartimento di Scienze e Metodi dellโ€™Ingegneria, Universit`a di Modena e Reggio Emilia 1st International Workshop on Edge of Things (EoT) Valencia, Spain โ€“ August 1, 2019 Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 24 / 26
  • 30. References References I Ciancarini, P. (1996). Coordination models and languages as software integrators. ACM Computing Surveys, 28(2):300โ€“302. Ciatto, G., Mariani, S., Omicini, A., Zambonelli, F., and Louvel, M. (2018). Twenty years of coordination technologies: State-of-the-art and perspectives. In Di Marzo Serugendo, G. and Loreti, M., editors, Coordination Models and Languages, volume 10852 of Lecture Notes in Computer Science, pages 51โ€“80. Springer. 20th IFIP WG 6.1 International Conference, COORDINATION 2018, Held as Part of the 13th International Federated Conference on Distributed Computing Techniques, DisCoTec 2018, Madrid, Spain, June 18-21, 2018. Proceedings. Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 25 / 26
  • 31. References References II Gelernter, D. (1985). Generative communication in Linda. ACM Transactions on Programming Languages and Systems, 7(1):80โ€“112. Oโ€™Brien, P. D. and Nicol, R. C. (1998). Fipa โ€” towards a standard for software agents. BT Technology Journal, 16(3):51โ€“59. Viroli, M. and Omicini, A. (2006). Coordination as a service. Fundamenta Informaticae, 73(4):507โ€“534. Ciatto et al. (UniBo, UniMoRe) Tuple Spaces for Edge Computing EoT 2019, Aug 1 26 / 26