longpollclient

package
v1.5.5-rc1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 17, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Event

type Event struct {
	Timestamp int64     `json:"timestamp"`
	Category  string    `json:"category"`
	Data      string    `json:"data"`
	ID        uuid.UUID `json:"id"`
	RequestId string
}

type LongPollClient

type LongPollClient struct {
	// contains filtered or unexported fields
}

func NewLongPollClient

func NewLongPollClient(config LongPollClientConfig) (*LongPollClient, error)

func (*LongPollClient) PullOnce

func (c *LongPollClient) PullOnce(since time.Time) ([]Event, error)

func (*LongPollClient) Start

func (c *LongPollClient) Start(since time.Time) chan Event

func (*LongPollClient) Stop

func (c *LongPollClient) Stop() error

type LongPollClientConfig

type LongPollClientConfig struct {
	Url        url.URL
	Logger     *log.Logger
	HttpClient *http.Client
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL