Compressed Multiaddr Combinations
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 20/100
- Issue type
- Feature
- Clarity
- Needs clarification
- Activity status
- Stale
- Tech stack
- go
- Domain
- networking
Research direction
Start by reviewing the existing multiaddr representation and wire-format handling, then compare the proposed OR-lists and DAGs against the open problems listed. Done would require an agreed scope and an implemented representation with transformation, change handling, and transmission or in-memory use addressed.
Written by the indexing model from the issue text.
Description
When handling many multiaddrs that have common prefixes, or sections, it has been discussed that it may be useful to have a format for expressing these as combinations, or DAGs. This is to allow much more compressed transmissions, and even in-memory representations.
For example, the list:
/ip4/1.2.3.4/tcp/4001/ipfs/Qmf8SVETTnpzzCJyurQa2ekxFwKnUNNYycLHsNfVjiq19B
/ip4/1.2.3.4/udp/4002/utp/ipfs/Qmf8SVETTnpzzCJyurQa2ekxFwKnUNNYycLHsNfVjiq19B
/ip4/127.0.01/tcp/4001/ipfs/Qmf8SVETTnpzzCJyurQa2ekxFwKnUNNYycLHsNfVjiq19B
/ip4/127.0.0.1/udp/4002/utp/ipfs/Qmf8SVETTnpzzCJyurQa2ekxFwKnUNNYycLHsNfVjiq19B
/ip6/::1/tcp/4001/ipfs/Qmf8SVETTnpzzCJyurQa2ekxFwKnUNNYycLHsNfVjiq19B
/ip6/::1/udp/4002/utp/ipfs/Qmf8SVETTnpzzCJyurQa2ekxFwKnUNNYycLHsNfVjiq19B
OR-Lists
It is an expansion of the combinations
/ip4/1.2.3.4 OR /ip4/127.0.0.1 OR /ip6/::1
/tcp/4001 OR /udp/4002/udt
/ipfs/Qmf8SVETTnpzzCJyurQa2ekxFwKnUNNYycLHsNfVjiq19B
This notation could be much more compressed way to represent these than the full list.
DAGs
Another such representation could treat it like a dag:
n0 := /ip4/1.2.3.4
n1 := /ip4/127.0.0.1
n2 := /ip6/::1
n3 := /tcp/4001
n4 := /udp/4002/udt
n5 := /ipfs/Qmf8SVETTnpzzCJyurQa2ekxFwKnUNNYycLHsNfVjiq19B
n6 := n0 OR n1 OR n2
n7 := n3 OR n4
n8 := n6 AND n7 AND n5
This one could also be very compressed, and allow representing much more versatile lists.
Some open problems with this:
- Transforming lists of addrs into these reprs.
- Dealing with changes efficiently (one node added or dropped) -- this may turn out pretty easy
- Use it for the wire format transmission of a big multiaddr set
- Use it for the in-memory representation of a big multiaddr set! (this could be very cool)
- Making all this super efficient.
- I'm not convinced how useful vs complex this would be.
- Opening to gather thoughts.
- Wonder if there's already some generic way of doing this over any set of strings that we can just use.
- Dominant language
- Go
- Stars
- 482
- Forks
- 87
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from multiformats/multiaddr
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
multiformats/multiaddr#181 ·
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
multiformats/multiaddr#178 · 4 comments ·
-
Difficulty 5/5 Over a week Newbie friendliness 10/100
multiformats/multiaddr#168 ·
-
Multiaddr URI scheme Open
Difficulty 5/5 Over a week Newbie friendliness 25/100
multiformats/multiaddr#165 · 2 comments · 1 reaction ·
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
multiformats/multiaddr#156 · 1 reaction ·
All issues in multiformats/multiaddr
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
Difficulty 1/5 Under an hour Newbie friendliness 84/100
-
enhancement needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
kind/cleanup
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
kubernetes-sigs/kueue#15947 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
sympozium-ai/sympozium#627 ·