Documentation
¶
Overview ¶
Package notifier is the webhook sink of the Event stream: the one outbound Notifier Ripen ships with. It is off by default, filtered, and deliberately unreliable in one direction only — delivery may be dropped, never a Transaction.
Three rules shape it. Delivery is at-most-once and fail-open: a run never waits for a webhook and never fails because of one. Paging is on state *changes*, so a stack that has been broken for a week pages once, and pages again the moment it breaks after recovering. And the state database is the system of record: an Event can only report what is already written there.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Options ¶
type Options struct {
Settings config.WebhookSettings
Heartbeat time.Duration
Store *state.Store
Stream *event.Stream
HTTPClient *http.Client
Clock func() time.Time
QueueSize int
// Backoff is the pause between delivery attempts.
Backoff time.Duration
}
Options configures a Webhook.
type Webhook ¶
type Webhook struct {
// contains filtered or unexported fields
}
Webhook is the outbound Notifier.
func New ¶
New reads the destination, resets suppression if it changed, and starts the delivery worker.