uOttawaUniversity of Ottawa - Canadas University
list of dots

Umple User Manual    [Previous]   [Next]   


Model Oriented Tracing Language (MOTL)

Model Oriented Tracing Language (MOTL) allows developers to specify tracing at the model level.

Historically, developers have traced software using various techniques:

  • Adding print statements or some other special debug statement to code, often with conditional compilation so it can be switched off when the final system is compiled.
  • Using tracepoints or breakpoints in a debugger.
  • Using a tool Like DTrace (also see here) that specifies a trace script to dynamically patch live running code.
  • Using a tool like LTTNG to insert tracepoints.

However, in software generated from UML, these techniques can only be used effectively on generated code. They require understanding the structure of that generated code; furthermore trace directives need replacing when the code is replaced. Tracing thus occurs at a level of abstraction below the level at which the system is implemented.

MOTL is designed to allow tracing with direct reference to UML model elements (state machines and their states and events, associations and attributes). MOTL specifies how to inject trace code into generated code for UML constructs.

MOTL syntax is designed to be be usable independently of Umple. For example, trace statements could be used to inject tracing into code generated from a UML model specified in Papyrus. The current implementation of MOTL focuses on tracing Umple-generated code. In order to trace a UML model created by an arbitrary UML tool, it is currently necessary to have the model from that tool converted to Umple first.

MOTL can be used to generate tracing directives for different types of tracers. At its simplest level, if the phrase 'tracer Console;' is used (or no tracer statement is included), then trace output is directed to standard error. Generation of tracing for DTrace and LTTNG is under development.

MOTL can be used in two modes:

  • As scripts that are independent of the model. These appear like DTrace scripts. When used with Umple, they are merged into an Umple model using Umple's mixin capability.
  • By directly annotating model elements.

The following pages describe how to use MOTL. Many aspects of MOTL are under development. Some future pages for tracing features under development cam be found in Umple wiki pages.

The MOTL project has been sponsored by NSERC, Ericsson and Defence Research and Development Canada, in the Distributed Multi-Core Tracing Project managed by Ecole Polytechnique de Montreal