Task: Optimize Concurrency Architecture
This task focuses on the specification of the concurrency architecture.
Purpose
The purpose of this task is to identify the concurrency units, map passive objects into task threads, specify how the tasks will run, and specify how resources will be shared among the tasks.
Relationships
RolesPrimary: Additional: Assisting:
InputsMandatory: Optional: External:
  • None
Outputs
Main Description

The concurrency and resource architectural view is one of critical importance for real-time and embedded systems. This view is concerned with:

  • The identification of concurrency units (tasks or threads)
  • Specification of the scheduling policy for the concurrency units
  • Specification of the scheduling metadata for the concurrency units, including arrival pattern, synchronization pattern, periodicity, jitter, minimum arrival time, worst case execution time, blocking time, etc.
  • Specification of the resource sharing strategies and patterns between concurrency units
  • Determination of the timeliness of tasks and the schedulability of the task sets.
  • Determining and eliminating potential deadlock.
Steps
Make a new Active class for each task
Active classes are the fundamental unit of concurrency in the UML. We recommend you create new classes here rather than make classes from your analysis model active. This makes for an easier migration to the concurrency architecture.
Identify Tasks
Using the task identification strategies, define which tasks should be created.
Analyze concurrency architecture for schedulability
We recommend that you perform schedulability analysis on your concurrency architecture to ensure that even under conditions not tested, you can be guaranteed that all deadlines can be met.
Apply resource sharing patterns
The resource patterns are applied with model refactoring to integrate them into the system design.
Identify synchronization points
Synchronization points are points in different task action sequences when they must interact with other tasks.
Apply scheduling patterns
The scheduling patterns are applied to integrate them into the system design.
Select resource sharing patterns
A resource sharing pattern focuses on a technical means for sharing a resource so as to maintain its integrity while simultaneously optimizing its client's usage.
Test model with tasks in place
The testing of the elaborated model should focus on two aspects. First, the addition of the concurrency elements should not break existing functionality. Secondly, the desired optimizations should be achieved.
Identify shared resources
Resources are typically passive elements that are constrained in some way. When resources are shared, care must be taken to ensure their integrity.
Select scheduling patterns
There are many ways to schedule tasks. See the associated guidance.
Apply synchronization patterns
The synchronization patterns are applied with model refactoring to integrate them into the system design.
Select synchronization patterns
There are many synchronization strategies and patterns that can be applied. For more information, see the referenced material.
Refine each task

This includes:

  • Specifying the tasks properties, such as:
    • Priority
    • Worst case execution time
    • Blocking time
    • Deadline
    • Period
    • Jitter
    • Minimum interarrival time
    • Maximum burst length
  • Adding "passive" objects into the «active» class as parts
  • Refactor the collaboration to include the «active» classes
  • Refine scenarios to include «active» classes
More Information