1.

How To Improve Java Serialization Performance?

Answer»

Java serialization performance directly rely on the number and size of attributes in the Java object. To improve the performance,

  • Mark the unwanted or non Serializable attributes as transient.
  • Save only the STATE of the object, not the DERIVED attributes.Some times, serializing them can be expensive.
  • Serialize attributes only with NON-default values.
  • Use Externalizable INTERFACE and implement the readExternal and writeExternal methods to dynamically IDENTIFY the attributes to be SERIALIZED.

Java serialization performance directly rely on the number and size of attributes in the Java object. To improve the performance,



Discussion

No Comment Found