Documentation ¶
Overview ¶
Package nats exposes an embedded NATS server.
It allows for message-oriented communication between the instances of this app.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultSettings = Settings{ URL: "nats://localhost:4222", Topics: TopicsSettings{ Postings: "postings", Results: "results", }, Server: ServerSettings{ MaxReconnect: nats.DefaultOptions.MaxReconnect, ReconnectWait: nats.DefaultOptions.ReconnectWait, StartupTimeout: 3 * time.Second, ClusterID: "messaging", ClusterURL: "nats://localhost:5333", ClusterRoutes: "", ClusterHeadlessService: "", MonitorHTTPPort: 6333, }, }
DefaultSettings define defaults for the embedded NATS server and clients.
Functions ¶
func DefaultSettingsNATS ¶
DefaultSettingsNATS returns all defaults for this package as a viper register.
This is primarily intended for documentation & help purpose.
Types ¶
type Server ¶
type Server struct { Settings // contains filtered or unexported fields }
type ServerDebugSettings ¶
type ServerSettings ¶
type Settings ¶
type Settings struct { URL string Topics TopicsSettings Server ServerSettings }
Settings for embedded NATS.
Primarily intended for being unmarshaled from a viper config.
type TopicsSettings ¶
Click to show internal directories.
Click to hide internal directories.