11.12.2012 Views

Model-Driven Evolution of Software Architectures - Software and ...

Model-Driven Evolution of Software Architectures - Software and ...

Model-Driven Evolution of Software Architectures - Software and ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

7.7. TargetMetamodel 147<br />

tworesourceusagepatternsareexecutedinparallel.<br />

Conditionalexecution Theidiomforconditionalexecutionismorecomplicated.<br />

First,werequireittobespecifiedusingachoicePseudostatewith<br />

twooutgoingTransitions. OnespecifiessomeconditionasaGuard;the<br />

otherspecifies [else]asaGuard.Furthermore,werequire‘proper’nesting<br />

<strong>of</strong>conditionalactivationpathsinastatemachine.Thismeansthatwerequirepairs<strong>of</strong>corresponding,alternativepathsthroughthestatemachinetobemergedoneatatime(usingjunctionPseudostates),<strong>and</strong>inreverseorder.Figure7.7onthefollowingpagecontainsseveral(nested)examples<strong>of</strong><br />

thispattern(choice<strong>and</strong>junctionPseudostatesaredepictedusingdiamonds<br />

<strong>and</strong>thesmallerblackcircles,respectively).<br />

Withoutthisrequirementforpropernesting,findingtheset<strong>of</strong>States,<br />

<strong>and</strong>thusActions,whichareenabledwhensomeGuardevaluatestotrue<br />

wouldbecomerathercomplicated. Forthetransformation<strong>of</strong>oursource<br />

modelstotargetmodels,findingthisset<strong>of</strong>statesisanecessarystep.‘Nonproper’nestingoccurs,forinstance,inthebottom-half<strong>of</strong>theprocesswafer<br />

requestinFigure7.5onpage141. Thisresultsinreplication<strong>of</strong>theactivitiesperformedoneachpathduringnormalisation.ThethreeCompositeStatesinthebottom-half<strong>of</strong>Figure7.7onthefollowingpageillustrate<br />

thisreplication. Part<strong>of</strong>thisparticularnormalisationstepiscoveredby<br />

constraint C4,whichstatesthatapaththroughastatemachinecanonly<br />

splitintwopaths<strong>and</strong>thatnomorethantwopathscanbejoinedinasingle<br />

statenode.BecausetheOCLconstrainttoexpresspropernestingisrather<br />

lengthy,wedidnotincludeithere.<br />

7.7 TargetMetamodel<br />

Weconsider TRSasthegivenparadigmfortheend-point<strong>of</strong>themigration.Thisend-pointisbasedonaresearchprototype[V<strong>and</strong>enNieuwelaar,<br />

2004]. Usingthe TRSparadigm,amanufacturingrequestistranslated<br />

intovalidmachinebehaviourintwophases.First,uponarrival<strong>of</strong>amanufacturingrequest,aschedulingprobleminthecontext<strong>of</strong>thatrequestis<br />

instantiatedduringaplanningphase.Forthis,therequestisinterpreted<br />

throughrulesthatoperateoncapabilities(resourcetypes)<strong>and</strong>behaviours<br />

(tasktypes). Here,amanufacturingactivitycorrespondstoatask<strong>and</strong>a<br />

mechatronicsubsystemtoaresource. Thefirstphaseresultsinahierarchicaldigraphthatconsists<strong>of</strong>tasks<strong>and</strong>their(precedence)relations.Nodes<br />

inthisgraphcanbecompositetoeitherdenoteaset<strong>of</strong>tasksthatallneed<br />

tobeexecutedortodenoteaset<strong>of</strong>tasks<strong>of</strong>whichonlyonewillbeexecutedbasedonsomecondition.Second,aschedulingphaseconstructively<br />

assignstasksinthisdigraphtospecificresourcesovertime[Viennot,1986;

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!