Documentation ¶
Index ¶
- type PeerEntry
- type PeerIndex
- type Tavern
- func (tavern *Tavern) Announce(ctx context.Context, req *connect.Request[tavernv1.AnnounceRequest]) (*connect.Response[tavernv1.AnnounceResponse], error)
- func (tavern *Tavern) List(ctx context.Context, req *connect.Request[tavernv1.ListRequest]) (*connect.Response[tavernv1.ListResponse], error)
- func (tavern *Tavern) ListenAndServe(addr string, tlsConfig *tls.Config) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Tavern ¶
type Tavern struct { AnnounceInterval int64 tavernv1connect.UnimplementedTavernServiceHandler // contains filtered or unexported fields }
func (*Tavern) Announce ¶
func (tavern *Tavern) Announce(ctx context.Context, req *connect.Request[tavernv1.AnnounceRequest]) (*connect.Response[tavernv1.AnnounceResponse], error)
Announce a new peer for the given hash.
func (*Tavern) List ¶
func (tavern *Tavern) List(ctx context.Context, req *connect.Request[tavernv1.ListRequest]) (*connect.Response[tavernv1.ListResponse], error)
List all announced peers for the given hash.
Click to show internal directories.
Click to hide internal directories.