Better serialisation strategy for sample app
Nicer deserialisation