Plug-in Development for the Open Source AADL Tool Environment Part 4: OSATE Infrastructure & Language Extensions

Similar documents
Plug-in Development for the Open Source AADL Tool Environment Part 3: Generation & External Models

Error Model Meta Model and Plug-in

An Implementation of the Behavior Annex in the AADL-toolset Osate2

Plug-in Development for the Open Source AADL Tool Environment Part 2: Plug-in Development Process

Investigation of System Timing Concerns in Embedded Systems: Tool-based Analysis of AADL Models

AADL Meta Model & XML/XMI

AADL Graphical Editor Design

An Extensible Open Source AADL Tool Environment (OSATE)

An Extensible Open Source AADL Tool Environment (OSATE)

UML&AADL 11 An Implementation of the Behavior Annex in the AADL-toolset OSATE2

Query Language for AADLv2, Jérôme Hugues, ISAE Serban Gheorghe, Edgewater

Presentation of the AADL: Architecture Analysis and Design Language

Presentation of the AADL: Architecture Analysis and Design Language

An implementation of the AADL-BA Behavior Annex front-end: an OSATE2 Eclipse plug-in

OSATE Analysis Support

AEROSPACE STANDARD. SAE Architecture Analysis and Design Language (AADL) Annex Volume 3: Annex E: Error Model Annex RATIONALE

AADL v2.1 errata AADL meeting Sept 2014

Error Model Annex Revision

Introduction to AADL analysis and modeling with FACE Units of Conformance

Analysis and Design Language (AADL) for Quantitative System Reliability and Availability Modeling

SAE AADL Error Model Annex: Discussion Items

Dependability Modeling Based on AADL Description (Architecture Analysis and Design Language)

EMFT 1.0 Release Review (OCL, Query, Transaction, and Validation)

The Ocarina Tool Suite. Thomas Vergnaud

A System Dependability Modeling Framework Using AADL and GSPNs

Flow Latency Analysis with the Architecture Analysis and Design Language (AADL)

Pattern-Based Analysis of an Embedded Real-Time System Architecture

An EMF Framework for Event-B

Weiss Chapter 1 terminology (parenthesized numbers are page numbers)

Think of drawing/diagramming editors. ECE450 Software Engineering II. The problem. The Composite pattern

Teiid Designer User Guide 7.5.0

Capturing Middleware using UML Models.

Copyright 2018 Adventium Labs. 1

AADS+: AADL Simulation including the Behavioral Annex

The Strategy Pattern Design Principle: Design Principle: Design Principle:

An Information Model for High-Integrity Real Time Systems

Dominique Blouin Etienne Borde

The Montana Toolset: OSATE Plugins for Analysis and Code Generation

COPYRIGHTED MATERIAL. Table of Contents. Foreword... xv. About This Book... xvii. About The Authors... xxiii. Guide To The Reader...

Teiid Designer User Guide 7.7.0

Design Document Overview

ADeS presentation. a simulator for AADL v Amélie Schyn Romain Sezestre Jean-François Tilman

Model handling with EMF

Methods and Tools for Embedded Distributed System Timing and Safety Analysis. Steve Vestal Honeywell Labs

Design Patterns. SE3A04 Tutorial. Jason Jaskolka

What Every Xtext User Wished to Know Industry Experience of Implementing 80+ DSLs

CSSE 490 Model-Based Software Engineering: Architecture Description Languages (ADL)

CSCD01 Engineering Large Software Systems. Design Patterns. Joe Bettridge. Winter With thanks to Anya Tafliovich

AADL Fault Modeling and Analysis Within an ARP4761 Safety Assessment

AADL Generative Implementation Annex

CSCI Object Oriented Design: Frameworks and Design Patterns George Blankenship. Frameworks and Design George Blankenship 1

1Z0-560 Oracle Unified Business Process Management Suite 11g Essentials

The Architecture Analysis and Design Language and the Behavior Annex: A Denotational Semantics

Topics in Object-Oriented Design Patterns

On 17 June 2006, the editor provided the following list via an to the convener:

CISC836: Models in Software Development: Methods, Techniques and Tools

