Documentation
¶
Index ¶
Constants ¶
View Source
const ServiceName = "example-optional"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ExampleOptional ¶
type ExampleOptional struct{}
ExampleOptional demonstrates allowed-failure behavior. It fails immediately but is marked as an allowed failure, so it doesn't take down the rest of the app. Useful pattern for non-critical services like metrics exporters, cache warmers, or analytics collectors.
func New ¶
func New() (*ExampleOptional, error)
func (*ExampleOptional) IsAllowedFailure ¶
func (o *ExampleOptional) IsAllowedFailure() bool
IsAllowedFailure makes ExampleOptional implement the AllowedFailure interface. Its failure won't bring down the service manager.
func (*ExampleOptional) Name ¶
func (o *ExampleOptional) Name() string
Click to show internal directories.
Click to hide internal directories.