Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewDBInserter ¶
func NewDBInserter(opts ...InserterOption) agplusage.Inserter
NewDBInserter creates a new database-backed usage event inserter.
Types ¶
type InserterOption ¶
type InserterOption func(*dbInserter)
func InserterWithClock ¶
func InserterWithClock(clock quartz.Clock) InserterOption
InserterWithClock sets the quartz clock to use for the inserter.
type Publisher ¶
type Publisher interface { // Close closes the publisher and waits for it to finish. io.Closer // Start starts the publisher. It must only be called once. Start() error }
Publisher publishes usage events ***somewhere***.
type TallymanPublisherOption ¶
type TallymanPublisherOption func(*tallymanPublisher)
func PublisherWithClock ¶
func PublisherWithClock(clock quartz.Clock) TallymanPublisherOption
PublisherWithClock sets the clock to use for publishing usage events.
func PublisherWithHTTPClient ¶
func PublisherWithHTTPClient(httpClient *http.Client) TallymanPublisherOption
PublisherWithHTTPClient sets the HTTP client to use for publishing usage events.
func PublisherWithIngestURL ¶
func PublisherWithIngestURL(ingestURL string) TallymanPublisherOption
PublisherWithIngestURL sets the ingest URL to use for publishing usage events.
func PublisherWithInitialDelay ¶
func PublisherWithInitialDelay(initialDelay time.Duration) TallymanPublisherOption
PublisherWithInitialDelay sets the initial delay for the publisher.
Click to show internal directories.
Click to hide internal directories.