Interface IBowireCatalogueProvider
- Namespace
- Kuestenlogik.Bowire.Sources
- Assembly
- Kuestenlogik.Bowire.dll
Extension point for "where does Bowire's URL/service list come
from" (#136) — sibling to IBowireProtocol (wire
plugins) and IBowireAuthProvider (sign-in plugins). Today
the workbench reads URLs from local config + the user-editable
sidebar; a catalogue provider augments (or replaces) that source
by reading from a service registry, a remote JSON document, or a
Bowire-agent hub.
public interface IBowireCatalogueProvider
Remarks
Concrete providers live either in core (local, http,
consul) or in optional sibling packages
(Kuestenlogik.Bowire.Catalogue.Kubernetes,
Kuestenlogik.Bowire.Catalogue.Agent) so heavyweight client
libraries only land in installs that opt-in. Discovery follows the
same assembly-scan pattern as
BowireProtocolRegistry: providers are picked up at
startup if their assembly is loaded.
At most one provider is active per process — selected by the
Bowire:Discovery:Catalogue:Provider appsettings key (or the
--catalogue-provider <id> CLI flag once the standalone
tool exposes it). When no provider is selected (the laptop
default), the catalogue endpoint returns an empty list and the
workbench keeps its current "manual URL entry only" behaviour.
Composes with Bowire:Discovery:UrlManagement (#92) — catalogue
entries and locally-added URLs are additive, with an origin chip
distinguishing them in the URL management view.
Properties
Id
Stable id used to select this provider in config (e.g.
"local", "http", "consul",
"kubernetes", "agent"). Compared case-insensitively
against the configured provider key.
string Id { get; }
Property Value
Name
Human-readable provider name for the Settings → Sources tab
and startup logs (e.g. "Local file",
"HTTP endpoint", "Consul").
string Name { get; }
Property Value
Methods
FetchAsync(CancellationToken)
Fetch the current catalogue snapshot. Called on a configurable refresh interval (default 5 minutes; see RefreshInterval) and on a manual trigger from the workbench UI.
Task<IReadOnlyList<BowireCatalogueEntry>> FetchAsync(CancellationToken cancellationToken)
Parameters
cancellationTokenCancellationTokenCancellation token — refresh cycles are bounded by the configured interval, so providers should respect it to avoid piling up overlapping fetches when an upstream is slow.
Returns
- Task<IReadOnlyList<BowireCatalogueEntry>>
The list of catalogue entries currently visible to this provider. Empty list is fine (means "no entries"); throw to signal a hard fetch failure — the registry catches and surfaces it as a problem-details response on
GET /api/catalogue/entries.