serialization: add an example of a custom serializer