thread serializer/deserializer for cache