linkedin / linkedin/goavro

Supporting Custom Codecs

Open
#288 1 comment 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
1.1k
Forks
232
PR merge metrics
No merged PRs in 30d

Description

Hello!

I'm fairly new to the Go ecosystem and was curious whether supporting custom codecs would potentially be on the roadmap for this project.

In my particular case, I have a custom type which wraps a fixed type and requires additional encoding/decoding steps. More specifically, my type has an additional layer of compression which needs to be handled during textual serialization. In Ruby, I can use a library such as [Avromatic](https://github.com/salsify/avromatic?tab=readme-ov-file#custom-type-configuration) to define custom encoding/decoding steps for a custom type I might be registering.

Perhaps there's some Go pattern I'm unaware of that would allow me to do this, but for now I've landed on just forking the project and augmenting the default symbol table to include my custom type with its own codec. However, I'd like to avoid maintaining a fork of this project longterm, and ideally define my custom logic in the project that includes `goavro`.

I've searched through a few issues, and If I'm not misunderstanding, this [issue](https://github.com/linkedin/goavro/issues/253) seems to resonate with my problem, in that support for custom textual encoders/decoders would helpful. However, given the timeline, I'm not entirely sure whether it's still being pursued.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing issue #253 and the current default symbol table, which the report identifies as the place currently being extended for custom types. Determine whether an existing extension point supports custom textual encoding and decoding without a fork. Done means the required custom codec behavior can be defined by a project using goavro and the approach is documented or otherwise demonstrated.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.