0% found this document useful (0 votes)
36 views22 pages

3 - Advanced Modeling Techniques

Uploaded by

vgg67916
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
36 views22 pages

3 - Advanced Modeling Techniques

Uploaded by

vgg67916
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 22

Advanced modeling

techniques

Software Engineering
Topics

• Modeling more than one service

• Services as submachine states

• Service sessions as concurrent parts

2 Software Engineering
ICU case study

• ICU: “I see you” system


• Service for a mobile app
o The mobile sends a message
o The app provides a picture of the user’s position

3 Software Engineering
ICU case study

Service works as follows:


• The user sends a service request through the app
• The service requests the GPS position of the phone
• The phone sends the GPS position to the server
• The service uses the GPS position to search for an image
using the Google Earth API
• The service sends the image to the user

4 Software Engineering
ICU extension

New service that works as follows:


• User can store favorite places in the system
• User can request the closer favorite position
• The system will respond with the place and its distance
to the user

5 Software Engineering
System modeling
scheme
SW Context SW System

Components
diagram

Sequence diagram

State machine
diagram

Source Code

6 Software Engineering
SW Context
• Unnecessary to change the SW context components
diagram, we just modify the use cases diagram

• Necessary to create 1 additional sequence diagram in


the context per each new use case
7 Software Engineering
SW System
• The new service requires us to store data
o Where do we store it?
o How do we model this interaction?

• Necessary to create 1 additional sequence diagram in


the system per each new use case

• Modifications to the state machine

8 Software Engineering
Separation of
concerns
• Modification of the system components diagram to
evolve the architecture of the system

Consistency with internal sequence diagrams is critical!

9 Software Engineering
Separation of
concerns
• The archive component:
o Allows to isolate work on persistent data
o Provides a simple critical region to model DDBB systems that
work concurrently with our system
• Archive and process can be coded by different people

10 Software Engineering
Separation of
concerns
• We modify the state machine to include the new case

11 Software Engineering
Separation of
concerns

Many services  state machine becomes too complex

We aim to:
• Isolate reusable functions
• Separate independent concurrent tasks
• Separate different alternating services

For each service, we create one submachine state

12 Software Engineering
Submachine states
For each service, we create one submachine state

13 Software Engineering
Submachine states
Each submachine is defined through its own state machine

14 Software Engineering
Submachine states
Consistency!

15 Software Engineering
Concurrent parts
• So far, we only support one request of the ICU/Hotpos
service at the same time.

• We should assume:
o Several users can use the system concurrently
o The system may handle everybody at once, keeping data apart
o Some things take IRL time outside the system
o Concurrency improves overall throughput

• Goal: modify the diagrams to support several requests


at the same time.

16 Software Engineering
Concurrent parts
• Risk: services may confuse user’s data & comms

• Session solution: each initiative by a user is represented


by an instantiation of a state machine, with all the data
and communications related to the user

• Session generated when the user initiates a service, and


terminated when the service is finished

17 Software Engineering
Concurrent parts
• Modification to the system components diagram to
evolve the architecture: controller, process, archive

18 Software Engineering
Concurrent parts
• The controller stores users and their sessions, routing
users to their processes

19 Software Engineering
Concurrent parts

Controller does not need to route responses from archive


20 Software Engineering
Concurrent parts
• The sequence diagram must now be modified to include
these components, processes are created by the
controller through a creation message

21 Software Engineering
Concurrent parts
• The state machine also changes, adding a final state
that represents the termination of the session

22 Software Engineering

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy