Menu

#14 Serialized object transfer

Server
open
nobody
Defect (22)
5
2009-02-13
2009-02-13
No

The current version (_VERSION) is used in object headers and elsewhere to make sure that incompatible versions of a serialized object are detected rather than generating subtle errors.   Subtle errors may also occur when a serialized object is transferred from one platform to another if the endian or the native size of an integer (NUM) is different even if the object header has the same version.  Both types of errors can be avoided if a platform component is added to the version which distinguishes between an object created on a platform that is different from the current platform.  This component only has to distinguish between platforms that have a different endian or a different native size of NUM.   For instance a 64-bit Windows and a 64-bit Linux platform both running on a computer with an  Intel or AMD processor may exchange objects of the same version without any problem.  However, a 32-bit Windows based machine may not use an object created on a 64-bit Windows based machine even though they used the same operating system.  Since a cell processor employs a different memory order for multi-byte integers from an Intel processor, it is not possible to transfer serialized objects between these two machines

Discussion


Log in to post a comment.