Documentation
¶
Overview ¶
Package eventbus publishes the app's events to the broker that lodge embeds (lodge ADR-0022, and hearth's events/broker).
The transport dials the broker on the first event, and it dials again after a dial that failed, so that frostmarksd starts and serves its API while the broker is not there yet: the outbox keeps each event, and the relay's next drain publishes it.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Conn ¶
type Conn interface {
// Transport publishes 1 event, and it returns nil only once the broker
// holds it.
events.Transport
// Close closes the connection.
Close()
}
Conn is a connection to the broker: hearth's broker transport, which closes its connection when the app stops.
type Transport ¶
type Transport struct {
// contains filtered or unexported fields
}
Transport is the app's transport to lodge's broker. It dials the broker when it has the first event to publish, and not before.