1 / 35

Message Based Communication

Message Based Communication. TANENBAUM-Chapter 2. Message Oriented Communication. RPC and RMI type firmware is not always desirable or even practical In such cases messaging is the way to go! Subject of concern in communication Persistence Transient Asynchronous Synchronous.

Download Presentation

Message Based Communication

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Message Based Communication TANENBAUM-Chapter 2

  2. Message Oriented Communication • RPC and RMI type firmware is not always desirable or even practical • In such cases messaging is the way to go! • Subject of concern in communication • Persistence • Transient • Asynchronous • Synchronous

  3. Persistence and Synchronicity in Communication (1) 2-20 • General organization of a communication system in which hosts are connected through a network and messages are passed and queued in an asynchronous manner. • Thus, persistence in comm is achieved.

  4. Example: Persistence and Synchronicity in Communication (2) • Persistent communication of letters back in the days of the Pony Express.

  5. Persistence and Synchronicity in Communication (3) 2-22.1 • Persistent asynchronous communication • Persistent synchronous communication

  6. Persistence and Synchronicity in Communication (4) 2-22.2 • Transient asynchronous communication • Receipt-based transient synchronous communication

  7. Persistence and Synchronicity in Communication (5) • Delivery-based transient synchronous communication at message delivery • Response-based transient synchronous communication

  8. Message Based Transient Communication: Berkely Sockets • Messaging through transport level sockets • Sockets form an interface to transport layer • Socket is an operating system abstraction over the end-to-end communication protocol • UNIX derivative OSs are the first in providing socket interface to TCP of TCP/IP protocol suit • So called, well-known port numbers together with IP numbers are used to bind to a socket…

  9. Berkeley Sockets (1) • Socket primitives for TCP/IP.

  10. Berkeley Sockets (2) • Connection-oriented communication pattern using sockets.

  11. Message-orientedTransient Communication: MPI • Message passing middleware standard • MPI is developed to provide a transport layer independency or more transparency • MPI provides mainly transient communication, could be synch or asynch • MPI library can be tailored to high speed communication, usually provided as proprietary libraries • MPI is developed for parallel application, where each group and a process with the group are assigned identifiers

  12. The Message-Passing Interface (MPI) • Examples for some of the most intuitive message-passing primitives of MPI. There are over 100 MPI functions, used especially to improve communication efficiency

  13. Message Queing Model • Targeted to support non time critical persistent asynchronous transmission • Each receiving application has its own private queue, to which messages are delivered, with no guarantee for when they will be processed • The sender and receiver queues need to be globally identified • Queues are managed by queue managers • So called message brokers can be used to transfer a message into the format acceptable by the end receiver…

  14. Message-Queuing Model (1) 2-26 • Four combinations for loosely-coupled communications with respect to queues.

  15. Message-Queuing Model (2) • Basic interface to a queue in a message-queuing system.

  16. General Architecture of a Message-Queuing System (1) • Mapping queue-level names to network locations, same as in DNS . Normally queues are managed by queue managers. Static mapping is easier dynamic mapping is more complex.

  17. General Architecture of a Message-Queuing System (2) 2-29 • The general organization of a message-queuing system with routers, that know about network topology, where every queue manager needs to know the nearest router, malticasting can also be done.

  18. Message Brokers 2-30 • The general organization of a message broker in a message-queuing system, used to convert one message format to another. Message broker is an application level message converter. A database should be used to allow rule based format conversions.

  19. Message Brokers (cont.) • General message queues are aimed to support persistent communication for the end user. • Although e-mail systems behaves similarly they are not to guarantee message delivery, message priorities, logging facilitis, multicasting, load balancing, fault tolerance, etc.

  20. Example: IBM MQSeries 2-31 • General organization of IBM's MQSeries message-queuing system. a MCA-Message Channel Agent manages two ends of a message channel, • This is primarily aimed at mainframe database applications • Message channels between QM are implemented in TCP connection, and managed by Message Ch Agent-MCA.

  21. Properties of MCA in IBM MQseries • Some attributes associated with message channel agents-MCA. Sending and receiving MCAs must be compatible in terms of rules of communication between them

  22. Message Transfer in IBM MQSeries(1) • The general organization of an MQSeries queuing network using routing tables and aliases. • A message header, in addition to the send queue address, has to have the address of the queue manager-QM and the destination queue under that QM

  23. Message Transfer in MQSeries(2)Primitives available in an IBM MQSeries MQI • Message Queue Interface-MQI is a simple programming interface for the applications. • MQSeries provides these facilities to applications when the messages have arrived

  24. Stream Oriented Communication(1) • In digital transmission of video and voice the timing is important. This depend humans’ physical hearing and vision abilities… this is continuous media (CM) domain… The transmission has to be in streams rather than self contained messages. • So, which facilities should a distributed system provide for such CM streams transmission: • Temporal relationship between different items of CM is crucial for correct interpretation of such data

  25. Stream Oriented Communication(2) • CM is supported by data streams, because of existence of temporal relationship between the data items. • Temporal (time dependent) data transmission is generally provided by so called data streams. • Asynchronous tr mode: no limits are defined • Synch tr mode: max end-to-end delay is defined • Isochronous tr mode: max and min end-to-end delay is defined • Complex streams have more than one sub stream, e.g., stereo audio can have two audio streams… • Streams can be multicast between one source and a number of sinks and filtered if needed…

  26. Data Stream (1) • Setting up a stream between two processes across a network.

  27. Data Stream (2) 2-35.2 • Setting up a stream directly between two devices.

  28. Data Stream (3) • An example of multicasting a stream to several receivers.

  29. Stream Comm: Quality of service (QoS) • QoS for CM tr can be defined in terms of timeliness, volume, and reliability • In addition to time requirements, in an application, using so called bucket algorithm, service requirements may include • loss sensitivity of data items • Minimum delay noticed by the receiver • Max delay variation • Quality of guarantee • QoS requires allocation of resources, usually, in terms of processing capacity, bandwidth, buffers… • There is no best model for specifying QoS parameters • Resource reSerVation Protocol is a transports level for routers to tune to the QoS requirements, by the servers.

  30. Specifying QoS (1) • A flow specification.

  31. Specifying QoS (2): Example method • The principle of a token bucket algorithm. Irregular data stream is regulated at the bucket output.

  32. Setting Up a Stream: RSVP-Resource reSerVation Protocol • The basic organization of RSVP-Resource reSerVation Protocol- for resource reservation in a distributed system, to achieve the required QoS.

  33. Synchronization Example (1) • In multimedia systems this is very important, as more than one stream may come together to meet the application requirements • For example • Two voice streams for stereo voice applications • Presentations slides with voice streams • Video stream with voice stream: lip synchronization! • Synchronization at the lowest level is conducted by the operating system, for example switching between video frames and voice frames, • The low level communication channels must be able meet such requirements

  34. Synchronization Example (2) • The principle of explicit synchronization on the level data unit: video and voice

  35. Synchronization using Middleware (3) 2-41 • The principle of synchronization as supported by high-level interfaces. Different streams are first converted into discrete stream packets, with synchronization information, which can then be multiplexed into one stream as in MPEG-2 standard.

More Related