notificationserver

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2023 License: Apache-2.0 Imports: 9 Imported by: 5

Documentation

Index

Constants

View Source
const (
	PathWebsocketV1 = "/v1/waitfornotification"
	PathRESTV1      = "/v1/sendnotification"
)

server paths

View Source
const (
	TargetCustomer  = "customerGUID"
	TargetCluster   = "clusterName"
	TargetComponent = "clusterComponent"
)
View Source
const (
	TargetComponentPostureValue   = "PolicyValidator"
	TargetComponentLoggerValue    = "Logger"
	TargetComponentTriggerHandler = "InClusterTriggerHandler"
)

Variables

This section is empty.

Functions

func PushNotificationServer

func PushNotificationServer(edgeURL string, targetMap map[string]string, message interface{}, jsonFormat bool) error

PushNotificationServer push notification to rest api server. if jsonFormat is set to false, will Marshal useing bson

Types

type Notification

type Notification struct {
	Target            map[string]string `json:"target"`
	SendSynchronicity bool              `json:"sendSynchronicity"`
	Notification      interface{}       `json:"notification"`
}

Notification passed between servers

func MockNotificationA

func MockNotificationA() *Notification

Jump to

Keyboard shortcuts

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