Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add RoutingDHT struct that implements the routing.Routing interface and embeds the DHT #929

Closed
dennis-tra opened this issue Sep 19, 2023 · 1 comment
Labels
nice-to-have Not required but certainly a nice thing to have v2 All issues related to the v2 rewrite

Comments

@dennis-tra
Copy link
Contributor

Given that many are not happy with the routing.Routing interface we could avoid "polluting" the DHT API with the routing.Routing methods. So I propose to do the following:

type RoutingDHT struct {
    *DHT
}

var _ routing.Routing = (*RoutingDHT)(nil)

func NewRoutingDHT(d *DHT) *RoutingDHT {
    return &RoutingDHT{DHT: d}
}

// routing.Routing methods...

@iand
Copy link

iand commented Oct 2, 2023

Migrated to probe-lab/zikade#30

@iand iand closed this as completed Oct 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
nice-to-have Not required but certainly a nice thing to have v2 All issues related to the v2 rewrite
Projects
None yet
Development

No branches or pull requests

2 participants