Pub/Sub Targets

One can think of a pub/sub target a lot like they do a human subscriber. It is simply yet another destination to send notifications when an alert is triggered. But, instead of providing an email or phone number to reach this entity, we need special information that allows DWAS to send information along to a pub/sub topic within the Google Cloud Platform.

Prerequisite to set up Pub/Sub

  • Create a service account in GCP (Google Cloud Platform)
  • Create a Project.
  • Create a Topic inside the project.
  • Create a JSON key of the service account.

One can configure a pub/sub target within the DWAS service by using the appropriate create and edit interfaces and by providing the key fields:

  • Project ID
  • Topic ID
  • GCP Service Account JSON
  • Enabled (to actively transmit notifications)

A sample image of this configuration is as shown:

Pub/Sub Configuration

There can be a many-to-many relationship between alerts and pub/sub targets. Therefore the configuration is very flexible and the user is free to set up whatever flow they deem most appropriate. A sample image of binding a single pub/sub target with a single alert is as shown:

Pub/Sub Binding

The user is then free to subscribe to this pub/sub topic using either a poll-based or push-based architecture. This configuration is the responsibility of the user and will not be discussed further here.

Before we explore notifications, we have one loose end to tend to. Let's explore a convenience feature for the bulk upload of points using GeoJSON file uploads.