IBM Support

Using the same operation in IBM Rhapsody to act as both synchronous and asynchronous.

Question & Answer


Question

Is there a way to use same operation to act both as synchronous and asynchronous depending on the parameter that is passed to it in IBM Rhapsody?

Cause

In Rhapsody synchronous and asynchronous functions are represented as different message types:

  • While creating new functions, Synchronous functions are created as operations, whereas asynchronous functions are created as Events.
  • In modeling, synchronous functions are represented as Messages (Filled arrowheads), whereas asynchronous functions are represented as Events (Stick arrowheads)

Can the same operation act both as synchronous or asynchronous function based on parameters that are passed to it? Is it possible in rhapsody by any means?

Answer

No, they must be modeled separately. This is following the notation from UML standard.

Mixing synchronous and asynchronous messages within the same object is not recommended as it can block the message queue, which can lead to dropped asynchronous (events) messages. The recommended practice is to use Synchronous (triggered operations) messages to call other external objects, rather than within its own object.

[{"Product":{"code":"SSB2MU","label":"IBM Engineering Systems Design Rhapsody"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"General Information","Platform":[{"code":"PF016","label":"Linux"},{"code":"PF033","label":"Windows"}],"Version":"8.0;8.0.1;8.0.2;8.0.3;8.0.4;8.0.5;8.0.6;8.1;8.1.1;8.1.2;8.1.2.1;8.1.3;8.1.4;8.1.5;8.2;8.2.1","Edition":"Rational Rhapsody Architect for Software;Rational Rhapsody Architect for Systems Engineers;Rational Rhapsody Designer for Systems Engineers;Rational Rhapsody Developer","Line of Business":{"code":"LOB59","label":"Sustainability Software"}}]

Product Synonym

Rational Rhapsody

Document Information

Modified date:
27 May 2022

UID

swg21991453