hostbus

package
v0.0.11-dev Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HostRegistrationBus

type HostRegistrationBus interface {
	Publish(ctx context.Context, bundle URLBundle) error
	Close() error
}

HostRegistrationBus is the public interface for publishing URL bundles. Implementations are package-private to prevent external construction.

func New

func New(subscriber chan URLBundle) (HostRegistrationBus, error)

New constructs a new host registration bus with the provided subscriber channel.

type Tag

type Tag struct {
	Key   TagKey
	Value string
}

Tag associates a tag key with a value.

type TagKey

type TagKey int

TagKey identifies a URL tag category.

const (
	TagKeyUnspecified TagKey = iota
	TagKeySource
	TagKeyRole
	TagKeyIndex
	TagKeyGroup
)

type URLBundle

type URLBundle struct {
	FetchedAt time.Time
	URLs      []URLRecord
}

URLBundle captures a set of URLs discovered by any component. It keeps transport hints generic and intentionally avoids OAuth-specific fields.

type URLRecord

type URLRecord struct {
	URL            *url.URL
	Description    string
	Tags           []Tag
	UnixSocketPath string
}

URLRecord describes a single URL plus optional metadata tags.

Jump to

Keyboard shortcuts

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