Automatic Generation of Static Fault Trees from AADL Models

EPL 603 TOPICS IN SOFTWARE ENGINEERING. Lab 6: Design Patterns

object/relational persistence What is persistence? 5

Lecture 7: Type Systems and Symbol Tables. CS 540 George Mason University

Contents. Figures. Tables. Examples. Foreword. Preface. 1 Basics of Java Programming 1. xix. xxi. xxiii. xxvii. xxix

Kerievsky_book.fm Page 355 Thursday, July 8, :12 PM. Index

C# 6.0 in a nutshell / Joseph Albahari & Ben Albahari. 6th ed. Beijin [etc.], cop Spis treści

AbstractCommand, AbstractEnumerator, AbstractOverrideableCommand, AddCommand, AbstractTreeIterator, Adapter, EAnnotation.

Workshop 1: Specification for SystemC-AADL interoperability

Socket attaches to a Ratchet. 2) Bridge Decouple an abstraction from its implementation so that the two can vary independently.

Programming in Scala Second Edition

ModelicaML: Getting Started Issue April 2012

Outline. Java Models for variables Types and type checking, type safety Interpretation vs. compilation. Reasoning about code. CSCI 2600 Spring

Business-Driven Software Engineering Lecture 5 Business Process Model and Notation

JDT Plug in Developer Guide. Programmer's Guide

BEAAquaLogic. Service Bus. Interoperability With EJB Transport

Software Design Patterns. Background 1. Background 2. Jonathan I. Maletic, Ph.D.

Tiger EMF Model Transformation Framework (EMT)

CIS 890: High-Assurance Systems

Architecture Description Languages. Peter H. Feiler 1, Bruce Lewis 2, Steve Vestal 3 and Ed Colbert 4

AADL Inspector Tutorial. ACVI Workshop, Valencia September 29th, Pierre Dissaux. Ellidiss. Technologies w w w. e l l i d i s s.

H2 Spring B. We can abstract out the interactions and policy points from DoDAF operational views

When Modeling meets Productivity. Sven Efftinge - itemis

AEROSPACE STANDARD. SAE Architecture Analysis and Design Language (AADL) Annex Volume 3: Annex E: Error Model Annex RATIONALE

Eclipse Modeling Framework (EMF) Paweł Żalejko

PATTERN-ORIENTED SOFTWARE ARCHITECTURE

Architecture Analysis and Design Language (AADL) Part 2

ADT: Eclipse development tools for ATL

Peer-to-Peer Architectures and the Magi Open-Source Infrastructure

Using UML To Define XML Document Types

UML PROFILING AND DSL

Comparing graphical DSL editors

Java for Programmers Course (equivalent to SL 275) 36 Contact Hours

Institut Supérieur de l Aéronautique et de l Espace Constraints Annex Implementation Approach

RAMSES. Refinement of AADL Models for the Synthesis of Embedded Systems. Etienne Borde

Metamodeling. Janos Sztipanovits ISIS, Vanderbilt University

Dominique Blouin Etienne Borde

Schedulability Analysis of AADL Models

AADL Simulation and Performance Analysis in SystemC

BPS BIRT General Designer Usability Improvements Specification

Content Sharing and Reuse in PTC Integrity Lifecycle Manager

Object-Oriented Design

The New Generation of the Eclipse Platform. Budapesti Műszaki és Gazdaságtudományi Egyetem Méréstechnika és Információs Rendszerek Tanszék

foreword to the first edition preface xxi acknowledgments xxiii about this book xxv about the cover illustration

Transcription:

Plug-in Development for the Open Source AADL Tool Environment Part 4: OSATE Infrastructure & Language Extensions Peter Feiler / Aaron Greenhouse/ Lutz Wrage Software Engineering Institute (phf / aarong/ lwrage)@sei.cmu.edu 412-268- (7790 / 6464 / 7771 ) OSATE Plug-in Development Series Introduction to OSATE Plug-in Development OSATE capabilities & plug-in architecture AADL Meta model & example plug-in OSATE Plug-in Development Process Plug-in development design approach Model traversal & AADL properties Analysis plug-ins & result management Interfacing with Existing Models & Tools Declarative & instance models Generation & external representations OSATE Infrastructure & API Persistence Modal system models Sublanguage extensions 2

