during which the attribute value is considered valid.
We use the MARTE NFP Duration datatype as a type
for the validity duration feature.
We characterize each sensor stereotype by two
properties : maximum data error and periodicUpdate.
Maximum data error indicates the maximum devia-
tion tolerated between the current attribute value and
the updated value. It is of type NFP Real. Maximum
data error represents a non-functional property spec-
ifying the upper bound of the error. We propose to
associate the Nfp stereotype of MARTE profile to the
maximum data error attribute. PeriodicUpdate refers
to a periodic operation of the class that owns the sen-
sor attribute. The role of this periodic operation is to
update the current value and the timeStamp fields of
the sensor attribute. It is of type Operation.
As shown in Figure 2, we characterize derived
stereotype by sporadicUpdate property, that refers to
a sporadic operation of the class that owns the derived
attribute. This sporadic operation is used to update the
current value and the timeStamp fields of the derived
attribute.
Each real-time attribute value is characterized by
a timestamp, which indicates the time at which it was
last updated. So, for each real-time attribute value
corresponds a timestamp, which distinguishes it from
other attribute’s values. Whereas, the values of the
validity duration and maximum data error fields are
the same for the same real-time attribute.
3.2.2 Stereotypes for Real-Time Transactions
A real-time transactions may be aperiodic, periodic,
or sporadic (Ramamritham et al., 2004). It has timing
constraints such as deadline and period. We define
three stereotypes, aperiodic, periodic, and sporadic
(cf. Figure 2) in order to declare respectively ape-
riodic, periodic, and sporadic operations in the class
diagram. Each of these stereotypes is characterized
by a deadline, which indicates the last time by which
the method execution must be completed. Thereby,
we define an abstract stereotype, called realTimeOp-
eration, which is used to annotate model elements
(i.e. Operations) with real-time features according to
set of RtSpecification associated with this stereotype.
RtSpecification possesses nine tagged values among
which: relDl, occKind, and priority. The relDl at-
tribute specifies the deadline of a method execution.
The occKind attribute indicates the arrival transaction
specification (i.e. periodic, aperiodic, or sporadic).
For a periodic (respectively aperiodic and sporadic)
transaction, the PeriodicPattern (respectively Aperi-
odicPattern and SporadicPattern) enumeration literal
is selected for ArrivalPattern attribute of the occKind
property. The priority attribute specifies the priority
Figure 3: Time Specification in MARTE.
order of a transaction. The realTimeOperation stereo-
type factorizes also two properties: concPolicy and
isAtomic. When the value of isAtomic is true, the
method execution is done as one individual unit. This
fact coincides with the atomicity property of a trans-
action. However, in RTDBs, this feature is relaxed in
order to allow the validation of a transaction even if
only a part of its actions have been executed (Agrawal
et al., 1994). So, in our work, we consider that the
value of the isAtomic property is always false. The
concPolicy property specifies the concurrency policy
of a transaction. The values of this property may be:
reader, writer or parallel. A writer transaction im-
plies that multiple calls from concurrent transactions
may occur simultaneously and will be treated as soon
as concurrency on data allows its execution. A reader
transaction implies that multiple calls from concur-
rent transactions may occur simultaneously and will
be executed simultaneously if there is no writer trans-
action using one or more data that the reader trans-
action needs. A parallel transaction is a transaction
whose actions do not use any data of the database in
reading mode nor in writing mode. In our work, we
consider that for an update transaction, which can pe-
riodic or sporadic, the concPolicy property is writer.
3.2.3 Real-Time Class Stereotype
The design of a RTDB, which is by definition a
database system, has to take into account the manage-
ment of many components such as queries, schemas,
transactions, commit protocols, concurrency control
protocol, and storage management (Stankovic et al.,
1999). In order to deal with time-constrained data,
time-constrained operations, parallelism, and concur-
rency property inherent to RTDBs, we introduced the
RealTimeClass stereotype. This stereotype specifies
that instances of a class will encapsulate real-time
data and real-time operations and a local concurrency
mechanism. Because of the dynamicnature of the real
world, more than one transaction may send requests
to the same object. Concurrent execution of these
transactions allows several methods to run concur-
rently within the same object. To handle this essential
property of RTDB systems, we associate to each ob-
ject a local concurrency control mechanism, named
local controller, that manages the concurrent execu-
ModelingStructural,TemporalandBehavioralFeaturesofaReal-TimeDatabase
121