Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type OpenSergoClient ¶
type OpenSergoClient interface { // Start the client. Start() error // SubscribeConfig subscribes data for given subscribe target. SubscribeConfig(key model.SubscribeKey, opts ...SubscribeOption) error // UnsubscribeConfig unsubscribes data for given subscribe target. UnsubscribeConfig(subscribeKey model.SubscribeKey) error }
OpenSergoClient is the universal interface of OpenSergo client.
type SubscribeOption ¶
type SubscribeOption func(*SubscribeOptions)
func WithAttachment ¶
func WithAttachment(key string, value interface{}) SubscribeOption
WithAttachment provides an attachment (key-value pair).
func WithSubscriber ¶
func WithSubscriber(subscriber subscribe.Subscriber) SubscribeOption
WithSubscriber provides a subscriber.
type SubscribeOptions ¶
type SubscribeOptions struct { Subscribers []subscribe.Subscriber Attachments map[string]interface{} }
SubscribeOptions represents the options of OpenSergo data subscription.
Click to show internal directories.
Click to hide internal directories.