Persistent AADL models Multi-file Support Modal system models Sublanguage extensions Outline 3 Tool Interoperability Textual AADL Parser Co-resident model AADL XML Interchange AADL Front-end Name Resolution Semantic Checking Declarative AADL Model AADL Instance Model Persistent XML document Convert Tool-specific XML Representation Graphical Layout Model Graphical AADL Graphical View Convert Tool-specific representation 4

Persistence in OSATE Eclipse Files & IResources Eclipse Modeling Framework XML, resources, resource sets OSATE resource manager 5 Persistence in Eclipse Files & IResources IResource-based navigation IResources with temporary and persistent markers & attributes Synchronization between files and IResources IResource delta & change propagation 6

Eclipse Resource Navigator Eclipse Navigator File system 7 Resource Markers Marker decorators Marker locations Filtered marker viewing 8

Persistence in Eclipse Files & IResources IResource-based navigation IResources with temporary and persistent markers & attributes Synchronization between files and IResources On startup Automatic or manual for active Eclipse IResource delta & change propagation Set of changed IResources Propagation through builder 9 Persistence in EMF Resources & XML documents Meta model-based content hierarchy Multiple content structures per Resource are possible Meta model based XML processors Generated methods Meta model interpretation Tailorable generated resource factories Parameterization of XML processors Resource sets & XML cross reference resolution 10

Resource Factory Generation Ecore based, XML based, XMI based 11 Generated Resource Factory Default implementation 12

Parameterization of XML Processor Reference representation XPath based URI Method redefinition in AObject String eurifragmentsegment EObject eobjectforurifragmentsegment Generator parameterization Change of tag names For more details see EMF book 13 Cross Document References XML document XML document XML document Package1 Comp1 Comp2 Comp1.impl Comp2.impl Subcomp1 @Classifier Package2 Comp1 Comp2 Comp1.impl Comp2.impl Subcomp1 @ Classifier Res1.aaxl Res2.aaxl Res3.aaxl Resourceset Package3 Comp1 Comp2 Comp1.impl Comp2.impl Subcomp1 @ Classifier XPATH reference URI #//aadlpackage[@name=package2]/aadlpublic/ systemimpl[@name=comp1.impl] Reference resolution within resourceset Lazy resolution when reference is followed 14

OSATE Resource Manager Assures single resource set per project across plug-ins Text editor, parser, AADL object editor, graphical editor Assures single resource per XML document getresource, getemptyresource methods Hides idiosyncrasies of EMF resource API IResource <-> Resource conversion Selection of IResource in Eclipse navigator Markers on IResources IResource & IPath Resources & URIs Aadl model objects & Resources 15 AADL Models as Resources Text Editor & Parser Textual AADL Parser Semantic Checking Object Editor Object View Graphical Editor Graphical View Shared in-core instance Declarative AADL Model Analysis Plug-in Model analysis Persistent XML document Sharing of XML document 16

Synchronization of Models Batch processing Change notification in-core and resource-based Reprocess whole model Coordination of processing activities Incremental update In-core listener notification on individual AADL model objects Cross-reference methods in EcoreUtil User-defined reference-based propagation 17 References & Proxies Saving of Aadl models Root AADL model object as Resource content Save method on Resource Cross references stored as URI Loading of Aadl models getresource method for lookup by name Res.eContent().get(0) to get root Aadl model object Implicit loading of XML document with lazy reference evaluation References & proxies Proxy representation of references Automatic proxy resolution Unresolved references remain proxies Res.unload() results in conversion to reference proxies 18

OSATE Resource Manager API IPath getosatepath(string) IResource createfolderiresource(string) Resource getresource(iresource) Resource getresource(uri) Resource getemptyresource(uri) IResource converttoiresource(resource) ResourceSet getresourceset() EObject (AObject) methods eisproxy() eresource() 19 Outline Persistent AADL models Multi-file Support Modal system models Sublanguage extensions Initial implementation in test 20

