Applications which are both context-aware and adapting, enhance users’ experience by anticipating their
need in relation with their environment and adapt their behavior according to environmental changes.
Being by definition both context-aware and adaptive these applications suffer both from faults related to
their context-awareness and to their adaptive nature plus from a novel variety of faults originated by the
combination of the two. This research work analyzes, classifies, detects, and reports faults belonging
to this novel class aiming to improve the robustness of these Context-Aware Adaptive Applications
(CAAAs).
To better understand the peculiar dynamics driving the CAAAs adaptation mechanism a general
high-level architectural model has been designed. This architectural model clearly depicts the stream of
information coming from sensors and being computed all the way to the adaptation mechanism. The
model identifies a stack of common components representing increasing abstractions of the context and
their general interconnections. Known faults involving context data can be re-examined according to this
architecture and can be classified in terms of the component in which they are happening and in terms
of their abstraction from the environment. Resulting from this classification is a CAAA-oriented fault
taxonomy.
Our architectural model also underlines that there is a common evolutionary path for CAAAs and
shows the importance of the adaptation logic. Indeed most of the adaptation failures are caused by
invalid interpretations of the context by the adaptation logic. To prevent such faults we defined a model,
the Adaptation Finite-State Machine (A-FSM), describing how the application adapts in response to
changes in the context. The A-FSM model is a powerful instrument which allows developers to focus in
those context-aware and adaptive aspects in which faults reside.
In this model we have identified a set of patterns of faults representing the most common faults in
this application domain. Such faults are represented as violation of given properties in the A-FSM. We
have created four techniques to detect such faults. Our proposed algorithms are based on three different
technologies: enumerative, symbolic and goal planning. Such techniques compensate each other. We
have evaluated them by comparing them to each other using both crafted models and models extracted
from existing commercial and free applications. In the evaluation we observe the validity, the readability
of the reported faults, the scalability and their behavior in limited memory environments. We conclude
this Thesis by suggesting possible extensions