helpers

package
v0.0.30 Latest Latest
Warning

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

Go to latest
Published: Sep 24, 2021 License: MIT Imports: 15 Imported by: 2

Documentation

Index

Constants

View Source
const (
	// ServiceName ...
	ServiceName = "engagement"
	// TopicVersion ...
	TopicVersion = "v1"
)

Variables

This section is empty.

Functions

func AddPubSubNamespace

func AddPubSubNamespace(topicName string) string

AddPubSubNamespace creates a namespaced topic name

func EpochTimetoStandardTime

func EpochTimetoStandardTime(timeOfDelivery string) time.Time

EpochTimetoStandardTime converts unix epoch time to standard time

func InitializeInterServiceClient

func InitializeInterServiceClient(serviceName string) *interserviceclient.InterServiceClient

InitializeInterServiceClient initializes an external service in the correct environment given its name

func RecordSpanError

func RecordSpanError(span trace.Span, err error)

RecordSpanError is a helper function to capture errors in a span

func StripMailGunIDSpecialCharacters

func StripMailGunIDSpecialCharacters(messageID string) string

StripMailGunIDSpecialCharacters strips '<' and '>' charcaters that come along with the returned Mailgun's message-id

func ValidateElement

func ValidateElement(el feedlib.Element) error

ValidateElement ensures that an element is non nil and valid

Types

type FilterParams

type FilterParams struct {
	Labels []string `json:"labels"`
}

FilterParams organizes the parameters needed to filter persistent feed items

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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