Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
Cfg *Config
Client api.Client
URL string
// contains filtered or unexported fields
}
Client for connecting to harvester
func (*Client) EventCatchUp ¶
func (h *Client) EventCatchUp(parentCtx context.Context, link string, events chan *proto.Event) error
EventCatchUp syncs all events
func (*Client) ReceiveSyncEvents ¶
func (h *Client) ReceiveSyncEvents(ctx context.Context, topicSelfLink string, sequenceID int64, eventCh chan *proto.Event) (int64, error)
ReceiveSyncEvents fetches events based on the sequence id and watch topic self link, and publishes the events to the event channel
type Config ¶
type Config struct {
ClientTimeout time.Duration
Host string
PageSize int
Port uint32
Protocol string
ProxyURL string
SequenceProvider events.SequenceProvider
TenantID string
TLSCfg *tls.Config
TokenGetter func() (string, error)
// contains filtered or unexported fields
}
Config for harvester
func NewConfig ¶
func NewConfig(cfg config.CentralConfig, getToken auth.TokenGetter, seq events.SequenceProvider) *Config
NewConfig creates a config for harvester connections
type ErrSeqGone ¶ added in v1.1.44
type ErrSeqGone struct {
}
ErrSeqGone - error for purged sequence
func (*ErrSeqGone) Error ¶ added in v1.1.44
func (e *ErrSeqGone) Error() string
Click to show internal directories.
Click to hide internal directories.