Use json for encoding/decoding. However, this breaks duplex.
Fix reflection decoding with JSON