Documentation
¶
Overview ¶
Package diagnostics wires the diagnostics domain — doctor preflight checks, config-CLI validation, and smoke delivery tests — into an fx module. This file is the only fx-aware part of the domain; the domain, application, and infrastructure layers stay framework-free.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Module = fx.Module("diagnostics", fx.Provide( fx.Annotate(diagnosticsinfra.NewGitHubSigner, fx.As(new(diagnosticsdomain.Signer))), fx.Annotate(diagnosticsinfra.NewHTTPWebhookSender, fx.As(new(diagnosticsdomain.WebhookSender))), fx.Annotate(diagnosticsinfra.NewSlackSmokeReactions, fx.As(new(diagnosticsdomain.SmokeReactions))), fx.Annotate(diagnosticsinfra.NewStoreSmokeMessages, fx.As(new(diagnosticsdomain.SmokeMessages))), fx.Annotate(diagnosticsinfra.NewStoreSmokeCleanup, fx.As(new(diagnosticsdomain.SmokeCleanup))), fx.Annotate(provideSmokeMappings, fx.As(new(diagnosticsdomain.SmokeMappings))), fx.Annotate(provideLockGateway, fx.As(new(diagnosticsdomain.LockGateway))), fx.Annotate(provideDoctor, fx.As(new(diagnosticsdomain.Doctor))), fx.Annotate(provideSmokeUseCase, fx.As(new(diagnosticsdomain.Smoke))), provideMappingsValidator, ), )
Module binds the diagnostics ports to their implementations. The composition root must supply the following external inputs:
- *persistence.PullRequests
- *slack.Client
- *http.Client
- routingdomain.RoutingProvider (satisfies SmokeMappings Get)
- diagnosticsdomain.EntrySource (the routing provider for MappingsValidator)
- validationdomain.RepoValidator
- validationdomain.OrgRepoLister (may be nil via a provider func)
- diagnostics.Config
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
ConfigSnapshot diagnosticsdomain.ConfigSnapshot
SmokeConfig diagnosticsdomain.SmokeConfig
LockPath string
Clock func() time.Time
}
Config carries the composition-root-supplied, config-derived values the diagnostics use cases need but the module cannot build itself.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package application holds the diagnostics use cases — the doctor, the config list/validate CLI, and the smoke delivery — behind the domain's use-case interfaces.
|
Package application holds the diagnostics use cases — the doctor, the config list/validate CLI, and the smoke delivery — behind the domain's use-case interfaces. |
|
Package domain defines the diagnostics domain's ports, DTOs, and constants — the operator-tooling contracts (preflight doctor, config CLI, smoke delivery).
|
Package domain defines the diagnostics domain's ports, DTOs, and constants — the operator-tooling contracts (preflight doctor, config CLI, smoke delivery). |
|
Package infrastructure holds the diagnostics adapters: the config snapshot and database probe, the routing lock gateway, the request signer, the webhook sender, the report writer, and the smoke store/Slack adapters.
|
Package infrastructure holds the diagnostics adapters: the config snapshot and database probe, the routing lock gateway, the request signer, the webhook sender, the report writer, and the smoke store/Slack adapters. |
Click to show internal directories.
Click to hide internal directories.