livepeer / livepeer/go-livepeer-basicnet

Code generation for messages

Open
#33 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
18
Forks
6
PR merge metrics
No merged PRs in 30d

Description

Currently we use a mix of encodings: JSON to wrap Golang gob-encoded messages.

* The gob encoding is not portable. While theoretically documented in https://golang.org/pkg/encoding/gob/ , in practice gob encoding restricts usage to Go-based clients only. We should use a more portable serialization format so nodes can be developed in other languages.
* Consider whether we should keep the current JSON wrapper: with a typed, schema-based serialization (capnp, protobufs), we can rely more on code generation, and do less manual handling for each message, reducing the amount of boilerplate (eg, `data.go`).
* Fine grained versioning built into the networking protocol, assisted by the protocol compiler. https://capnproto.org/language.html#evolving-your-protocol

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 reading data.go and tracing how the networking protocol currently wraps and decodes gob messages. Compare the issue's proposed capnp or protobuf approaches, then define a selected portable schema, generated message handling, and protocol versioning that supports non-Go clients.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, json
Domain
distributed-systems, networking
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.