1 / 24

Communication Services: Messages, Queuing, Multiplexing, and More

This chapter explores various communication services, including messages, queuing, multiplexing, message with reply, remote method invocation, and conversation. It also discusses examples and objectives of these services.

stayton
Download Presentation

Communication Services: Messages, Queuing, Multiplexing, and More

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. Chapter 12 by David G. Messerschmitt

  2. Communication services by David G. Messerschmitt

  3. Example communication services • Messages • Queuing and multiplexing • Message with reply • Remote method invocation • Conversation • Broadcast

  4. Some objectives • Allow modules to interact in the same way across different hosts as on a single host • Make it easier to develop applications by capturing common generic needs • Support a range of applications with distinct needs

  5. Message • The smallest unit of information meaningful to the sender and recipient • Recipient must be ready and listening • Directs or informs the recipient • Pure push model • Employs a send-receive protocol

  6. Supporting deferred applications • Queuing • Queuing allows a message to be sent even though the recipient is not waiting • The message sits in a queue somewhere in the infrastructure until it is actively retrieved by the recipient • Combines send-receive and request-reply protocols

  7. Participants in message with queuing Sender Recipient Send/ receive Queue Request/ response Sender can send message whenever it wants Recipient can access message whenever it wants Infrastructure

  8. Multiplexing • Multiplexing • Allows recipient to receive messages from two or more senders • How are the senders identified? • Presumes queuing: what if two messages are sent simultaneously? • Supported by Message Oriented Middleware (MOM)

  9. Multiplexing and queuing Sender1 Recipient Mux & queue Sender2 Recipient deals with one message at a time even if coming from many senders Infrastructure

  10. Example application: workflow Receiving Administrative assistants Purchasing Workers

  11. What message is not • Delivery may not be guaranteed • No shared context of messages from same sender to recipient • Application is free to create that context on its own • Messages may not be delivered in the same order as sent

  12. Message with reply • Service couples two messages: • Request and coupled response message • Sender freed of burden of associating response • Requests information or a service • Pure pull model • Immediate • Recipient presumes sender is waiting for reply and responds as quickly as possible

  13. RMI method: parameters return_values An action object-oriented programming is called a method Method invocation method: parameters return_values Remote method invocation (RMI)

  14. Sender is blocked waiting for response method: parameters -> return_values Client object Server object method,parameters Blocked: can’t do anything else Computes method() returns Time = Blocked waiting for response = Working on request

  15. Comparison Sender Recipient Sender Queue Recipient Send/receive Send/receive Message waiting Request/ response Request/ response = Work on message or request = Blocked waiting for response

  16. Conversation • Two-way exchange of messages • Messages in one direction are influenced by messages in the other • To maintain conversation • Messages should be delivered reliably • Messages should be delivered in the same order as sent • No coupling of replies with messages

  17. Session protocol A session typically provides guaranteed ordered delivery to maintain proper context Establish Conversation Disestablish

  18. Some advantages of sessions • Aids application by managing a shared context for a conversation • Identification, ordering, reliable delivery • Reduces overhead • Example: only one name server query • Security (Chapter 8) • Quality of service (Chapter 11)

  19. Examples • What are examples of applications that would naturally leverage: • Messages? • Queuing and multiplexing? • Message with reply? • Conversation?

  20. Multimedia record-store-playback Audio coder Audio decoder Record Playback One (big) message Storage Storage Video coder Video decoder

  21. Streaming multimedia Audio coder Audio decoder Video coder Video decoder

  22. A session supports streaming multimedia Accumulate audio in message Send message Time Receive message Playback audio in message Delay

  23. Delay and latency Message latency = time from sending of message until it is received in its entirety Time Delay = time elapsing between an event (or series of events) and its (their) representation

  24. Relationship of delay and latency Latency Time Delay Delay = latency (of network) + message accumulation time If delay is important, keep the messages short!

More Related