Designing component-based architectures with Rational Rose RealTime

from The Rational Edge: This article first examines the goals and challenges of developing and deploying real-time systems and then describes an easy-to-follow approach to architecting a scalable, component-based system with Rose RealTime.


Reedy Feggins, Senior System Engineer, IBM, Software Group

Reedy Feggins is a Senior System Engineer on the IBM Rational team responsible for supporting customers involved in real-time system development, Internet application development, visual modeling, and requirements management. In this capacity he delivers seminars, on-site customer training courses, and consulting services. Prior to joining Rational, he worked within the software industry as a system architect, developer, tester, and project manager. During an eight-year tenure at AT&T Bell Labs, he was involved in the specification and development of several real-time systems used in the AT&T Switched Network. He holds a BS and an MS in Electrical Engineering from the State University of New York at Buffalo.

15 July 2003

Rose RealTime is a comprehensive visual development environment that delivers a powerful combination of modeling notation, design capabilities, and debugging tools to meet the challenges faced by real-time designers. Rose RealTime provides software architects and embedded system developers with a unique tool for rapidly prototyping, designing, and constructing executable models. Many new Rose RealTime designers, however, find it difficult to create robust models when they first start using the tool. This article first examines the goals and challenges of developing and deploying real-time systems and then describes an easy-to-follow approach to architecting a scalable, component-based system with Rose RealTime.

The Challenges of Developing Real-Time Systems

Real-time systems range from small embedded applications (e.g., for cell phones, handheld devices, or set-top boxes) to highly evolved distributed applications (e.g., for airplanes, switches, and automotive systems). Developers have created and deployed real-time systems for years, but the process offers challenges not normally encountered in other development domains:

  • Most real-time systems must run on small, customized operating systems with limited memory and strict performance requirements (e.g., response times and throughput).
  • Because many real-time systems are deployed in highly critical applications, developers must provide fault-tolerant capabilities that isolate the result of a subsystem fault/failure, so that the application can continue to operate at a degraded level.
  • Real-time systems require tight integration among application software, the real-time operating system (RTOS), and the target hardware; this is contrary to the goals of most good system architectures.

Architecting Real-Time Systems

So how do developers meet these special challenges? We can begin to address that question by looking at the basics of architecting a real-time system.

The main goal of a real-time system architect -- like that of all other system architects -- is to create a "good" system. In this instance, "good" means the system will meet corporate and customer needs for:

  • Reliability -- Does the system have just a few bugs (note that no system is completely free of bugs)?
  • Flexibility -- Can the system evolve to meet changing user needs?
  • Affordability -- Can the organization afford to build and maintain the system? To sell the product in which it is embedded?
  • Availability -- Can the system run on available operating systems and hardware?

System architectures are used by diverse sets of people at different times in the development cycle, so often these architectures are separated into different views.1 This approach enables all the different groups of stakeholders to communicate needs (i.e., requirements), resolve conflicts, and document decisions. The Rational Unified Process (RUP) identifies a standard set of views called the 4+1 Architecture Views, depicted in Figure 1.

Figure 1: The 4+1 Architecture Views from the Rational Unified Process
(click here to enlarge)

The +1 refers to the Use Case View, which contains the key use cases that drive the architecture. The other four views are:

  • The Logical View that describes the software structure and is used to identify major design packages, capsules, and classes.
  • The Process View that addresses the concurrent aspect of the system at runtime: tasks, threads, or processes, and their interactions.
  • The Deployment View that shows how the various executables and other runtime components are mapped onto the underlying platforms or computing nodes.
  • The Implementation View that provides the software's static organization in terms of packaging, layering, and configuration management.

Together, these views provide the architect with the necessary perspective to adequately model and build a complex real-time system. Although the 4 + 1 Views don't map exactly to the UML models (or, therefore, to Rose RealTime), let's take a look at how Rational Rose RealTime supports them.

The Use Case View

As for most software systems, architecting for real-time systems involves understanding the short- and long-term requirements and deciding on necessary tradeoffs to achieve the highest quality system. The Use Case Architecture View, which describes functional requirements from the user's perspective, is documented in a set of diagrams. This view (the +1) maps precisely to the Use Case View in Rose RealTime. For most systems, only a subset of these diagrams are architecturally significant. These architecturally significant diagrams describe usage scenarios that:

  • Require multiple software components.
  • Identify how components communicate or are organized (see Figure 1 for an example).
  • Describe configuration, administration, or maintenance scenarios for multiple components.
  • Specify qualities that make the system competitive, cost-effective, or worth building.

Figure 2: An Architecturally Significant Use Case Diagram
(click here to enlarge)

The RUP also suggests using a "Robustness Analysis" to map a system's use cases into three classes:

  • Control Class -- used to manage application services or resources typically mapped to active classes.
  • Boundary Class -- used to identify interfaces between actors and the system under development.
  • Entity Class -- used to contain persistent data typically mapped to passive classes.

In most cases, these "Robustness" classes are mapped as shown in Figure 3.

Mapping Use Cases to Robustness Classes

Figure 3: Mapping Use Cases to "Robustness" Classes

The Logical View

The Logical View provides the architect with a mechanism for describing the system software structure in terms of major design packages, capsules, and subsystems. The logical view is represented in Rose RealTime by class and structure diagrams2 used to show the architecturally significant artifacts in the view:

  • Major classes that have high visibility throughout the rest of the application
  • Business domain and persistent classes
  • Active classes (or capsules)
  • Protocol classes
  • Classes critical to system integrity

Grouping and organizing the application elements into packages is the best approach for depicting architecturally significant components and subsystems. Typically, system architects use packages to illustrate dependency relationships between different parts of an application. Packages are useful for showing architecture layers, as depicted in Figure 4. They are also units of configuration management that can be used to organize the building and evolution of actual software elements.

Figure 4: Showing Architectural Layers with Packages
(click here to enlarge)

Capsules are the basic building blocks that Rational Rose RealTime modelers use to provide encapsulated data and operations as well as support for concurrent events. They also represent capsule-related roles and responsibilities. Possessing many of the characteristics of a class (e.g., attributes and operations), capsules are class stereotypes used to depict active (or concurrent) responsibilities that the application must exhibit. Each capsule represents an independent flow of control in the system under development. Using Rational Rose RealTime, application developers use state diagrams to model class behavior and structure diagrams to depict object interaction. Like passive classes, capsules communicate with each other through messages, via well-defined interfaces called "ports."

Figure 5: Structure Diagram for an Asymmetric Digital Subscriber Line (ADSL) Project
(click here to enlarge)

Many Logical View diagrams can be used to provide architecturally significant information for constructing real-time systems, but the structure diagrams associated with each capsule provide the most complete representation of the software's dynamic structure. The example in Figure 5 depicts the structure diagram for an Asymmetric Digital Subscriber Line (ADSL) project.

The Process View

In Rose RealTime, vital aspects of the Process View -- namely determining the threads of control within the application -- are focused in modeling elements: capsules and components. By definition, each capsule (i.e., active class) has its own independent thread of control that is implemented using its state diagram. Each capsule can be mapped to a specific component (or set of components), which can then be built as an executable library or external library. Each component implements a non-trivial set of functionality and may not necessarily be a single unit of code or a single binary. System architects can use both capsules and components to depict units of distribution, assembly, and deployment. Further, as shown in Figure 6, designers can assign capsules to specific runtime threads, thereby enhancing the modeling capabilities of the Process View.

Figure 6: Assigning Capsules to Runtime Threads
(click here to enlarge)

The Deployment View

The Deployment View gives the architect the means for describing how components and subsystems are distributed across system nodes. Deployment diagrams depict architecturally significant elements such as processor nodes, device nodes, connections, and runtime components (e.g., executables). Figure 7 is a typical deployment diagram.

Figure 7: A Typical Deployment Diagram
(click here to enlarge)

Implementation View

The Implementation View focuses on the software development environment and how it is organized. Typically, applications constructed using Rose RealTime are organized into a set of hierarchy layers, realized using subset of the packages found on class and component diagrams. Each layer should provide a well-defined interface (using capsules and, in some special cases, interface classes) to the layers above it. The Implementation View assists architects in describing partitioning, reuse, and visibility guidelines to the team. In Rose RealTime, the Implementation View is realized using class diagrams to depict model organization -- with packages, interfaces, and subsystems. Architects must continuously review and assess the impact on these guidelines as changes are made by team members.

Resolving the Architect's Dilemma

Any well-designed architecture separates design concerns from abstract implementation details, supports the testing of independent components, enables greater reuse of larger subsystems or frameworks as well as low-level classes, and ultimately increases system longevity. It also provides several key benefits during the development process:

  • Good communication as well as understanding of tradeoffs among stakeholders regarding major design decisions;
  • Efficient resource management (development teams, hardware and software environments, and capital resources);
  • Effective coordination of project schedules and risk assessment efficiency.

In designing a "good" architecture, real-time architects face a few special challenges. They must balance the need to focus on the big picture with the need to design component-based architecture that will work seamlessly with the RTOS and target hardware. Rational Rose RealTime provides the support they need to accomplish this. Using the 4+1 Views, system architects and application developers can better model system responsibilities and create reusable elements.


  • Feggins, Reedy; "Developing Large Scale Executable Architectures Using Rational Rose RealTime." Rational User Conference 2000.
  • Bass, Len, et al., Software Architecture in Practice. Addison Wesley Longman, 1998.
  • Rosenberg, Doug, Use Case Driven Object Modeling with UML -- A Practical Approach. Addison-Wesley [Longman??], 1999.
  • Stevens, Perdita, et al., Using UML Software Engineering with Objects and Components. Addison-Wesley Longman, 2000.
  • Eriksson, Hans-Erik, et al., UML Toolkit. John Wiley & Sons, 1998.
  • Selic, Bran, Gullekson, Garth, et al., Real-time Object-Oriented Modeling. John Wiley & Sons, 1994.
  • Kozaczynski, Wojtek, "Principles of Architecting Software Systems." Rational Software, 1999.
  • Rational University, "Developing Real-time Software With Rational Rose RealTime -- version 6.0." Rational Software, 1999.


1 An architecture view is a simplified description (abstraction) of a system from a particular perspective or vantage point, covering particular concerns and omitting entities that are not relevant to this perspective.

2 Structure diagrams are stereotyped collaboration diagrams used to graphically depict the active objects and their communication paths.


developerWorks: Sign in

Required fields are indicated with an asterisk (*).

Need an IBM ID?
Forgot your IBM ID?

Forgot your password?
Change your password

By clicking Submit, you agree to the developerWorks terms of use.


The first time you sign into developerWorks, a profile is created for you. Information in your profile (your name, country/region, and company name) is displayed to the public and will accompany any content you post, unless you opt to hide your company name. You may update your IBM account at any time.

All information submitted is secure.

Choose your display name

The first time you sign in to developerWorks, a profile is created for you, so you need to choose a display name. Your display name accompanies the content you post on developerWorks.

Please choose a display name between 3-31 characters. Your display name must be unique in the developerWorks community and should not be your email address for privacy reasons.

Required fields are indicated with an asterisk (*).

(Must be between 3 – 31 characters.)

By clicking Submit, you agree to the developerWorks terms of use.


All information submitted is secure.

Dig deeper into Rational software on developerWorks

ArticleTitle=Designing component-based architectures with Rational Rose RealTime