Multi-file Support OSATE 0.4 Single textual AADL Single declarative AADL XML & separate instance model XML resources Upcoming OSATE release AADL text multi-file support AADL XML multi-file support Search paths 21 OSATE 0.4 File Support Textual AADL Single file contains AADL specification with all packages & property sets Predeclared property sets are auto-inserted by parser Inclusion of each predeclared property set in AADL text file overrides auto-insert of property set AADL XML Parsing into single file declarative AADL model Includes predeclared property sets Each AADL instance model as separate XML file File name derived from instantiated system implementation 22

Declarative & Instance Models Text Editor & Parser Declarative AADL Model Instance Plug-in Instance Model Instance Model Instance Model Analysis Plug-in Model analysis Works on both models OSATE 0.4: Cross-file URI includes file name declmodel.aaxl#//systemimpl[@name=comp1.impl] /subcomponents/threadsubcomponent[@name=t1] Persistent declarative XML Persistent Persistent instance Persistent XML instance XML instance XML 23 OSATE Multi-File Support Textual AADL in OSATE Separate text file per package Separate text file per property set Separate text file for AADL specification non-package/nonpropertyset declarations Import of text files with multiple packages/propertysets AADL XML in OSATE Separate XML file per package Separate XML file per property set Separate XML file for AADL specification non-package/nonpropertyset declarations Separate XML file for each instance model 24

OSATE Resource Organization OSATE Workspace Represents AADL global namespace Project Src/Text Output/XML Instances Instance1 Project AADLSpec AADLSpec Packages Propertysets AADLSpec AADLSpec Packages Propertysets Resourceset cmu edu com LM User PS1 User PS2 cmu edu com LM User PS1 User PS2 One Resourceset Per workspace Pack1 Pack2 Pack3 Pack1 Pack1 Pack2 Pack3 Pack1 25 Alternative OSATE Package View OSATE Workspace Project Src/Text Output/XML Instances Instance1 Project AADLSpec AADLSpec Packages Propertysets AADLSpec AADLSpec Packages Propertysets Resourceset edu::cmu:: Pack1 edu::cmu:: Pack2 edu::cmu::pack3 com::lm::pack1 User PS1 User PS2 edu::cmu:: Pack1 edu::cmu:: Pack2 edu::cmu::pack3 com::lm::pack1 User PS1 User PS2 26

OSATE Searchpath OSATE Workspace Project Searchpath Src/Text per project Searchpath order determines match Output/XML Instances Project AADLSpec AADLSpec Packages Propertysets AADLSpec AADLSpec Packages Propertysets Resourceset Search Path Search Path External Shared Folder Src/Text External Shared Folder Searchpath specifies src&output folder name Output/XML 27 Future OSATE Project Refinement Library project Shared read-only collection of packages/propertysets Update notification from repository Source project Modifiable collection of packages/propertysets Modification coordination via version control Local project AADL specification with anonymous namespace only Not accessible by packages Instance project Work with system instance Instance model with variations Analysis results Derived/transformed instance models 28

Outline Persistent AADL models Multi-file Support Modal system models Sublanguage extensions Initial implementation available 29 Instance Model Implementation Status Instantiate from system implementation Semantic connections Port connections implemented Port group unfolding to be done Access connections implemented Mode transition connections to be done Property values Contained property associations in instance model implemented Cached property associations implemented Modal contained property values in test Modal instance property value lookup in test 30

Modal & Configurable System Instances Set of legal System Operation Modes Supports SOM-specific property values Mode instances per modal component instance 31 Modal Instance Model ExternalModelAdapter Current system operation mode ModalInstanceAdapter Current mode M1 M2 System instance Modal component instance SystemOperationMode SystemOperationMode Modal component instance Current mode Component instance Component instance M1 M2 M3 Modal component instance Component instance Modal component instance M1 M2 32

