registry

package
v1.3.1 Latest Latest
Warning

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

Go to latest
Published: Jan 30, 2026 License: MIT Imports: 10 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	URL          string        `yaml:"url" json:"url"`
	RetryMax     int           `yaml:"retry_max" json:"retry_max"`
	RetryWaitMin time.Duration `yaml:"retry_wait_min" json:"retry_wait_min"`
	RetryWaitMax time.Duration `yaml:"retry_wait_max" json:"retry_wait_max"`
}

Config holds configuration parameters for the registry client.

type RegistryClient

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

RegistryClient encapsulates the logic for calling the registry endpoints.

func New

func New(ctx context.Context, cfg *Config) (*RegistryClient, func() error, error)

New creates a new instance of RegistryClient.

func (*RegistryClient) Lookup

func (c *RegistryClient) Lookup(ctx context.Context, subscription *model.Subscription) ([]model.Subscription, error)

Lookup calls the /lookup endpoint with retry and returns a slice of Subscription.

func (*RegistryClient) Subscribe

func (c *RegistryClient) Subscribe(ctx context.Context, subscription *model.Subscription) error

Subscribe calls the /subscribe endpoint with retry.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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