adminhttpclient

package
v0.0.0-...-403c8b4 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2022 License: Apache-2.0, MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client is an http client for the indexer finder API,

func New

func New(baseURL string, options ...httpclient.Option) (*Client, error)

New creates a new admin HTTP client.

func (*Client) Allow

func (c *Client) Allow(ctx context.Context, peerID peer.ID) error

Allow configures the indexer to allow the peer to publish messages and provide content.

func (*Client) Block

func (c *Client) Block(ctx context.Context, peerID peer.ID) error

Block configures indexer to block the peer from publishing messages and providing content.

func (*Client) ImportFromCidList

func (c *Client) ImportFromCidList(ctx context.Context, fileName string, provID peer.ID, contextID, metadata []byte) error

ImportFromCidList process entries from a cidlist and imprts it into the indexer.

func (*Client) ImportFromManifest

func (c *Client) ImportFromManifest(ctx context.Context, fileName string, provID peer.ID, contextID, metadata []byte) error

ImportFromManifest processes entries from manifest and imports them into the indexer.

func (*Client) ImportProviders

func (c *Client) ImportProviders(ctx context.Context, fromURL *url.URL) error

ImportProviders

func (*Client) ListLogSubSystems

func (c *Client) ListLogSubSystems(ctx context.Context) ([]string, error)

func (*Client) ReloadConfig

func (c *Client) ReloadConfig(ctx context.Context) error

ReloadConfig reloads reloadable parts of the configuration file.

func (*Client) SetLogLevels

func (c *Client) SetLogLevels(ctx context.Context, sysLvl map[string]string) error

func (*Client) Sync

func (c *Client) Sync(ctx context.Context, peerID peer.ID, peerAddr multiaddr.Multiaddr, depth int64, resync bool) error

Sync with a data peer up to the latest ID.

Jump to

Keyboard shortcuts

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