System Operation Modes Class SystemOperationMode List of mode instances Class SystemInstance List of SystemOperationMode Current mode via adapter Class SOMIterator SOMIterator(SystemInstance root) Iterate of the system operation modes in root nextsom() Returns the next system operation mode Sets the modal adapters to the current system operation mode [See next 2 slides] hasnext() 33 Modal Instance Adapter EMF provides a generated adapter factory OSATE provides an adapter for modal instances Factory associates one adapter per object being adapted & adaptation key ModalInstanceAdapterFactory.INSTANCE.adapt (aobject, aobject); adapter.getcurrentmode() adapter.setcurrentmode(modeinstance mi) 34

System Instance Adapter We use a second adapter to associate the current system operation mode with a system instance. Retrieve adapter: ExternalModelAdapter adapter = (ExternalModelAdapter) ExternalModelAdapterFactory.INSTANCE.adapt( systeminstanceobj, SystemInstance.CURRENT_SOM_ADAPTER_KEY); Get the current system operation mode: SystemOperationMode som = (SystemOperationMode) adapter.getexternalmodelobject(); 35 Traversal Methods Revisited Class AObject getchildren(): econtent() Class ComponentInstance getchildren(): subset of children active in current mode Uses ModalInstanceAdapter Class SystemInstance setsystemoperationmode(systemoperationmode) clearsystemoperationmode() Class ForAllAObject Traversal methods call on getchildren 36

SOM Iteration Example Mode-specific priority inversion analysis EList SOMlist = sysinstance.getsystemoperationmode(); SOMIterator somit = SOMIterator(SOMList); while ( somit.hasnext()) { somit.nextsom(); checksystempriorityinversion(sysinstance); } Transparent use of analysis method 37 AADL Properties & Instance Model Non-cached property value System Accessible implementation from instance model System instance Application Subcomponent SourceText Execution Platform Subcomponent Application Execution platform system instance system instance Instance property value Application ComponentImpl Period Thread component instance Period Process component instance Thread component Period instance Process component instance ActualBinding Thread component instance Period Cached property value 38

Modal Property Values A component s property value may depend on the modes of the components in the model. In a declarative model The modes of the component itself. As a subcomponent, the modes of the containing component. In an instance model The modes of any arbitrary containing ancestor. Due to contained property associations. 39 Modal Property Values: Examples system implementation Inner.Impl modes InnerMode1: initial mode; InnerMode2: mode; properties PS::x => 1 in modes (InnerMode1); PS::x => 2 in modes (InnerMode2); end Inner.Impl; system implementation Outer.Impl subcomponents sub: system Inner.Impl { PS::y => 3 in modes (OuterMode1); PS::y => 4 in modes (OuterMode2); }; modes OuterMode1: initial mode; OuterMode2: mode; end Outer.Impl; Declarative model: Property values of component affected by modes of component itself. Declarative model: Property values of subcomponent affected by modes of containing component. system Main.Impl subcomponents sub: system S.I;... modes: M1: initial mode; M2: mode; properties PS::z => 5 applies to sub.a.b.c.d in modes (M1); end Main.Impl; Instance model: Property values of component instance affected by modes of arbitrary ancestor component. 40

Modal Property Value Complexities A property value may also be modal because A component may exist in certain modes only. Thus, a property value may not exist in some modes. This is distinct from a property value being not present, or unset. It references another property whose value is modal. 41 Modal Subcomponents Example system implementation ModalSubcomponents.Impl subcomponents sub1: system S1.Impl { PS::x => 0; } in modes (M1, M2); sub2: system S2.Impl { PS::x => 1 in modes (M1); } in modes (M1, M3); sub3: system S3.Impl { PS::x => 2 in modes (M2); PS::x => 3 in modes (M3); } in modes (M2, M3); modes M1: initial mode; M2: mode; M3: mode; end ModalSubcomponents.Impl; Assuming PS::x doesn t have a default value. Mode M1 M2 M3 Mode M1 M2 M3 Mode M1 M2 M3 Value of x 0 0 Nonexistent Value of x 1 Nonexistent Not Present Value of x Nonexistent 2 3 42

