Serialization
+Serialization is the process of translating data structures or object state into a format that can be stored (for example, in a file or memory buffer) or transmitted (for example, across a network connection link) and reconstructed later (possibly in a different computer environment).
+ +Uses
+
-
+
- Transferring data through the wires (messaging). +
- A method of storing data (in databases, on hard disk drives) +
- A method of remote procedure calls +
- A method for distributing objects +
- A method for detecting changes in time-varying data +
Drawbacks
++
-
+
- Serialization breaks the opacity of an abstract data type by potentially exposing private implementation details. +
- Trivial implementations which serialize all data members may violate encapsulation. +
- To discourage competitors from making compatible products, publishers of proprietary software often keep the details of their programs' serialization formats a trade secret. +
- Many institutions, such as archives and libraries, attempt to future proof their backup archives—in particular, database dumps—by storing them in some relatively human-readable serialized format. +
Formats
++
-
+
- Xerox Network Systems Courier technology in the early 1980s influenced the first widely adopted standard +
- Sun Microsystems published the External Data Representation (XDR) in 1987. +
- In the late 1990s, a push to provide an alternative to the standard serialization protocols started: XML was used to produce a human readable text-based encoding. +
- JSON is a lighter plain-text alternative to XML which is also commonly used for client-server communication in web applications. JSON is based on JavaScript syntax, but is supported in other programming languages as well. +
+ +