4. Chapter 4: Inter-process Communication

4.11. External data representation and marshaling introduction

Why does the communication data need external data representation and marshaling?

  • Different data format on different computers, e.g., big-endian/little-endian integer order, ASCII (Unix) / Unicode character coding

How to enable any two computers to exchange data values?

  • The values be converted to an agreed external format before transmission and converted to the local form on receipt
  •  The values are transmitted in the sender’s format, together with an indication of the format used, and the receipt converts the value if necessary

External data representation

  • An agreed standard for the representation of data structures and primitive values

Marshaling (unmarshaling)

  • The process of taking a collection of data items and assembling them into a form suitable for transmission in a message
  • Usage: for data transmission or storing in files

Two alternative approaches 

  • CORBA’s common data representation / Java’s object serialization