Modal Property Reference Example property set PS is bool1: aadlboolean => true applies to (system); bool2: aadlboolean => false applies to (system); bool3: aadlboolean applies to (system); end PS; system Example properties PS::bool3 => end Example; value(ps::bool1) and value(ps::bool2); Value of bool3 for component type Example is non-modal: it s always false system implementation Example.Impl modes M1: initial mode; M2: mode; properties PS::bool1 => false in modes (M1); PS::bool2 => true in modes (M2); end Example.Impl; Value of bool3 for component implementation Example.Impl is now modal: Mode bool1 bool2 bool3 M1 False False False M2 True True True 43 Modal Property Associations in Meta Model PropertyAssociation objects refer to modes via the inmodes association. In declarative model: List of Mode objects In instance model: List of SystemOperationMode objects 44

Review: Property Lookup Methods PropertyHolder declares property lookup methods getsimplepropertyvalue(propertydeclaration pd) getsimplepropertyvalue(string ps, String pn) For non-modal association of a single-valued property Returns a PropertyValue object, or null if association is modal, multi-valued, or not found. getpropertyvaluelist(propertydeclaration pd) getpropertyvaluelist(string ps, String pn) For non-modal association of a multi-valued property Returns a List of PropertyValue objects, or null if association is modal or not found getpropertyvalue(propertydeclaration pd) getpropertyvalue(string ps, String pn) General lookup method Returns a ModalPropertyValue object More on this follows 45 Interface ModalPropertyValue (1) Encapsulates mode-dependent property values (In package edu.cmu.sei.aadl.model.properties.) Methods boolean ismodal() Whether the value is modal. AadlPropertyValue getvalue() Gets the value when it is non-modal. Throws ModeNotSpecifiedException if a mode is required. Set getmodecontexts() Get the ModeContext objects whose modes affect the value. The modes visible in the context are returned by ModeContext.getModes(). ModeContext[] getmodecontextsasarray() Same as above, but as an array. 46

Interface ModalPropertyValue (2) Methods (continued) AadlPropertyValue getvalue(map modes) Get the value given specific mode bindings. Parameter modes maps ModeContexts to Modes. The ModeContext should be from getmodecontexts(). The Mode should be from the ModeContext s modes. Throws ModeNotSpecifiedException if a needed ModeContext is not bound to a Mode. Collection getallmodebindings() Get all the Maps that could be used with getvalue(). Collection getallvalues() Get all the values the property could have, as ReflectiveAadlPropertyValue objects. 47 Interface ModeContext Represents objects that contain mode declarations. (In package edu.cmu.sei.aadl.model.properties.) Two implementations: DeclarativeModeContext for declarative models. Refers to Modes from a ComponentImpl object. InstanceModeContext for instance modes. Refers to SystemOperationModes from a SystemInstance object. Methods String getname() Get the name of the underlying model object List getmodes() Get the modes available in the context. 48

Interface AadlPropertyValue (1) Encapsulates the property value. In particular, distinguishes nonexistence from not present. (In package edu.cmu.sei.aadl.model.properties.) Methods boolean exists() Whether the property value exists. If false, the other methods are irrelevant. boolean isnotpresent() Whether the property value is not present. boolean islist() Whether the property value is a list. False if!exists() isnotpresent(). 49 Interface AadlPropertyValue (2) Methods (continued) PropertyValue getscalarvalue() The property value if!islist(). Throws UnsupportedOperationException if islist(). List getvalue() The property value as a List of PropertyValue objects. List of length 1 if!islist(). 50

Interface ReflectiveAadlPropertyValue Extends AadlPropertyValue (In package edu.cmu.sei.aadl.model.properties.) Adds method Map getmodebinding() Returns the mode binding this value is for. Same as for ModalPropertyValue.getValue(Map). 51 Property Lookup Example final ModalPropertyValue dispatchmpv = ph.getpropertyvalue(predeclaredproperties.dispatch_protocol); for (Iterator values = dispatchmpv.getallvalues().iterator(); values.hasnext();) { final ReflectiveAadlPropertyValue dispatchpv = (ReflectiveAadlPropertyValue) values.next(); boolean bad =!dispatchpv.exists() dispatchpv.isnotpresent(); if (!bad) { final EnumValue dispatch = (EnumValue) dispatchpv.getscalarvalue(); bad =!PredeclaredProperties.APERIODIC.equals( dispatch.getenumliteral()) &&!PredeclaredProperties.SPORADIC.equals( dispatch.getenumliteral()); } if (bad) { reporterror(ph, "\"Dispatch_Protocol\" must be \"Aperiodic\" or " + "\"Sporadic\" when thread contains a server subprogram" + convertmodestostring(dispatchpv.getmodebinding())); } } Code fragment checking that all values of Dispatch_Protocol are Aperiodic or Sporadic 52

