registry

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Registry

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

Registry is a thread-safe in-process capability index. buckets is keyed by "namespace/name" of the owning ArkRegistry CR so multiple ArkRegistry instances coexist without overwriting each other.

func (*Registry) AgentCount

func (r *Registry) AgentCount() int

AgentCount returns the total number of indexed agents across all buckets.

func (*Registry) Rebuild

func (r *Registry) Rebuild(key string, agents []arkonisv1alpha1.ArkAgent)

Rebuild atomically replaces the entries for one ArkRegistry CR (key = "namespace/name"). Does not touch other registries' buckets.

func (*Registry) Remove

func (r *Registry) Remove(key string)

Remove deletes the bucket for a deleted ArkRegistry CR.

func (*Registry) Resolve

func (r *Registry) Resolve(req ResolveRequest) string

Resolve returns the agent name that best matches the request, or "" if no agent matches.

func (*Registry) Snapshot

func (r *Registry) Snapshot() []arkonisv1alpha1.IndexedCapability

Snapshot returns a read-only capability snapshot across all buckets for status reporting.

type ResolveRequest

type ResolveRequest struct {
	Capability string
	Tags       []string
	Strategy   arkonisv1alpha1.RegistryLookupStrategy
}

ResolveRequest carries the parameters of a single registry lookup.

Jump to

Keyboard shortcuts

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