implement externalizable for faster serialization . this isoptional and you can simply implement serializable . concode_field_sep long id concode_field_sep void writeExternal concode_elem_sep int hashCode concode_elem_sep boolean equals concode_elem_sep int affinityKey concode_elem_sep int affinityKey concode_elem_sep long getId concode_elem_sep String toString
void function ( ObjectInput arg0 ) { id = arg0 . readLong ( ) ; }