Caveat: Property Lookup and Instance Models Modeless property lookup methods understand the modal adapters on instance models. getsimplepropertyvalue(propertydeclaration pd) getsimplepropertyvalue(string ps, String pn) getpropertyvaluelist(propertydeclaration pd) getpropertyvaluelist(string ps, String pn) Property value looked up based on the current system operation mode. 53 Need an example of modal property lookup in an instance model with the current mode set on the model. This should allow us to hide the map stuff. 54

Setting Property Values PropertyHolder declares property setting methods. setpropertyvalue( PropertyDefinition pd, PropertyValue pv) Set a non-list property value. Throws exception if property is not applicable to the property holder, or if the property value is inappropriate. setpropertyvalue(propertydefinition pd, List pvl) Set a list property value. Throws exception if property is not applicable to the property holder, or if the property value is inappropriate. removepropertyassociations(propertydefinition pd) Remove all property associations for the given property from the property holder. 55 Setting Modal Property Values Modeless property setting methods understand the modal adapters on instance models. setpropertyvalue( PropertyDefinition pd, PropertyValue pv) setpropertyvalue(propertydefinition pd, List pvl) Property value set for current system operation mode only. Modal variants of property setting methods: setpropertyvalue(propertydefinition pd, PropertyValue pv, List modes) setpropertyvalue(propertydefinition pd, List pvl, List Modes) removepropertyassociations(propertydefinition pd, List modes) Removes associations for the given property in the given modes. 56

Setting Contained Property Associations PropertyHolder declares the methods setcontainedpropertyvalue(propertydefinition pd, List appliestopath, PropertyValue pv) setcontainedpropertyvalue(propertydefinition pd, List appliestopath, PropertyValue pv, List modes) setcontainedpropertyvalue(propertydefinition pd, List appliestopath, List pvl) setcontainedpropertyvalue(propertydefinition pd, List appliestopath, List pvl, List modes) removecontainedpropertyassociations( PropertyDefinition pd, List appliestopath) removecontainedpropertyassociations( PropertyDefinition pd, List appliestopath, List modes) Parameter appliestopath is a list of declarative components This path is not checked to see that it makes sense with respect to the features/subcomponents of current PropertyHolder. 57 Modal Analysis Results Stored as modal instance property values Multiple sets in same instance model Option: keep (modal) result property value sets in separate XML document 58

Modal Analysis Result Sets Modal analysis results in form of sets of modal property associations Stored as separate XML documents 59 Persistent AADL models Multi-file Support Modal system models Sublanguage extensions Outline Not yet prototyped 60

AADL Language Extensions New properties through property sets Sublanguage extension Annex subclauses expressed in an annex-specific sublanguage Project-specific language extensions Language extensions as approved SAE AADL standard annexes Examples Error Model ARINC 653 Behavior Constraint sublanguage 61 An Error Model Extension Supports reliability, availability, maintainability, safety, and related specification and analysis activities Useful in system safety certification and qualification Optional set of declarations and associated semantics Facilitates a variety of analyses top-down hazard analysis a bottom-up failure modes and effects analysis fault tree and stochastic process analyses safety, reliability, availability, maintainability integrated analyses Provides a representation of system hazards component failure modes 62

Error Model A component has error-free and error states Fault event occurs local to a component with a specified probability. The error state may persist for some interval of time (the error latency) before it becomes externally observable Observable error states are propagated to dependent components Propagations can be masked by the observer (Subcomponent error model states can be mapped into a composite error model state) 63 Error Modeling Approach Error model annex clauses declare Error states and transitions Fault events & occurrence rates Error propagation events & occurrence rates Masking propagation events Architecture model provides Dependency information Basis for isolation analysis 64

