api

package
v0.4.6 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2022 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const LoggerTag = "EVENT_API"

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	EventStore *store.EventStore
	Address    string
	Logger     log.Logger
}

type EventAPI

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

EventAPI provides an HTTP API for EventStore.

func New

func New(ctx context.Context, cfg Config) (*EventAPI, error)

New returns a new instance of the EventAPI struct.

func (*EventAPI) Start

func (e *EventAPI) Start() error

Start starts HTTP server.

func (*EventAPI) Wait

func (e *EventAPI) Wait() chan error

Wait waits until the context is canceled or until an error occurs.

Jump to

Keyboard shortcuts

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