Documentation ¶
Overview ¶
Package notifications contains the logic about send Swarming notifications.
Package notifications contains the logic about send Swarming notifications.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SendOnTaskUpdate ¶
func SendOnTaskUpdate(ctx context.Context, tr *model.TaskRequest, trs *model.TaskResultSummary) error
SendOnTaskUpdate sends PubSub notifications for given task.
Types ¶
type PubSubNotification ¶
PubSubNotification defines the message schema for Swarming to send the task completion PubSub message. The message attributes may contain "auth_token" if users provided it.
type PubSubNotifier ¶
type PubSubNotifier struct {
// contains filtered or unexported fields
}
func NewPubSubNotifier ¶
func NewPubSubNotifier(ctx context.Context, cloudProj string) (*PubSubNotifier, error)
NewPubSubNotifier initializes a PubSubNotifier.
func (*PubSubNotifier) RegisterTQTasks ¶
func (ps *PubSubNotifier) RegisterTQTasks(disp *tq.Dispatcher)
RegisterTQTasks registers task queue handlers.
func (*PubSubNotifier) Stop ¶
func (ps *PubSubNotifier) Stop()
Stop properly stops the PubSubNotifier.
Click to show internal directories.
Click to hide internal directories.