Language Extension Implementation Property sets handled by OSATE Sublanguage extension AADL meta model provides abstract Annex classes Sublanguage meta model as additional EMF meta model package AADL parser callout to sublanguage lexer/parser generated from ANTLR (www.antlr.org) 65 AADL Metamodel as Basis Metamodel Elements (in core package) AnnexLibrary (aadlspecpackage.ecd) in AadlSpec and AadlPackageSection (public / private) AnnexSubclause (core.ecd) in ComponentClassifier (types / implementations) Both are named elements with no further internal structure. Default implementations: DefaultAnnexLibrary and DefaultAnnexSubclause Return content of annex as a string with no processing. 66

AADL Metamodel 2 aadlspecpackage.ecd core.ecd 67 Example Sublanguage Simplified error model annex Error models State machine associated with component type or implementation Error model states and transitions Error model events Internal faults trigger transitions Propagation events (outgoing) Combining error models Masks (in) filter incoming propagation events Properties on error model elements 68

Observable Events Observable error propagation event Error Model detected_fault error_free undetected_fault Fault Event fail_stopped babbling propagated fail_stopped propagated babbling 69 Error Propagation Comp2 Fail_stopped Babbling detected_ error_free fault fail_stopped Fail_stopped undetected _fault babbling Babbling Masked events Comp1 Fail_stopped Fail-stopped Babbling Babbling Erroneous components Masked incoming error propagation events Dependent component 70

Component Dependencies Component dependencies are determined from the architecture. Errors may propagate: Port Data access through a connection through a shared subcomponent from an hardware component to all dependent software components from a software component to other software components that share a common hardware resource, according to partitioning rules Resource binding Bus access 71 Extending the Metamodel 1 New package: errormodel ErrorModelLibrary 72

Extension Rules Do Extend AADL metamodel classes ErrorModelLibrary AnnexLibrary Errormodel NamedElement etc. Ultimately, all new classes should have AObject as a superclass to support XMI / XML (de)serialization. Reference AADL metamodel classes Reuse existing constructs where possible Don t change the basic AADL model by Introducing new superclass for AADL metamodel element Indirect change to basis AADL Model complete regeneration Referencing new class from AADL class 73 Error Model Properties Example: Occurrence probability of fault event AADL Probability: aadlinteger applies to FaultEvent How to model this? Issue PropertyDefinition can only apply to PropertyOwnerCategory, which is an enumeration Solution / Workaround Subclass PropertyDefinition 74

Extending the Metamodel 2 Error model properties Extensibility of property metamodel is currently limited Applies to and property references are based on enumerations EMF enumerations cannot be extended 75 Current metamodel Properties 76

Properties Possible solution approaches Programmatic extensibility Manually extend the enumerations based on a plug-in mechanism Dynamic registration without numeric constants Re-design the metamodel for extensibility Details TBD Future OSATE release 77 Extending the Metamodel 2 ErrorAnnex (AnnexSubclause) inside classifier This is incomplete! 78

Masks A mask filters incoming propagation events from Sibling component Subcomponent Accessed data Etc. In textual AADL: Specify the path to an outgoing propagation event in another component error model Name resolution must be extended to resolve the reference Similar to a property referencing a subcomponent 79 Parsing an Annex 1 Textual annex must be parsed to create the model: 2 possible approaches 1. Two-pass approach 2. Parser extension 80

Two-pass approach Parsing an Annex 2 Similar to analysis plug-in Don t change standard parser Traverse the model and parse value strings from default annex implementation Replace the DefaultAnnex object with the new ones from the extended metamodel Currently the way to do it 81 Extend the parser Parsing an Annex 3 Create a parser plug-in Each annex provides a plug-in to the parser to handle annex specific syntax Annex parser must register with the AADL parser ANTLR provides some basic support to switch to another parser Planned to be supported in a future OSATE release 82

Summary Leveraged Eclipse & EMF for persistent XML document support Multi-file AADL models in test Modal system models Easy to use Hard to implement Presented AADL sublanguage extension approach Being prototyped 83