Java serialization ways performance comparison