In order to be able to make assertions about how the state of all components changes over time and to make debugging easier, we dump and save the state of components in json format when they receive an event.
In golang we currently use encoding/json for this, but given that it simply drops private fields this isn't ideal (which leads to workarounds such as introducing an extra datatype which exposes the private fields).
Perhaps an other library which also encodes private fields can be used, e.g. https://github.com/json-iterator/go.