09.08.2013 Views

Architecture Modeling - SPES 2020

Architecture Modeling - SPES 2020

Architecture Modeling - SPES 2020

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

<strong>Architecture</strong> <strong>Modeling</strong><br />

When specifying requirements there is no strict typing like int or real but there are categories<br />

that specify what is described by the different attributes. To not complicate the language too<br />

much and to be also expressive enough, the set of supported attributes has been carefully chosen:<br />

• Events represent activities in the system. An event can be for example a signal, a user<br />

input by pressing a button, or the availability of a computational result. Events occur at<br />

specific points in time and have no duration.<br />

• Conditions are logical and/or arithmetical expressions over variables and the status of<br />

events. Conditions can be used in two different ways. Firstly, they can be used as pseudo<br />

events to trigger an action if the condition becomes true. And secondly, they may represent<br />

the system state that has to hold for a specified time.<br />

• Intervals describe a continuous fragment of time whose boundaries are either (relative)<br />

time measures, or events. Intervals can be open “]x,y[“ or closed “[x,y]” or a combination.<br />

• Components refer to entities that are able to handle events or condition variables.<br />

RSL supports various combinations of elements. It allows for example filtering of events by<br />

intervals or conditions. That is, whenever a pattern expects an event, one may also use “event<br />

during interval”, or “event under (condition)”. Thus, one can e.g. specify<br />

whenever request during [activate,deactivate] occurs response occurs during [l,u]<br />

meaning that a response is constrained only if the request happened after an activate and before<br />

some deactivate event. Filtering of events can be applied recursively. So activate could again<br />

be filtered by some interval or condition.<br />

The interested reader is referred to Section 6.1 for a detailed description of the RSL.<br />

While specification languages such as RSL help the engineer to formalize requirements, there<br />

are other pitfalls when specifying contracts. Two key properties of contracts, essential to maintain<br />

sanity of the design-flow shall be discussed here, namely receptiveness and consistency.<br />

Receptiveness Since the interface of a component distinguishes input ports and output ports,<br />

there is a clear separation between those ports the component controls and those that are controlled<br />

by the components environment. Receptiveness denotes the fact that also the responsibilities<br />

of both assumption and guarantee of a contract are properly distinguished. More formally,<br />

a contract is receptive only if the assumption does not restrict possible behavior of the output of<br />

a component, and if the guarantee does not restrict the input ports.<br />

To give an example, we assume a component with inport i and outport o. A guarantee stating<br />

that, whenever the component sends an event to o, the environment responds by another event<br />

send to i within, say 5 ms, violates the receptiveness property. It violates receptiveness because<br />

it is not the duty of a components guarantee to require the environment to react in a certain<br />

amount of time. For the same reason, an assumption stating that the component produces an<br />

output event each 10 ms violates receptiveness. On the other hand, an assumption for such a<br />

component, stating that whenever the component sends an event to o, the environment responds<br />

by another event send to i within 5 ms, perfectly maintains receptiveness. A receptive contract<br />

is denoted directed.<br />

49/ 156

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

Saved successfully!

Ooh no, something went wrong!