handler

package
v0.7.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 30, 2023 License: Apache-2.0, MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler added in v0.7.0

type Handler struct {
	// contains filtered or unexported fields
}

handler provides request handling functionality for the find server that is common to all protocols.

func New added in v0.7.0

func New(indexer indexer.Interface, reg *registry.Registry, indexCounts *counter.IndexCounts) *Handler

func (*Handler) Close added in v0.7.0

func (h *Handler) Close()

func (*Handler) Find added in v0.7.0

func (h *Handler) Find(mhashes []multihash.Multihash) (*model.FindResponse, error)

Find reads from indexer core to populate a response from a list of multihashes.

func (*Handler) GetProvider added in v0.7.0

func (h *Handler) GetProvider(providerID peer.ID) ([]byte, error)

func (*Handler) GetStats added in v0.7.0

func (h *Handler) GetStats() ([]byte, error)

func (*Handler) ListProviders added in v0.7.0

func (h *Handler) ListProviders() ([]byte, error)

func (*Handler) RefreshStats added in v0.7.0

func (h *Handler) RefreshStats()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL