Skip to content

Create Event class to use with the serializer. #132

@marcosschroh

Description

@marcosschroh

When encode_record_with_schema_id or encode_record_with_schema is called with data/record, these methods should return an Event object containing the data/record, the payload (the data encoded), the schema_id used to serialize the data and possible kafka_headers rather than the payload encoded.

We want to do this in order to provide more information to the user.

The same should happen with the decode_message. Related to #129

class Event:
    def __init__(self, data, payload, schema_id):
        ...
   
    def headers(self):
       ...

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions