Message-Passing Communication Analyzer By Poonam Bijlani CSE 775- Distributed Objects Prof. Jim Fawcett - PowerPoint PPT Presentation

1 / 26
About This Presentation
Title:

Message-Passing Communication Analyzer By Poonam Bijlani CSE 775- Distributed Objects Prof. Jim Fawcett

Description:

Title: Message-Passing Communication Analyzer By Poonam Bijlani CSE 775- Distributed Objects Prof. Jim Fawcett Author: Oom Last modified by: Jim Fawcett – PowerPoint PPT presentation

Number of Views:129
Avg rating:3.0/5.0
Slides: 27
Provided by: Oom
Category:

less

Transcript and Presenter's Notes

Title: Message-Passing Communication Analyzer By Poonam Bijlani CSE 775- Distributed Objects Prof. Jim Fawcett


1
Message-Passing Communication AnalyzerByPoonam
BijlaniCSE 775- Distributed ObjectsProf. Jim
Fawcett
2
Project Overview
  • The message passing Communication Analyzer is
    implemented as a two way communication subsystem
    using .NET Remoting.
  • Xml Messages are passed between the client and
    server.
  • The system can be configured in any of the
    following activation modes
  • Singleton one object for all clients
  • Single Call one object created for each call to
    the server
  • Client Activated one object for each client
  • Configuration files are used to establish any of
    the activation modes

3
Project Overview..contd
  • Sponsors are implemented to prevent the
    communication object from timing out if it is
    implemented as singleton or client activated.
  • Average time to service a message is found by
    sending a stream of continuous messages between
    client and server.

4
Context Diagram
Communication using .Net Remoting
Xml Messages
Messages
I/P
Marshal ByRef
User Interface
Input and
Client
Proxy
Server
Output
O/P
Object
Errors
Errors
Errors
Errors
5
GUI
6
Client Classes
7
Server Classes
8
Configuration files, Controls and Interfaces
  • Configuration Files used to set the remoting
    infrastructure between client and server. Also
    used to set the activation model.
  • Controls
  • XML Generator Generates XML messages of required
    size
  • HiRes Timer Calculates the time, in
    microseconds, to send and receive a message from
    the client to the server and back.
  • Interfaces
  • ILease and ISponsor Used for Lifetime management
    of Client Activated and Singleton Objects

9
Sponsors
  • .NET Remoting uses a lease-based form of
    distributed garbage collection to manage the
    lifetime of remote objects.
  • MyClientSponsor Class on the client side is used
    to renew the lease for Singleton and Client
    Activated objects after they have expired
  • The sponsor implements the ISponsor interface and
    registers the Sponsor using the Register( )
    method of the ILease interface.
  • The Lease Manager calls the renewal( ) method to
    renew the lifetime of the objects. I have used a
    time span of 20 seconds which means that the
    Lease Manager renews the objects lease time by 20
    seconds each time it calls the renewal ( )
    method.

10
Client- Thread and Queues
  • Queues
  • Send Queue
  • Receive Queue
  • Threads
  • Main Thread- Handles GUI and queues request for
    server
  • Communication Thread Takes care of communication
  • Receive Thread De-queues messages posted by the
    communication thread and populates GUI

11
Server Threads and Queues
  • Queues
  • Send Queue
  • Receive Queue
  • Blocking Queues implemented on both client and
    server to avoid wasting CPU cycles
  • Threads
  • Communication Thread- Takes care of communication
  • Worker Thread- Responsible for serving the
    Clients requests

12
Communication Subsystem
SERVER
Communication
Communication
CLIENT
Thread
Thread
RECIEVE Q
Child Thread
SEND Q
dequeues,
processes request
enqueues
Main Thread
response
XML MESSAGES
RECIEVE Q
Main Thread
enqueues server
Receiver
requests/
Thread
notifications
SEND Q
Singleton/
SingleCall/
ClientActivated
Remotable
Object
13
Client Activity Diagram
14
Server Activity
15
Event Trace Diagram
16
Singleton 1 Client
17
Single Call 1 Client
18
Client Activated 1 Client
19
Comparative Graph- 1 Client
20
Singleton Multi Client
21
Single Call Multi Client
22
Client Activated Multi Client
23
Comparative Graph- Multi Client
24
Uses
  • Calculate performance of distributed applications
    using messages up to 100Kb eg. Chat Applications
  • Can be modified by using PassByReference file
    transfer to measure the performance of
    distributed file systems, eg. FTP
  • Can be used to compare speeds of different
    networks eg. Dial-up, Broadband etc.

25
Conclusion
  • A message passing communication analyzer was
    successfully built and implemented using .NET
    remoting
  • Further, it was operated in three modes
    Singleton, Single Call and Client Activated
  • A HiRes Timer was used to analyze the performance
    of the system with increasing message sizes for a
    single client and up to 8 clients for a single
    message size.
  • Tests indicated that distributed applications
    where state preservation is not required, a
    client activated object should be preferred over
    Single Call.
  • Further choice of activation mode depends on the
    specific requirements of the application under
    consideration.

26
Thank You
Questions?
Write a Comment
User Comments (0)
About PowerShow.com