architectural design rewriting
play

Architectural Design Rewriting R. Bruni 1 , A. Lluch Lafuente 1 , U. - PowerPoint PPT Presentation

Architectural Design Rewriting R. Bruni 1 , A. Lluch Lafuente 1 , U. Montanari 1 , E. Tuosto 2 Department of Computer Science, University of Pisa { bruni,lafuente,ugo } @di.unipi.it Department of Computer Science, University of Leicester


  1. Architectural Design Rewriting R. Bruni 1 , A. Lluch Lafuente 1 , U. Montanari 1 , E. Tuosto 2 Department of Computer Science, University of Pisa { bruni,lafuente,ugo } @di.unipi.it Department of Computer Science, University of Leicester et52@mcs.le.ac.uk 1st CWI-DIPisa Workshop on Coordination, Coalgebras and Constraints Pisa, January 21-23, 2008 Architectural Design Rewriting 1/17

  2. The story SarA is a Software Architect. She develops software architectures with features such as style-conformance and dynamic reconfiguration. She meets AnDRea, a formal methodist, working on Architectural Design Rewriting. Architectural Design Rewriting 2/17

  3. Software Architectures, Graphs SarA: I need to design filter architectures. Some sort of pipelines that can be put in sequence or in parallel. Things like this diagram: AnDRea: I would call it a graph : components/connectors are hyperedges (boxes), ports/roles are tentacles (arrows), and attachments are nodes (circles). Architectural Design Rewriting 3/17

  4. Architectural Styles, Graph Grammars SarA: I need a mechanism to build configurations in that style to avoid cyclic or broken flows. AnDRea: A graph grammar provides you a style-consistent refinement process. For instance, this rule lets you refine a filter as a sequential composition of filters: Architectural Design Rewriting 4/17

  5. Architectural Styles, From Grammars to Algebras SarA: But I also need to compose designs. AnDRea: You can use a right-to-left algebraic reading of the grammar. For instance, production rule now becomes operation ( design production ) Architectural Design Rewriting 5/17

  6. An operation? AnDRea: In your algebra... the sort is FILTER , an edge exposing two nodes, domain are designs - graphs with interfaces - of sort FILTER , an operation is like a design, where some edges are arguments, and substitution means hyperedge replacement . SarA prefers to skip such technical details. Architectural Design Rewriting 6/17

  7. More productions: parallel filters SarA: Filters can be put in parallel, with suitable components to dispatch and collect messages. AnDRea draws... Architectural Design Rewriting 7/17

  8. More productions: empty and single filters SarA: I also need single filters and empty filters. AnDRea draws... Architectural Design Rewriting 8/17

  9. All productions AnDRea shows the whole picture... Architectural Design Rewriting 9/17

  10. Interpreting a term SarA: Show me an example, please. AnDRea draws. seq(filter1,par(filter2,filter3)) Architectural Design Rewriting 10/17

  11. Interpreting a term SarA: Show me an example, please. AnDRea draws. seq(filter1,par(filter2,filter3)) Architectural Design Rewriting 10/17

  12. Interpreting a term SarA: Show me an example, please. AnDRea draws. seq(filter1,par(filter2,filter3)) Architectural Design Rewriting 10/17

  13. Interpreting a term SarA: Show me an example, please. AnDRea draws. seq(filter1,par(filter2,filter3)) Architectural Design Rewriting 10/17

  14. Interpreting a term SarA: Show me an example, please. AnDRea draws. seq(filter1,par(filter2,filter3)) Architectural Design Rewriting 10/17

  15. Reconfigurations SarA: I also need a mechanism to manipulate configurations: to swap any sequence of filters or to serialise any parallel composition. AnDRea: You can use graph transformation rules. SarA: I don’t want to obtain things like unconnected filters. Is style preservation guaranteed by such rules? AnDRea: You need to proof them style consistent with a theorem or using a semi-decidable procedure or... SarA: Or? AnDRea: You define rules at the level of terms, exploiting the structure they introduce. Architectural Design Rewriting 11/17

  16. Swapping filters SarA: Show me how to swap filters, please. AnDRea writes and draws... seq(x1,x2) -> seq(x2,x1) Architectural Design Rewriting 12/17

  17. Swapping filters SarA: How can I reconfigure a sequence of three filters? AnDRea: Rule seq(x1,x2) -> seq(x2,x1) has different instances: seq(filter1,filter2,filter3) -> seq(filter1,filter3,filter2) Hint: seq is associative, seq(filter1,seq(filter2,filter3)) = seq(seq(filter1,filter2),filter3) Architectural Design Rewriting 13/17

  18. Swapping filters SarA: How can I reconfigure a sequence of three filters? AnDRea: Rule seq(x1,x2) -> seq(x2,x1) has different instances: seq(filter1,filter2,filter3) -> seq(filter1,filter3,filter2) seq(filter1,filter2,filter3) -> seq(filter2,filter3,filter1) Hint: seq is associative, seq(filter1,seq(filter2,filter3)) = seq(seq(filter1,filter2),filter3) Architectural Design Rewriting 13/17

  19. Swapping filters SarA: How can I reconfigure a sequence of three filters? AnDRea: Rule seq(x1,x2) -> seq(x2,x1) has different instances: seq(filter1,filter2,filter3) -> seq(filter1,filter3,filter2) seq(filter1,filter2,filter3) -> seq(filter2,filter3,filter1) seq(filter1,filter2,filter3) -> seq(filter2,filter1,filter3) Hint: seq is associative, seq(filter1,seq(filter2,filter3)) = seq(seq(filter1,filter2),filter3) Architectural Design Rewriting 13/17

  20. Swapping filters SarA: How can I reconfigure a sequence of three filters? AnDRea: Rule seq(x1,x2) -> seq(x2,x1) has different instances: seq(filter1,filter2,filter3) -> seq(filter1,filter3,filter2) seq(filter1,filter2,filter3) -> seq(filter2,filter3,filter1) seq(filter1,filter2,filter3) -> seq(filter2,filter1,filter3) seq(filter1,filter2,filter3) -> seq(filter3,filter1,filter2) Hint: seq is associative, seq(filter1,seq(filter2,filter3)) = seq(seq(filter1,filter2),filter3) Architectural Design Rewriting 13/17

  21. Serialisation SarA: And how are parallel filters serialised? AnDRea writes and draws... par(x1,x2) -> seq(x1,x2) Architectural Design Rewriting 14/17

  22. Propagated Serialisation SarA: I need serialisation to be propagated... AnDRea: Conditional labelled rules do the job AnDRea: Other rules are needed to propagate and stop the propagation. Architectural Design Rewriting 15/17

  23. Propagated Serialisation SarA: Show me an example, please. AnDRea draws... Architectural Design Rewriting 16/17

  24. Architectural Design Rewriting SarA: What is ADR? Algebra of graphs with interfaces (designs). Conditional, labelled rewrite rules on design terms. SarA: What can I do with ADR? Algebra = architectural style, metamodel, graphical encoding. Rewrite rules = reconfiguration, dynamic binding, ordinary execution. SarA: What is the status of ADR? Other domains of interpretation: constraints? Specification and Verification: e.g. exploiting the structure. Prototypical implementation in Maude. SarA: Where can I get more information on ADR? www.albertolluch.com/adr.html . Architectural Design Rewriting 17/17

  25. Epilogue SarA: What about Coordination? Coalgebras? Constraints? AnDRea: Let’s talk about it later. Let’s say... at dinner? Architectural Design Rewriting 18/17

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend