2

I have two questions about using Send and Receive signals in UML activity diagrams. Diagrams for two possible approaches I could think of:

enter image description here

  1. I usually see send and receive signals in tandem. But what if the send signal fails? Can we split the send and receive signals and include an error routine in between?
  2. When we model UML Diagrams for a web services, how the server processes a request is beyond my system scope. In that case, how do we model receiving a response?

If someone can see and confirm which on of these diagrams are right, I will be grateful!

Thanks in advance, Rajesh

qwerty_so
  • 35,448
  • 8
  • 62
  • 86

1 Answers1

2
  1. Your first diagrams shows nicely what happens if the send fails. An error is logged and the process finalizes. The server of course does not do anything.
  2. If the server side is not of interest, you do not need to model it. You can use Send and Receive events (see below) to model control flow going to a server or coming from a server.

enter image description here

Having said this, your 2nd picture should use the above Send/Receive. And as you do not model the server it's probably advisable to leave it all out of the diagram.

Personally, I would model some basics from the server side, namely the receive and send part, just as you did in the first diagram. As this implies a synchronous flow, the Send/Receive will give you the ability to show some asynchronous processing in this case. Just (abbreviated) like so:

enter image description here

qwerty_so
  • 35,448
  • 8
  • 62
  • 86
  • Thank you so much for your response! To note my understanding, 1. Send and receive are essentially signals. So we will use the signal symbols. 2. It is okay to put an error routine to take care of send failure. On the server side, may be I was not very clear. In this case specifically, we are going to use a public service that exposes a service. So I am under the opinion that we are not aware of how it is done. So we will keep the server side out of the description. Thanks again! – rajesh chandra Aug 19 '16 at 07:25
  • Although you do not model the details inside the server, you should show the send/receive part (like in your first picture or in mine above). – qwerty_so Aug 19 '16 at 09:28