5. Event flow
This chapter describes the flow of events in the system accompanying main
user actions. The set of actions includes:
Description:
Logging into the system is the first activity each user has to perform before
using the system. Logging will be done on the base of two parameters typed
by hte user: name and password. System will verify these parameters, grant
user specific privileges and enable user to perform the following actions.
Events:
- User types username and password to Control Application
- Demon send the information to Central Server (user id, user passwd)
- Data is verified in the database
- Central server returns user rights to Control Application (user rights)
- Central server returns existing sessions (session list)
Description:
After finishing working user has to log off from the system. This will remove
him from all the virtual connections he was participating and close all
the applications
Events:
- User select exit option from Control Application (exit)
- Demon send the information to Central Server (exit)
- Central Server updates information about virtual connections
- Demon closes all running client applications.
Description:
This activity will enable user to launch application on local host. The
actions performed by user will not be shared with any other users. They
will be sent to central server and logged in the database. It will be possible
for other users in the future to join this application from remote host
and start collaborative session.
Events:
- User chooses application in Control Application (app type)
- Information from Control Application goes to the demon (app type)
- Demon sends the information to the Central Server, information is written
to the database, virtual connection is established (app type)
- Central Server generates unique application id and sends it to the Demon
(app id)
- Demon generates new port number (port number)
- Demon launches proper application with number of port (port number)
Description:
This activity allows a user to launch new application and connect it to
an existing session. Control application on local host will display all
possible sessions user has rights to connect to.
Events:
- User chooses the session from Control Application (session id)
- Information is sent to Central server through the demon (session id)
- Database checks if master for this session exists, if so he/she is notified
(user id)
- If master agrees for joining another virtual connection is created and written
in the database. The application id is added to the session list
- Demon on initiator's machine is notified (accept)
- Demon launches the application and starts delivering messages to it -> goto: 5.3. Launching local application
Description:
This activity allows a user to connect already running application to an
existing session. Control application on local host will display all possible
sessions user has rights to connect to.
Events:
- User selects session from the list of session he/she has rights to connect
to (session id)
- Information is sent to Central server through the demon (session id)
- Database checks if master for this session exists, if so he/she is notified
(user id)
- If master agrees for joining another virtual connection is created and written
in the database. The application id is added to the session user list
- Demon on initiator's machine is notified (accept)
Description:
This action will launch application of a given type on the host of another
user currently logged in the system. We assume that before launching application
on remote host user will have application of this type running locally.
Before launching application remote user must confirm it. After remote application
is running it creates a session with the local application on the initiator's
host. If application uses master-slave mode initiator becomes master of
the session. Initiator has to be master of the given session.
Events:
- User chooses remote launching option in Control Application and remote user
id (session id, user id)
- Remote user is notified with a message that application is about to start,
he must accept it (app type, master user id)
- Server generates new application id and sends it to the remote user demon
(app id)
- New virtual connection is created (app id is added to the session list)
and message is sent to remote user's demon (app id)
- Remote user demon generates port number and launches application (port number)
Description:
If an application use master-slave mode there is one application transmitting
events called 'master' and several 'slaves' receiving events and changing
their state accordingly. Changing to master mode may be invoked by user
with proper rights for an application running in client mode. The application
becomes then master of the session and start transmitting events.
Events:
- User chooses change to master for a given session in Control Application
(session id)
- Information goes to the demon (session id)
- Demon sends message to Central Server (session id)
- Central Server sends information to current session master (user id)
- When master agrees for change, server sends info to all users (session id,
user id)
- All other participants are notified (user id, session id)
- Information about master in the database is updated (user id, session id)