Fix encoding race condition in map data attachment.

Concurrent serialization threads can be encoding an object.
Use temporary arrays to construct the serialized format and
then publish the temporary arrays.
Not tested! Initial commit of versions branch.

Still need to handle our smart byte[] caching. The
cache will need to be invalidated when we are upgrading
binary versions. Also still needs to run through nightly tests.
Merge branch 'squashed_sparsepage_versions' of github.com:addthis/hydra into squashed_sparsepage_versions