Add key for the "context" member in the "event" message
Add new state for context member
Add helper for calculating number of written bytes
Add helper for generating a new key in the buffer
DRAFT for serialize_event()