Versions in this module Expand all Collapse all v1 v1.0.4 Sep 29, 2024 Changes in this version + var ErrAborted = errors.New("event aborted") + type App struct + Subscriptions []*Subscription + func (App) KengineModule() kengine.ModuleInfo + func (app *App) Emit(ctx kengine.Context, eventName string, data map[string]any) Event + func (app *App) On(eventName string, handler Handler) error + func (app *App) Provision(ctx kengine.Context) error + func (app *App) Start() error + func (app *App) Stop() error + func (app *App) Subscribe(s *Subscription) error + type CloudEvent struct + Data json.RawMessage + DataContentType string + ID string + Source string + SpecVersion string + Time time.Time + Type string + type Event struct + Aborted error + Data map[string]any + func (e Event) CloudEvent() CloudEvent + func (e Event) ID() uuid.UUID + func (e Event) Name() string + func (e Event) Origin() kengine.Module + func (e Event) Timestamp() time.Time + type Handler interface + Handle func(context.Context, Event) error + type Subscription struct + Events []string + Handlers []Handler + HandlersRaw []json.RawMessage + Modules []kengine.ModuleID Other modules containing this package github.com/khulnasoft/kengine/v2