event

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2021 License: MIT Imports: 2 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 {
	ServiceName  string `json:"serviceName"`
	TopicName    string `json:"topicName"`
	IdempotentID string `json:"idempotentId"`
	Object       string `json:"object"`
	Message      string `json:"message"`
}

Event represents event object in for commerces services

type EventMirroringServiceInterface

type EventMirroringServiceInterface interface {
	Consume(ctx *context.Context, topicName string) (*Event, *types.Error)
	IsExist(ctx *context.Context, event *Event) bool
	Publish(ctx *context.Context, params *PublishEventParams) *types.Error
	Acknowledge(ctx *context.Context, event *Event) *types.Error
}

EventMirroringServiceInterface represents the mirroring services for storing event data

type PublishEventParams

type PublishEventParams struct {
	TopicNames     []string
	Body           []byte
	Metadata       map[string]string
	CallerFunction string
}

PublishEventParams encapsulate parameters in publish event method

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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