pubsub

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2024 License: CC0-1.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewPubsubSender

func NewPubsubSender(ctx context.Context, config interface{}) (event.Sender, error)

Types

type PubsubMessageCarrier

type PubsubMessageCarrier struct {
	*pubsub.Message
}

func (PubsubMessageCarrier) Get

func (k PubsubMessageCarrier) Get(key string) string

Get retrieves a single value for a given key.

func (PubsubMessageCarrier) Keys

func (k PubsubMessageCarrier) Keys() []string

Keys returns a slice of all key identifiers in the carrier.

func (PubsubMessageCarrier) Set

func (k PubsubMessageCarrier) Set(key, val string)

Set sets a header.

type PubsubSender

type PubsubSender struct {
	Schema       string `json:"schema" mapstructure:"schema"`
	KafkaBrokers string `json:"kafka_brokers" mapstructure:"kafka_brokers"`
	// contains filtered or unexported fields
}

func (*PubsubSender) Send

func (p *PubsubSender) Send(ctx context.Context, message *event.EventMessage) error

Jump to

Keyboard shortcuts

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