Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is multiplex socket communication?

I searched the "multiplex socket" on internet, but couldn’t found out the difference between multiplex socket and normal socket behaviors.

Normal socket also can communicate on both directions (read and write stream).

I think I must understand wrong about concept of multiplex, welcome your opinion about multiplex communication, Thanks!

EDIT: I use Java to implement the multiplex socket.

like image 456
卢声远 Shengyuan Lu Avatar asked Apr 02 '11 09:04

卢声远 Shengyuan Lu


People also ask

Which condition is used for multiplexing?

Multiplexing is used in a wide range of industries to facilitate both analog and digital communications. It was first introduced in the 1870s to support telegraphy but has since become a mainstay in telecommunications, such as radio, television and telephone.

Why I O multiplexing is required?

I/O multiplexing is typically used in networking applications in the following scenarios: When a client is handling multiple descriptors (normally interactive input and a network socket) When a client to handle multiple sockets at the same time (this is possible, but rare)

What is multiplexing with select?

I/O multiplexing—select() Like asynchronous I/O, the select() API creates a common point to wait for multiple conditions at the same time. However, select() allows an application to specify sets of descriptors to see if the following conditions exist: There is data to be read.


1 Answers

AFAIK, Multiplex communication is the sharing of a small number of sockets (e.g. one) to pass data for multiple higher level streams e.g. topics or queues.

like image 196
Peter Lawrey Avatar answered Sep 20 '22 10:09

Peter Lawrey